mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
main: round strikeout and underline position fallback handling
This commit is contained in:
parent
a1cd3769a3
commit
b2ca984ccb
1 changed files with 2 additions and 2 deletions
4
main.c
4
main.c
|
|
@ -634,7 +634,7 @@ main(int argc, char *const *argv)
|
|||
f->underline.thickness = ceil(ft_face->underline_thickness * x_scale / 64.);
|
||||
|
||||
if (f->underline.position == 0.) {
|
||||
f->underline.position = descent / 2.;
|
||||
f->underline.position = round(descent / 2.);
|
||||
f->underline.thickness = fabs(round(descent / 5.));
|
||||
}
|
||||
|
||||
|
|
@ -648,7 +648,7 @@ main(int argc, char *const *argv)
|
|||
}
|
||||
|
||||
if (f->strikeout.position == 0.) {
|
||||
f->strikeout.position = height / 2. + descent;
|
||||
f->strikeout.position = round(height / 2. + descent);
|
||||
f->strikeout.thickness = f->underline.thickness;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue