RFR: 8269806: Emoji rendering on Linux [v17]
Phil Race
prr at openjdk.org
Wed Jan 25 22:29:01 UTC 2023
On Wed, 25 Jan 2023 13:22:31 GMT, Nikita Gubarkov <duke at openjdk.org> wrote:
>> It was implemented in JetBrains Runtime a year ago and was ported & refactored for this PR
>> It includes:
>> - Bitmap glyph loading via Freetype
>> - Manual scaling & transformation of bitmap glyphs with nearest-neighbor or bilinear-mipmap style algorithms depending on the text antialiasing hint
>> - Storing BGRA glyphs in glyph cache & rendering them as plain images, as currently used XRender text drawing functions doesn't support colored glyphs
>> - Small fixes in related code like null-checks which could cause NPE & comment typos
>
> Nikita Gubarkov has updated the pull request incrementally with one additional commit since the last revision:
>
> Skip tests if required font is absent
src/java.desktop/share/classes/sun/font/CMap.java line 1173:
> 1171:
> 1172: char getVariationGlyph(int charCode, int variationSelector) {
> 1173: if (variationSelector == 0) return getGlyph(charCode);
another place for braces
src/java.desktop/share/classes/sun/font/CompositeGlyphMapper.java line 142:
> 140: @Override
> 141: public int charToVariationGlyph(int unicode, int variationSelector) {
> 142: if (variationSelector == 0) return charToGlyph(unicode);
more missing braces. I'm going to stop pointing these out, please just find and fix any others
src/java.desktop/share/native/libfontmanager/freetypeScaler.c line 52:
> 50: // to build on older Linuxes, this is not a big problem,
> 51: // as Linux uses bitmap emoji anyway.
> 52: #if defined(_WIN32) || defined(__APPLE__)
Do we really have to disable coloured outlines because of what's available at build time ? Why can't we dynamically locate all the needed symbols at runtime ?
-------------
PR: https://git.openjdk.org/jdk/pull/4798
More information about the client-libs-dev
mailing list