Skip to content

Commit

Permalink
Merge branch 'garbled_char'
Browse files Browse the repository at this point in the history
  • Loading branch information
zmatsuo committed Mar 10, 2024
2 parents 23919e3 + 941272b commit 0098cde
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 15 deletions.
1 change: 1 addition & 0 deletions doc/en/html/about/history.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ <h3 id="teraterm_5.3">YYYY.MM.DD (Ver 5.3 not released yet)</h3>
<li>Fixed text color to be gray instead of black when SGR 1 + SGR 30(Bold + FG Black).</li>
<li>Fixed same repeated characters are selected when double click on delimiter character.(Fixed select behavior that changed in 5.2 to be same as before.)</li>
<li>MACRO: fixed file name is garbled in status window when Kanji characters are included.</li>
<li>Fixed to repetition of surrogate pair characters correctly display when "Drawing resized font to fit cell width" is on.</li>
</ul>
</li>

Expand Down
1 change: 1 addition & 0 deletions doc/ja/html/about/history.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ <h3 id="teraterm_5.3">YYYY.MM.DD (Ver 5.3 not released yet)</h3>
<li>SGR 1 + SGR 30(強調+文字色黒)のとき、文字色を黒ではなく灰色で表示するよう修正した。</li>
<li>区切り文字をダブルクリックしたとき、連続した同一文字を選択するよう修正した(5.2で変わってしまった選択動作を従来と同じ動作となるよう修正した)。</li>
<li>MACRO: ステータスウィンドウのマクロファイル名が文字化けする場合があったので修正した。</li>
<li>"Drawing resized font to fit cell width"がonのとき、サロゲートペアの文字が連続した場合でも正しく表示するよう修正した。</li>
</ul>
</li>

Expand Down
17 changes: 2 additions & 15 deletions teraterm/teraterm/vtdisp.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,7 @@ typedef struct {
BOOL bg_enable;
BYTE alpha_vtback;
BYTE alpha_back;
BOOL debug_drawbox_text;
BOOL debug_drawbox_fillrect;
BOOL debug_drawbox_text; // 文字描画毎にboxを描画する
//
BYTE DCBackAlpha;
COLORREF DCBackColor;
Expand Down Expand Up @@ -1703,7 +1702,6 @@ void InitDisp(void)
w->alpha_back = 255;
w->alpha_vtback = 255;
w->debug_drawbox_text = FALSE;
w->debug_drawbox_fillrect = FALSE;
w->font_resize_enable = FontReSizeEnableInit;
BGReverseTextAlpha = 255;
}
Expand Down Expand Up @@ -2894,22 +2892,11 @@ void DrawStrW(HDC DC, HDC BGDC, const wchar_t *StrW, const char *cells, int len,
start_idx = i;
cell_count = 0;
wchar_count = 0;
zero_count = 0;
}
wchar_count++;
zero_count++;
}
#if 0
else if (zero_count > 2) {
wchar_count++;
cell_count += cells[i];
DrawStrWSub(DC, BGDC, &StrW[start_idx], &Dx[start_idx], wchar_count, cell_count, font_width,
font_height, Y, X);
start_idx = i;
zero_count = 0;
cell_count = 0;
wchar_count = 1;
}
#endif
else {
SIZE size;
GetTextExtentPoint32W(DC, &StrW[i - zero_count], 1 + zero_count, &size);
Expand Down

0 comments on commit 0098cde

Please sign in to comment.