diff options
| author | Po Lu | 2022-01-06 12:05:47 +0000 |
|---|---|---|
| committer | Po Lu | 2022-01-06 12:05:47 +0000 |
| commit | cbe10f37533bc8dc21f7eb9a86bc5f31b3b2c884 (patch) | |
| tree | 32c82d5d12797e44f23f1464a4c4a0fc89b809d8 /src | |
| parent | b3ceeb3f2a4240736840422c272204030d113083 (diff) | |
| download | emacs-cbe10f37533bc8dc21f7eb9a86bc5f31b3b2c884.tar.gz emacs-cbe10f37533bc8dc21f7eb9a86bc5f31b3b2c884.zip | |
Remove some more useless clipping stack calls on Haiku
* src/haikuterm.c (haiku_draw_box_rect):
(haiku_draw_relief_rect):
(haiku_draw_text_decoration): Get rid of calls to
BView_StartClip and BView_EndClip.
Diffstat (limited to 'src')
| -rw-r--r-- | src/haikuterm.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/src/haikuterm.c b/src/haikuterm.c index 928b5718551..2239770de95 100644 --- a/src/haikuterm.c +++ b/src/haikuterm.c | |||
| @@ -428,8 +428,6 @@ haiku_draw_box_rect (struct glyph_string *s, | |||
| 428 | void *view = FRAME_HAIKU_VIEW (s->f); | 428 | void *view = FRAME_HAIKU_VIEW (s->f); |
| 429 | struct face *face = s->face; | 429 | struct face *face = s->face; |
| 430 | 430 | ||
| 431 | BView_StartClip (view); | ||
| 432 | haiku_clip_to_string (s); | ||
| 433 | BView_SetHighColor (view, face->box_color); | 431 | BView_SetHighColor (view, face->box_color); |
| 434 | if (clip_rect) | 432 | if (clip_rect) |
| 435 | BView_ClipToRect (view, clip_rect->x, clip_rect->y, clip_rect->width, | 433 | BView_ClipToRect (view, clip_rect->x, clip_rect->y, clip_rect->width, |
| @@ -443,7 +441,6 @@ haiku_draw_box_rect (struct glyph_string *s, | |||
| 443 | if (right_p) | 441 | if (right_p) |
| 444 | BView_FillRectangle (view, right_x - vwidth + 1, | 442 | BView_FillRectangle (view, right_x - vwidth + 1, |
| 445 | top_y, vwidth, bottom_y - top_y + 1); | 443 | top_y, vwidth, bottom_y - top_y + 1); |
| 446 | BView_EndClip (view); | ||
| 447 | } | 444 | } |
| 448 | 445 | ||
| 449 | static void | 446 | static void |
| @@ -484,8 +481,6 @@ haiku_draw_relief_rect (struct glyph_string *s, | |||
| 484 | &color_corner); | 481 | &color_corner); |
| 485 | 482 | ||
| 486 | void *view = FRAME_HAIKU_VIEW (s->f); | 483 | void *view = FRAME_HAIKU_VIEW (s->f); |
| 487 | BView_StartClip (view); | ||
| 488 | haiku_clip_to_string (s); | ||
| 489 | BView_SetHighColor (view, raised_p ? color_white : color_black); | 484 | BView_SetHighColor (view, raised_p ? color_white : color_black); |
| 490 | if (clip_rect) | 485 | if (clip_rect) |
| 491 | BView_ClipToRect (view, clip_rect->x, clip_rect->y, clip_rect->width, | 486 | BView_ClipToRect (view, clip_rect->x, clip_rect->y, clip_rect->width, |
| @@ -548,8 +543,6 @@ haiku_draw_relief_rect (struct glyph_string *s, | |||
| 548 | if (right_p && bot_p) | 543 | if (right_p && bot_p) |
| 549 | BView_FillRectangle (view, right_x, bottom_y, 1, 1); | 544 | BView_FillRectangle (view, right_x, bottom_y, 1, 1); |
| 550 | } | 545 | } |
| 551 | |||
| 552 | BView_EndClip (view); | ||
| 553 | } | 546 | } |
| 554 | 547 | ||
| 555 | static void | 548 | static void |
| @@ -598,8 +591,6 @@ haiku_draw_text_decoration (struct glyph_string *s, struct face *face, | |||
| 598 | 591 | ||
| 599 | void *view = FRAME_HAIKU_VIEW (s->f); | 592 | void *view = FRAME_HAIKU_VIEW (s->f); |
| 600 | BView_draw_lock (view); | 593 | BView_draw_lock (view); |
| 601 | BView_StartClip (view); | ||
| 602 | haiku_clip_to_string (s); | ||
| 603 | 594 | ||
| 604 | if (face->underline) | 595 | if (face->underline) |
| 605 | { | 596 | { |
| @@ -734,7 +725,6 @@ haiku_draw_text_decoration (struct glyph_string *s, struct face *face, | |||
| 734 | BView_FillRectangle (view, s->x, glyph_y + dy, s->width, h); | 725 | BView_FillRectangle (view, s->x, glyph_y + dy, s->width, h); |
| 735 | } | 726 | } |
| 736 | 727 | ||
| 737 | BView_EndClip (view); | ||
| 738 | BView_draw_unlock (view); | 728 | BView_draw_unlock (view); |
| 739 | } | 729 | } |
| 740 | 730 | ||