• R/O
  • SSH

Commit

Tags
Keine Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#objective-cqt誰得cocoapythonrubywindowsphpgameguibathyscaphec翻訳omegatframework計画中(planning stage)twitterdombtronvb.nettestarduinodirectxpreviewerゲームエンジン

K.Takata's patch queue for Vim


Commit MetaInfo

Revision372d08a230fe8a34808a4ac95ef8bfb8d52bbad2 (tree)
Zeit2022-01-21 16:03:09
AutorK.Takata <kentkt@csc....>
CommiterK.Takata

Log Message

Update ambiwidth auto patch

Ändern Zusammenfassung

Diff

diff -r 460b270e52de -r 372d08a230fe wip-win32-directwrite-ambiwidth-auto.patch
--- a/wip-win32-directwrite-ambiwidth-auto.patch Fri Jan 21 14:50:15 2022 +0900
+++ b/wip-win32-directwrite-ambiwidth-auto.patch Fri Jan 21 16:03:09 2022 +0900
@@ -103,7 +103,7 @@
103103 diff --git a/src/gui_w32.c b/src/gui_w32.c
104104 --- a/src/gui_w32.c
105105 +++ b/src/gui_w32.c
106-@@ -5182,12 +5182,12 @@ error:
106+@@ -5182,21 +5182,21 @@ error:
107107
108108 #ifdef USE_AMBIWIDTH_AUTO
109109 # define CHARWIDE_CACHESIZE 0x20000
@@ -116,7 +116,18 @@
116116 + static GuiFont last_font = NOFONT;
117117 GuiFont usingfont = gui.wide_font ? gui.wide_font : gui.norm_font;
118118
119- /* Check validity of charwide cache */
119+- /* Check validity of charwide cache */
120++ /* Check validity of charwidth cache */
121+ if (last_font != usingfont)
122+ {
123+ /* Update cache. -1 is mark for uninitialized cell */
124+ int i;
125+
126+- TRACE("Charwide cache will be updated (base=%d)\n", gui.char_width);
127++ TRACE("Charwidth cache will be updated (base=%d)\n", gui.char_width);
128+ last_font = usingfont;
129+ for (i = 0; i < CHARWIDE_CACHESIZE; ++i)
130+ cache[i] = -1;
120131 @@ -5205,6 +5205,17 @@ gui_mch_get_charwidth(int c)
121132 {
122133 if (cache[c] >= 0)