Mercurial > emacs
comparison src/w32font.c @ 96472:04655c344174
(w32font_text_extents): Don't count overhang as part of width.
author | Jason Rumney <jasonr@gnu.org> |
---|---|
date | Tue, 01 Jul 2008 14:00:42 +0000 |
parents | 01647003e227 |
children | 5deb199cf917 |
comparison
equal
deleted
inserted
replaced
96471:e347ed611dcf | 96472:04655c344174 |
---|---|
524 } | 524 } |
525 | 525 |
526 /* Give our best estimate of the metrics, based on what we know. */ | 526 /* Give our best estimate of the metrics, based on what we know. */ |
527 if (metrics) | 527 if (metrics) |
528 { | 528 { |
529 metrics->width = total_width; | 529 metrics->width = total_width - w32_font->metrics.tmOverhang; |
530 metrics->lbearing = 0; | 530 metrics->lbearing = 0; |
531 metrics->rbearing = total_width + w32_font->metrics.tmOverhang; | 531 metrics->rbearing = total_width; |
532 } | 532 } |
533 | 533 |
534 /* Restore state and release DC. */ | 534 /* Restore state and release DC. */ |
535 SelectObject (dc, old_font); | 535 SelectObject (dc, old_font); |
536 release_frame_dc (f, dc); | 536 release_frame_dc (f, dc); |