Text Base Line inconsistent for glyphs with different hight

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
HPS
Reply | Threaded
Open this post in threaded view
|

Text Base Line inconsistent for glyphs with different hight

HPS
Version: 2.2.2_alpha1-77-g07e729ea
Compiler: GNU GCC 14.1.1
Compiled on: May 30 2024
Qt Version: 6.7.1
Boost Version: 1.83.0
System: Fedora Linux 40 (Server Edition)

How to reproduce:

Use an empty drawing
Add MText like "wer"
Add MText like "twer"
Add MText like "gwer"

The base lines are not aligned

Expected:

All chars have the same base line.



I did not check different text options.
Reply | Threaded
Open this post in threaded view
|

Re: Text Base Line inconsistent for glyphs with different hight

dxli
Does this happen to early versions?
HPS
Reply | Threaded
Open this post in threaded view
|

Re: Text Base Line inconsistent for glyphs with different hight

HPS
LibreCAD from Fedora 40 Repo works OK:
librecad.x86_64   2.2.0.2-3.fc40

Version: 2.2.0.2
Compiler: GNU GCC 14.0.1
Compiled on: Jan 25 2024
Qt Version: 5.15.13
Boost Version: 1.83.0
System: Fedora Linux 40 (Server Edition)
Reply | Threaded
Open this post in threaded view
|

Re: Text Base Line inconsistent for glyphs with different hight

dxli
The current text alignment algorithm is by aligning individual character's actually drawing sizes

This is is clearly an issue shown in the screenshots here.

I am thinking about vertically aligning by the maximum character size of the selected fonts family. Or, we do this in horizontal as well.

It's a new algorithm, so it first goes to 2.2.2, and if it works well, we will backport to 2.2.1 before the 2.2.1 release.
HPS wrote
LibreCAD from Fedora 40 Repo works OK:
librecad.x86_64   2.2.0.2-3.fc40

Version: 2.2.0.2
Compiler: GNU GCC 14.0.1
Compiled on: Jan 25 2024
Qt Version: 5.15.13
Boost Version: 1.83.0
System: Fedora Linux 40 (Server Edition)
HPS
Reply | Threaded
Open this post in threaded view
|

Re: Text Base Line inconsistent for glyphs with different hight

HPS
Actually your comment reminds me of the same problem I had with character alignment on a Dymo Label printer.

Thank you for fixing.