You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have noticed that some fonts (not all) just give wrong glyph indices when passed to DrawGlyphRun in the DWRITE_GLYPH_RUN. For example when i use FreeType to check the index for space in the AppleStorm font I get the glyph index 1. When i check on FontDrop I also get the index as 1 as shown in the screenshot.
Even when I ask DWriteCore itself to give me the glyph indices using GetGlyphIndices, it tells me space is glyph index 1. But when layed out it gives me 3. This results in situations like this, where with Open Sans it gives the correct result:
but when I switch to the offending font, it shifts it 2 indices to the right:
Steps to reproduce the bug
Since i cannot attach font files, 1 font that definitely does not work is the AppleStorm font.
Use that file to the retrieve some glyph indices using GetGlyphIndices, like space with codepoint 32.
See that it returns glyph index 1 for space.
Then layout text and see that the glyph index it has given (in this font) is 3.
Expected behavior
DWriteCore returns the correct glyph indices for the given codepoints. The same it also returns in GetGlyphIndices.
Screenshots
No response
NuGet package version
None
Packaging type
Unpackaged
Windows version
Windows 11 version 22H2 (22621, 2022 Update)
IDE
Visual Studio 2022
Additional context
No response
The text was updated successfully, but these errors were encountered:
Describe the bug
I have noticed that some fonts (not all) just give wrong glyph indices when passed to
DrawGlyphRun
in theDWRITE_GLYPH_RUN
. For example when i use FreeType to check the index for space in the AppleStorm font I get the glyph index1
. When i check on FontDrop I also get the index as1
as shown in the screenshot.Even when I ask DWriteCore itself to give me the glyph indices using
GetGlyphIndices
, it tells me space is glyph index1
. But when layed out it gives me3
. This results in situations like this, where with Open Sans it gives the correct result:but when I switch to the offending font, it shifts it
2
indices to the right:Steps to reproduce the bug
GetGlyphIndices
, like space with codepoint32
.1
for space.3
.Expected behavior
DWriteCore returns the correct glyph indices for the given codepoints. The same it also returns in
GetGlyphIndices
.Screenshots
No response
NuGet package version
None
Packaging type
Unpackaged
Windows version
Windows 11 version 22H2 (22621, 2022 Update)
IDE
Visual Studio 2022
Additional context
No response
The text was updated successfully, but these errors were encountered: