term_schedule_tblink(term); term_schedule_cblink(term);
void term_reconfig(Terminal *term, Config *cfg){    /*     * Before adopting the new config, check all those terminal     * settings which control power-on defaults; and if they've     * changed, we will modify the current state as well as the     * default one. The full list is: Auto wrap mode, DEC Origin     * Mode, BCE, blinking text, character classes.     */    int reset_wrap, reset_decom, reset_bce, reset_blink, reset_charclass;    int i;    reset_wrap = (term->cfg.wrap_mode != cfg->wrap_mode);    reset_decom = (term->cfg.dec_om != cfg->dec_om);    reset_bce = (term->cfg.bce != cfg->bce);    reset_blink = (term->cfg.blinktext != cfg->blinktext);    reset_charclass = 0;    for (i = 0; i < lenof(term->cfg.wordness); i++)	if (term->cfg.wordness[i] != cfg->wordness[i])	    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 */    if (reset_wrap)	term->alt_wrap = term->wrap = term->cfg.wrap_mode;    if (reset_decom)	term->alt_om = term->dec_om = term->cfg.dec_om;    if (reset_bce) {	term->use_bce = term->cfg.bce;	set_erase_char(term);    }    if (reset_blink)	term->blink_is_real = term->cfg.blinktext;    if (reset_charclass)	for (i = 0; i < 256; i++)	    term->wordness[i] = term->cfg.wordness[i];    if (term->cfg.no_alt_screen)	swap_screen(term, 0, FALSE, FALSE);    if (term->cfg.no_mouse_rep) {	term->xterm_mouse = 0;	set_raw_mouse_mode(term->frontend, 0);    }    if (term->cfg.no_remote_charset) {	term->cset_attr[0] = term->cset_attr[1] = CSET_ASCII;	term->sco_acs = term->alt_sco_acs = 0;	term->utf = 0;    }    if (!*term->cfg.printer) {	term_print_finish(term);    }}