public
Last active

  • Download Gist
gistfile1.diff
Diff
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
diff -r 5759342cde79 src/gui_w32.c
--- a/src/gui_w32.c Mon Jun 24 22:33:30 2013 +0200
+++ b/src/gui_w32.c Wed Jun 26 09:33:08 2013 +0900
@@ -3216,7 +3216,7 @@
if (l == 1 && vim_iswhite(*pend)
&& textWidth > maxDialogWidth * 3 / 4)
last_white = pend;
- textWidth += GetTextWidth(hdc, pend, l);
+ textWidth += GetTextWidthEnc(hdc, pend, l);
if (textWidth >= maxDialogWidth)
{
/* Line will wrap. */
@@ -3282,7 +3282,7 @@
pend = vim_strchr(pstart, DLG_BUTTON_SEP);
if (pend == NULL)
pend = pstart + STRLEN(pstart); // Last button name.
- textWidth = GetTextWidth(hdc, pstart, (int)(pend - pstart));
+ textWidth = GetTextWidthEnc(hdc, pstart, (int)(pend - pstart));
if (textWidth < minButtonWidth)
textWidth = minButtonWidth;
textWidth += dlgPaddingX; /* Padding within button */
@@ -3307,7 +3307,7 @@
pend = vim_strchr(pstart, DLG_BUTTON_SEP);
if (pend == NULL)
pend = pstart + STRLEN(pstart); // Last button name.
- textWidth = GetTextWidth(hdc, pstart, (int)(pend - pstart));
+ textWidth = GetTextWidthEnc(hdc, pstart, (int)(pend - pstart));
textWidth += dlgPaddingX; /* Padding within button */
textWidth += DLG_VERT_PADDING_X * 2; /* Padding around button */
if (textWidth > dlgwidth)

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.