1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-30 00:51:50 -08:00

Simplify Haiku underline code

* src/haikuterm.c (haiku_draw_text_decoration): Remove code left
over from when mouse face had to be set manually.
This commit is contained in:
Po Lu 2022-01-26 05:09:09 +00:00
parent bca6855084
commit db7de56eef

View file

@ -632,20 +632,12 @@ haiku_draw_text_decoration (struct glyph_string *s, struct face *face,
&& (s->prev->face->underline_pixels_above_descent_line
== s->face->underline_pixels_above_descent_line))
{
struct face *prev_face = s->prev->face;
if (prev_face && prev_face->underline == FACE_UNDER_LINE)
{
/* We use the same underline style as the previous one. */
thickness = s->prev->underline_thickness;
position = s->prev->underline_position;
}
else
goto calculate_underline_metrics;
/* We use the same underline style as the previous one. */
thickness = s->prev->underline_thickness;
position = s->prev->underline_position;
}
else
{
calculate_underline_metrics:;
struct font *font = font_for_underline_metrics (s);
unsigned long minimum_offset;
bool underline_at_descent_line;