[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/src/w32term.c
From: |
Jason Rumney |
Subject: |
[Emacs-diffs] Changes to emacs/src/w32term.c |
Date: |
Sun, 20 Jan 2002 11:21:16 -0500 |
Index: emacs/src/w32term.c
diff -c emacs/src/w32term.c:1.136 emacs/src/w32term.c:1.137
*** emacs/src/w32term.c:1.136 Wed Jan 16 18:04:03 2002
--- emacs/src/w32term.c Sun Jan 20 09:54:48 2002
***************
*** 388,395 ****
static void x_clear_cursor P_ ((struct window *));
static void frame_highlight P_ ((struct frame *));
static void frame_unhighlight P_ ((struct frame *));
! static void w32_new_focus_frame P_ ((struct w32_display_info *,
! struct frame *));
static void w32_frame_rehighlight P_ ((struct frame *));
static void x_frame_rehighlight P_ ((struct w32_display_info *));
static void x_draw_hollow_cursor P_ ((struct window *, struct glyph_row *));
--- 388,395 ----
static void x_clear_cursor P_ ((struct window *));
static void frame_highlight P_ ((struct frame *));
static void frame_unhighlight P_ ((struct frame *));
! static void x_new_focus_frame P_ ((struct w32_display_info *,
! struct frame *));
static void w32_frame_rehighlight P_ ((struct frame *));
static void x_frame_rehighlight P_ ((struct w32_display_info *));
static void x_draw_hollow_cursor P_ ((struct window *, struct glyph_row *));
***************
*** 1210,1218 ****
if (retval)
{
pcm->width = char_widths.abcA + char_widths.abcB + char_widths.abcC;
pcm->lbearing = char_widths.abcA;
! pcm->rbearing = pcm->width - char_widths.abcC;
pcm->ascent = FONT_BASE (font);
pcm->descent = FONT_DESCENT (font);
}
--- 1210,1229 ----
if (retval)
{
+ /* Don't trust the ABC widths. For synthesized fonts they are
+ wrong, and so is the result of GetCharWidth()! */
+ int real_width;
+ GetCharWidth (hdc, *char2b, *char2b, &real_width);
+
pcm->width = char_widths.abcA + char_widths.abcB + char_widths.abcC;
+
+ /* As far as I can tell, this is the best way to determine what
+ ExtTextOut will do with the broken font. */
+ if (pcm->width != real_width)
+ pcm->width = (pcm->width + real_width) / 2;
+
pcm->lbearing = char_widths.abcA;
! pcm->rbearing = char_widths.abcA + char_widths.abcB;
pcm->ascent = FONT_BASE (font);
pcm->descent = FONT_DESCENT (font);
}
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/04
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/04
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/04
- [Emacs-diffs] Changes to emacs/src/w32term.c, Pavel JanÃk, 2002/01/12
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/13
- [Emacs-diffs] Changes to emacs/src/w32term.c, Kim F. Storm, 2002/01/16
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/20
- [Emacs-diffs] Changes to emacs/src/w32term.c,
Jason Rumney <=
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/20
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/23
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/24
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/24
- [Emacs-diffs] Changes to emacs/src/w32term.c, Jason Rumney, 2002/01/26