1 --- dml-0.1.6.new/src/slang.c.old 2007-10-04 22:03:19.000000000 +0200
2 +++ dml-0.1.6.new/src/slang.c 2007-10-04 23:47:06.000000000 +0200
4 char *pi_conf_file = "/etc/dml.conf";
5 int pi_screen_height, pi_screen_width;
6 int pi_poor_man_frames = 0;
13 if (*s == '_' && s[1]) {
16 + s = pi_putch_utf8(++s);
21 + s = pi_putch_utf8(s);
27 if (*s == '_' && s[1]) {
30 + s = pi_putch_utf8(++s);
35 + s = pi_putch_utf8(s);
43 + SLutf8_enable(pi_utf8);
45 if (SLkp_init() == -1)
46 pi_die("Unable to initialize SLkp.");
48 SLsmg_write_char((unsigned)c & 0xff);
51 +unsigned char *pi_putch_utf8(unsigned char *c)
54 + SLsmg_write_nstring(c, 1);
55 + return SLutf8_skip_char(c, c + 7);
62 void pi_addstr(const char *c)
64 SLsmg_write_string((char*)c);
65 --- dml-0.1.6.new/src/main.c.old 2007-10-04 23:36:10.000000000 +0200
66 +++ dml-0.1.6.new/src/main.c 2007-10-04 23:39:06.000000000 +0200
71 +#include <langinfo.h>
81 static void usage(int err, char *name)
87 + setlocale(LC_ALL, "");
88 + pi_utf8 = !strcmp(nl_langinfo(CODESET), "UTF-8");
89 parse_options(argc, argv);
91 /* this is to allow Shift+PgUp to look at displayed error
92 --- dml-0.1.6.new/src/pi.h.old 2007-10-04 23:49:16.000000000 +0200
93 +++ dml-0.1.6.new/src/pi.h 2007-10-04 22:52:59.000000000 +0200
95 void pi_goto(int x, int y);
96 void pi_frame(int x, int y, int w, int h);
98 +unsigned char *pi_putch_utf8(unsigned char *c);
99 void pi_addstr(const char *c);
100 void pi_addstrn(const char *c, int n);
101 void pi_addstrn_fill(const char *c, int n);