HCoop
/
bpt
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c8d88d0
)
(w32_get_glyph_string_clip_rect): Clip cursor tightly.
author
Jason Rumney
<jasonr@gnu.org>
Sat, 16 Nov 2002 01:21:22 +0000
(
01:21
+0000)
committer
Jason Rumney
<jasonr@gnu.org>
Sat, 16 Nov 2002 01:21:22 +0000
(
01:21
+0000)
src/w32term.c
patch
|
blob
|
blame
|
history
diff --git
a/src/w32term.c
b/src/w32term.c
index
a9ab367
..
84c9a3c
100644
(file)
--- a/
src/w32term.c
+++ b/
src/w32term.c
@@
-3133,6
+3133,18
@@
w32_get_glyph_string_clip_rect (s, r)
r->top = WINDOW_TO_FRAME_PIXEL_Y (s->w, r->top);
+ /* If drawing the cursor, don't let glyph draw outside its
+ advertised boundaries. Cleartype does this under some circumstances. */
+ if (s->hl == DRAW_CURSOR)
+ {
+ if (s->x > r->left)
+ {
+ r_width -= s->x - r->left;
+ r->left = s->x;
+ }
+ r_width = min (r_width, s->first_glyph->pixel_width);
+ }
+
r->bottom = r->top + r_height;
r->right = r->left + r_width;
}