News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

Incorrect font height in some fonts

Started by Piotr Grochowski, April 30, 2020, 07:09:30 PM

Previous topic - Next topic

Piotr Grochowski

This is in Microsoft Windows.

[img src=https://i.imgur.com/BNdG29O.png /]

On the left is code blocks, where the font height is one pixel too much. On the right is Microsoft Notepad where the font height is handled properly.

An important thing is that it only happens with some fonts, not all fonts. This applies to both bitmap and TrueType fonts. My theory is that the incorrect font height happens when the font bottom is on the baseline (like is the case in the picture). This is not the right behavior of GDI rendering. I hate being prevented from using certain fonts as intended so please fix this issue by the next version.

Piotr Grochowski

And yes I did update to 20.03 and it's clearly not fixed, same result!

oBFusCATed

If you want to get help you'll need to provide more details, like:

1. Which fonts work?
2. Which doesn't?
3. What happens if you change the font size?
4. Does it work correctly in scite or codelite? Or even the stc demo in wxwidgets?
4. OS version
5. Have you tried to enable direct 2d in 20.03 ( settings -> editor -> other editor settings -> technology)?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Piotr Grochowski

Quote from: oBFusCATed on April 30, 2020, 07:41:16 PM
If you want to get help you'll need to provide more details, like:

1. Which fonts work?
2. Which doesn't?
3. What happens if you change the font size?
4. Does it work correctly in scite or codelite? Or even the stc demo in wxwidgets?
4. OS version
5. Have you tried to enable direct 2d in 20.03 ( settings -> editor -> other editor settings -> technology)?

1. Ones that have space both below and above the baseline (they are internal font settings, also called WinAscent and WinDescent)
2. Ones that have the baseline at the font bottom
3. The font height gets consistently off-by-one
4. I haven't learned the entirety of the C++ language yet so I don't know about those features.
4. Windows 10 Home, 1909, 18363.778
5. There isn't a "direct 2d" option anywhere

Piotr Grochowski

Reproducible too in Windows 7 Ultimate x64 Edition.

BlueHazzard

Have you tried the latest release? Have you tried the option from
Quote5. Have you tried to enable direct 2d in 20.03 ( settings -> editor -> other editor settings -> technology)?

Have you tried your font in notepad++? is it the same problem?

Can you name a font? Does it happen with windows standard fonts, or do i have to download a font?

Piotr Grochowski

Quote from: BlueHazzard on May 26, 2020, 08:08:25 PM
Have you tried the latest release? Have you tried the option from
Quote5. Have you tried to enable direct 2d in 20.03 ( settings -> editor -> other editor settings -> technology)?

Have you tried your font in notepad++? is it the same problem?

Can you name a font? Does it happen with windows standard fonts, or do i have to download a font?

I do not have Notepad++ right now and do not intend to ever use it.

Fonts that show the Incorrect font height in some fonts glitch include: Riglos Mono (as of version 1.1, not 1.0), and TD bitmaps fonts. The way to test the fonts for font height is to use this character: █ and paste it along multiple rows.