Skip to content

feat(emoji): add setting to render high-resolution system emojis in chats - #2256

Merged
mpretty-cyro merged 7 commits into
session-foundation:devfrom
igotlinux:feature/system-emoji-support
Nov 30, 2026
Merged

mpretty-cyro merged 7 commits into
session-foundation:devfrom
igotlinux:feature/system-emoji-support

Conversation

@igotlinux

@igotlinux igotlinux commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

First time contributor checklist

  • I have tested my contribution on these devices:
  • Android Emulator (Pixel, Android 14 / API 34), playDebug
  • Android Physical Device, playDebug
  • My contribution is fully baked and ready to be merged as is
  • I ensure that all the open issues my contribution fixes are mentioned in the commit message of my first commit using the Fixes #1234 syntax (Fixes Low-res emojis #53)

Description

Fixes #53

Note on #1053: I noticed #1053 previously attempted a larger emoji pipeline rewrite but has experienced merge conflicts on dev. This PR proposes a lightweight, non-breaking user preference toggle ("Use System Emojis") that immediately delivers crisp emojis on modern devices without requiring assets removal or breaking backward compatibility.

Session currently uses a legacy 66x66px bitmap spritesheet pipeline (EmojiProvider / EmojiTextView) inherited from older Signal code. On modern high-DPI screens, these small bitmap tiles appear blurry and pixelated when scaled up.

This PR adds a "Use System Emojis" toggle in Settings → Chats (disabled by default to avoid missing glyphs on older devices) that allows messages to render sharp, high-resolution vector emojis using the device's native emoji font rather than the low-resolution spritesheets.

Changes:

  • Added USE_SYSTEM_EMOJI key and getter/setter preferences in TextSecurePreferences.kt (defaults to false).
  • Updated EmojiTextView.java to check isUseSystemEmojiEnabled() before parsing/replacing emoji spans; when enabled, it skips the bitmap spritesheet replacement and renders the native Unicode characters.
  • Added preference toggle in ChatsPreferenceScreen.kt with dedicated QA tags in content-descriptions, and state handling in ChatsPreferenceViewModel.kt.

Testing:

  • Verified in Android Studio with compilePlayDebugKotlin, compilePlayDebugJavaWithJavac, and testPlayDebugUnitTest (all tests pass).
  • Toggled on/off in Settings → Chats and verified emoji sharpness in conversation views.

@igotlinux
igotlinux force-pushed the feature/system-emoji-support branch from 08c3b58 to e97e27c Compare November 11, 2026 15:19

@mpretty-cyro mpretty-cyro left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution here, there are a few changes which need to be made before this could be merged

@igotlinux

Copy link
Copy Markdown
Contributor Author

Thanks for the review @mpretty-cyro! Addressed all feedback:

  • Changed the default of USE_SYSTEM_EMOJI / useSystemEmoji to false in TextSecurePreferences.kt and ChatsPreferenceViewModel.kt.
  • Added dedicated qa_preferences_use_system_emojis / qa_preferences_use_system_emojis_toggle strings in content-descriptions and updated ChatsPreferenceScreen.kt to use them.

Verified with compilePlayDebugKotlin, compilePlayDebugJavaWithJavac, and testPlayDebugUnitTest.

@igotlinux

Copy link
Copy Markdown
Contributor Author

also updated EmojiProvider so reaction emojis, reaction pills, the emoji picker and input search bar use the system font too when the setting is on instead of still pulling the 66x66 spritesheets

@igotlinux

Copy link
Copy Markdown
Contributor Author

Any updates ?

@mpretty-cyro

Copy link
Copy Markdown
Collaborator

Any updates ?

I think this one is mostly good, I just need to do a quick test and add the new strings to Crowdin

With "Use System Emoji" on, reaction pills, the reaction bar and the
picker drew every emoji with the device font, so an emoji newer than
that font showed as an empty box or as its parts squeezed together. They
now use the bundled image for anything the font can't draw as a single
glyph, and non-emoji reaction text gets the existing crossed-square
fallback again.
@mpretty-cyro

Copy link
Copy Markdown
Collaborator

@igotlinux Thanks again for your contribution, I managed to get through testing this today and made the following changes before merging:

  • Merged current dev, which carries the new strings below. The three original commits are unchanged; the changes are three commits and that merge on top.
  • The setting's text is now translatable. The section title, name and description use conversationsEmoji, conversationsUseSystemEmoji and conversationsUseSystemEmojiDescription instead of English literals. The copy is now "Emoji", "Use System Emoji" and "Display emoji using your device's emoji font."
  • Fallback to the bundled emoji. With the setting on, reaction pills, the reaction bar and the emoji picker drew every emoji with the device font, so on an older device an emoji newer than its font showed as an empty box, or a joined sequence as its parts. Anything the font can't draw as a single glyph (Paint.hasGlyph) now uses the bundled image, and reaction text that isn't a known emoji gets the existing crossed-square placeholder again.
  • Removed the static TextSecurePreferences.setUseSystemEmojiEnabled(Context, Boolean), which had no callers.

@mpretty-cyro
mpretty-cyro merged commit 1e23329 into session-foundation:dev Nov 30, 2026
0 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Low-res emojis

2 participants