Index: head/chinese/irssi/Makefile =================================================================== --- head/chinese/irssi/Makefile (revision 49411) +++ head/chinese/irssi/Makefile (revision 49412) @@ -1,24 +1,25 @@ # New ports collection makefile for: zh-tw-irssi # Date created: April 26 2001 # Whom: vanilla # # $FreeBSD$ # MASTERDIR= ${.CURDIR}/../../irc/irssi EXTRA_PATCHES= ${.CURDIR}/files/patch-config.h.in \ ${.CURDIR}/files/patch-configure.in \ ${.CURDIR}/files/patch-src_fe-text_gui-entry.c \ - ${.CURDIR}/files/patch-src_fe-text_screen.h + ${.CURDIR}/files/patch-src_fe-text_screen.h \ + ${.CURDIR}/files/patch-src_fe-text_wrap.c CATEGORIES= chinese MAINTAINER= vanilla@FreeBSD.org USE_AUTOCONF= yes CONFIGURE_ARGS+= --with-big5 .include "${MASTERDIR}/Makefile" PKGNAMEPREFIX:= ${PKGNAMEPREFIX}tw- COMMENT= ${.CURDIR}/pkg-comment Property changes on: head/chinese/irssi/Makefile ___________________________________________________________________ Modified: cvs2svn:cvs-rev ## -1 +1 ## -1.1 \ No newline at end of property +1.2 \ No newline at end of property Index: head/chinese/irssi/files/patch-src_fe-text_wrap.c =================================================================== --- head/chinese/irssi/files/patch-src_fe-text_wrap.c (nonexistent) +++ head/chinese/irssi/files/patch-src_fe-text_wrap.c (revision 49412) @@ -0,0 +1,57 @@ +--- src/fe-text/gui-windows.c.orig Mon Oct 29 20:51:52 2001 ++++ src/fe-text/gui-windows.c Tue Oct 30 01:48:09 2001 +@@ -289,6 +289,7 @@ + unsigned char cmd; + char *ptr, *last_space_ptr; + int xpos, pos, indent_pos, last_space, last_color, color; ++ int w = 0; + + g_return_val_if_fail(line->text != NULL, NULL); + +@@ -343,14 +344,14 @@ + continue; + } + +- if (xpos == COLS && sub != NULL && ++ if (xpos >= COLS && sub != NULL && + (last_space <= indent_pos || last_space <= 10)) { + /* long word, remove the indentation from this line */ + xpos -= sub->indent; + sub->indent = 0; + } + +- if (xpos == COLS) { ++ if (xpos >= COLS) { + xpos = indent_pos; + + sub = g_new(LINE_CACHE_SUB_REC, 1); +@@ -376,8 +377,27 @@ + continue; + } + +- xpos++; +- if (*ptr++ == ' ') { ++ if(ptr[1] != '\0' && is_big5(ptr[0], ptr[1])) ++ w = 2; ++ else ++ w = 1; ++ ++ xpos+=w; ++ if (*ptr == ' ' || ++ (xpos <= COLS && w > 1)) { ++ last_space = xpos-1; ++ last_space_ptr = ptr + w; ++ last_color = color; ++ } ++ if(xpos <= COLS) ++ ptr += w; ++ else ++ ptr ++; ++ ++ if(w == 1 && xpos <= COLS && ++ ptr[0] != '\0' && ptr[1] != '\0' && ++ is_big5(ptr[0], ptr[1])) ++ { + last_space = xpos-1; + last_space_ptr = ptr; + last_color = color; Property changes on: head/chinese/irssi/files/patch-src_fe-text_wrap.c ___________________________________________________________________ Added: cvs2svn:cvs-rev ## -0,0 +1 ## +1.1 \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property