https://bugs.kde.org/show_bug.cgi?id=465886

Alvin Wong <al...@alvinhc.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Latest Commit|https://invent.kde.org/grap |https://invent.kde.org/grap
                   |hics/krita/-/commit/e95f6d4 |hics/krita/-/commit/22dc42a
                   |39a39a6c739e66b36d706876049 |537afdf11a5ca48aea617c6b715
                   |15fd7a                      |69ffed

--- Comment #12 from Alvin Wong <al...@alvinhc.com> ---
Git commit 22dc42a537afdf11a5ca48aea617c6b71569ffed by Alvin Wong.
Committed on 31/07/2023 at 13:03.
Pushed by alvinwong into branch 'krita/5.2'.

text: Add synthesizing bold glyphs

If the user requested bold but the font does not have native bold
variant, 5.1 and earlier will synthesize bold by making the glyph
thicker.

Implement the same thing for the new text engine. This emboldens the
glyph outline by a bit using `FT_Outline_Embolden`, and adjust the glyph
advance to accommodate for the wider glyph. This implementation is
heavily inspired by Firefox.

For bitmap glyphs, use `FT_Bitmap_Embolden` like `FT_GlyphSlot_Embolden`
does, but we use a lighter strength, and for small fonts size we only
embolden the glyph horizontally. This is similar to what Windows does.
If we embolden both horizontally and vertically, especially for CJK the
glyphs often lose the details and become completely unrecognizable black
blobs.

This commit does not provide an option for disabling it, but we should
implement the `font-synthesis-weight` CSS property to do so in the
future.
(cherry picked from commit e95f6d439a39a6c739e66b36d70687604915fd7a)

M  +59   -1    libs/flake/text/KoSvgTextShape.cpp

https://invent.kde.org/graphics/krita/-/commit/22dc42a537afdf11a5ca48aea617c6b71569ffed

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to