Mercurial > emacs
comparison src/w32term.c @ 48360:033719ff91f1
(w32_get_glyph_string_clip_rect): Clip cursor tightly.
author | Jason Rumney <jasonr@gnu.org> |
---|---|
date | Sat, 16 Nov 2002 01:21:22 +0000 |
parents | 9fde360ca455 |
children | c7fb53597300 |
comparison
equal
deleted
inserted
replaced
48359:1e8497bc057d | 48360:033719ff91f1 |
---|---|
3131 r->top -= s->f->output_data.w32->internal_border_width; | 3131 r->top -= s->f->output_data.w32->internal_border_width; |
3132 } | 3132 } |
3133 | 3133 |
3134 r->top = WINDOW_TO_FRAME_PIXEL_Y (s->w, r->top); | 3134 r->top = WINDOW_TO_FRAME_PIXEL_Y (s->w, r->top); |
3135 | 3135 |
3136 /* If drawing the cursor, don't let glyph draw outside its | |
3137 advertised boundaries. Cleartype does this under some circumstances. */ | |
3138 if (s->hl == DRAW_CURSOR) | |
3139 { | |
3140 if (s->x > r->left) | |
3141 { | |
3142 r_width -= s->x - r->left; | |
3143 r->left = s->x; | |
3144 } | |
3145 r_width = min (r_width, s->first_glyph->pixel_width); | |
3146 } | |
3147 | |
3136 r->bottom = r->top + r_height; | 3148 r->bottom = r->top + r_height; |
3137 r->right = r->left + r_width; | 3149 r->right = r->left + r_width; |
3138 } | 3150 } |
3139 | 3151 |
3140 | 3152 |