mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-26 09:42:25 +00:00
Don't forget to flush the bidi cache when the user enables or
disables bidi or shaping, otherwise they'll have to do a manual screen refresh to see any difference. [originally from svn r4632]
This commit is contained in:
parent
6b136f5c2f
commit
9b37d130ed
16
terminal.c
16
terminal.c
@ -1134,6 +1134,22 @@ void term_reconfig(Terminal *term, Config *cfg)
|
|||||||
if (term->cfg.wordness[i] != cfg->wordness[i])
|
if (term->cfg.wordness[i] != cfg->wordness[i])
|
||||||
reset_charclass = 1;
|
reset_charclass = 1;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* If the bidi or shaping settings have changed, flush the bidi
|
||||||
|
* cache completely.
|
||||||
|
*/
|
||||||
|
if (term->cfg.arabicshaping != cfg->arabicshaping ||
|
||||||
|
term->cfg.bidi != cfg->bidi) {
|
||||||
|
for (i = 0; i < term->bidi_cache_size; i++) {
|
||||||
|
sfree(term->pre_bidi_cache[i].chars);
|
||||||
|
sfree(term->post_bidi_cache[i].chars);
|
||||||
|
term->pre_bidi_cache[i].width = -1;
|
||||||
|
term->pre_bidi_cache[i].chars = NULL;
|
||||||
|
term->post_bidi_cache[i].width = -1;
|
||||||
|
term->post_bidi_cache[i].chars = NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
term->cfg = *cfg; /* STRUCTURE COPY */
|
term->cfg = *cfg; /* STRUCTURE COPY */
|
||||||
|
|
||||||
if (reset_wrap)
|
if (reset_wrap)
|
||||||
|
Loading…
Reference in New Issue
Block a user