]> git.lyx.org Git - features.git/commit
Use correct width for \fint
authorEnrico Forestieri <forenr@lyx.org>
Sat, 29 Aug 2020 18:10:26 +0000 (20:10 +0200)
committerEnrico Forestieri <forenr@lyx.org>
Sat, 29 Aug 2020 18:10:26 +0000 (20:10 +0200)
commit80f94a9398ef1843d2592e87bd71d1cd2b40703c
tree28505a3403558ed48237100fc17f417759c14f36
parentc225b758cb10bd72609e548b5cddd0bdbb85416d
Use correct width for \fint

Both QTextLine::naturalTextWidth() and QTextLine::horizontalAdvance()
return the same value for \fint. However, examining esint10.ttf with
fontforge does not reveal any issue with the metrics. The fact that
\fint seems to be the only affected symbol might be due to its code
point, which corresponds to a space, so that maybe Qt makes some
assumptions on the metrics.

As QTextLine::naturalTextWidth() returns the width of the line that is
occupied by text, in the case of a single symbol we can obtain the
same value by using the width of the rectangle bounding the symbol.
src/frontends/qt/GuiFontMetrics.cpp