properly paint multi-line color regexes when COLOR_SYNTAX is set
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1621
35c25a1d-7b9e-4130-9fde-
d3aeb78583b8
CVS code -
+- General:
+ - Change instances in the code that refresh the entire edit
+ window when color support is enabled (in order to properly
+ handle multi-line color regexes) to only do so when
+ it's necessary, i.e, when COLOR_SYNTAX is set. (DLR)
- nano.c:
main()
- Move the call to raw() on systems that don't define
#ifdef ENABLE_COLOR
update_color();
- edit_refresh();
+ if (ISSET(COLOR_SYNTAX))
+ edit_refresh();
#endif
}
#ifdef ENABLE_COLOR
update_color();
- edit_refresh();
+ if (ISSET(COLOR_SYNTAX))
+ edit_refresh();
#endif
}
filename = mallocstrcpy(filename, realname);
#ifdef ENABLE_COLOR
update_color();
- edit_refresh();
+ if (ISSET(COLOR_SYNTAX))
+ edit_refresh();
#endif
}
#endif
#ifdef ENABLE_COLOR
- refresh = 1;
+ if (ISSET(COLOR_SYNTAX))
+ refresh = 1;
#endif
#if !defined(DISABLE_WRAPPING) || defined(ENABLE_COLOR)
align(¤t->data);
#ifdef ENABLE_COLOR
- refresh = 1;
+ if (ISSET(COLOR_SYNTAX))
+ refresh = 1;
#endif
} else if (current->next != NULL && (current->next != filebot || blbf)) {
/* We can delete the line before filebot only if it is blank: it