Commit c85dc059 authored by Benno Schulenberg's avatar Benno Schulenberg
Browse files

Using prettier whitespace characters when in a UTF-8 locale.

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4644 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Showing with 15 additions and 5 deletions
+15 -5
2014-03-14 Benno Schulenberg <bensberg@justemail.net>
* src/nano.c (main) - When in a UTF-8 locale, use prettier characters
(»·) for indicating whitespace, and for similarity use ">." instead of
":." when not in a UTF-8 locale. Changes suggested by Mike Frysinger.
2014-03-05 Benno Schulenberg <bensberg@justemail.net>
* src/move.c (do_down) - Initialize the correct variable to zero.
Solves jumpy scrolling behaviour reported by Chris Allegretta .
......
......@@ -2576,11 +2576,16 @@ int main(int argc, char **argv)
#if !defined(NANO_TINY) && defined(ENABLE_NANORC)
/* If whitespace wasn't specified, set its default value. */
if (whitespace == NULL) {
whitespace = mallocstrcpy(NULL, ":.");
whitespace_len[0] = 1;
whitespace_len[1] = 1;
}
if (whitespace == NULL)
if (using_utf8()) {
whitespace = mallocstrcpy(NULL, "»·");
whitespace_len[0] = 2;
whitespace_len[1] = 2;
} else {
whitespace = mallocstrcpy(NULL, ">.");
whitespace_len[0] = 1;
whitespace_len[1] = 1;
}
#endif
/* If tabsize wasn't specified, set its default value. */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment