tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: nvi i18n



hi, all.

> i'm just now reading wcurses source with this diff.
> and found following changes:
> ...
> may make default cursor position right place.
>
> but unfortunately moving cursor left or right (by pressing ``h'' and ''l'')
> might not work correctlly.


i found following patch make all good for wcwidth > 1 character.

Index: cr_put.c
===================================================================
RCS file: /cvsroot/src/lib/libcurses/cr_put.c,v
retrieving revision 1.25
diff -u -r1.25 cr_put.c
--- cr_put.c    28 May 2007 15:01:54 -0000      1.25
+++ cr_put.c    18 Jun 2008 05:11:44 -0000
@@ -409,9 +409,8 @@
                                    == curscr->wattr)
                                        __cputchar(i);
 #else
-                               if ((curscr->lines[outline]->line[outcol].attr
-                                   & WA_ATTRIBUTES)
-                                   == curscr->wattr ) {
+                               if ((curscr->lines[outline]->line[outcol].attr)
+                                   == curscr->wattr) {
                                        if 
(WCOL(curscr->lines[outline]->line[outcol]) > 0) {
                                                
__cputwchar(curscr->lines[outline]->line[outcol].ch);
                                                
__cursesi_putnsp(curscr->lines[outline]->line[outcol].nsp,



any comments?

very truly yours.
-- 
Takehiko NOZAKI <tnozaki%NetBSD.org@localhost>


Home | Main Index | Thread Index | Old Index