diff options
author | Steve Slaven <bpk@hoopajoo.net> | 2005-03-22 00:17:00 (GMT) |
---|---|---|
committer | Steve Slaven <bpk@hoopajoo.net> | 2005-03-22 00:17:00 (GMT) |
commit | 58bb541d08a0efa32ec8d1f3265209ca3f3c8435 (patch) | |
tree | df69bd549986b09f83dc8d26e07c9a3d299dc204 | |
parent | 41199241f4d878c24c9b6d7977b56ad562d0064f (diff) | |
download | powwow-58bb541d08a0efa32ec8d1f3265209ca3f3c8435.zip powwow-58bb541d08a0efa32ec8d1f3265209ca3f3c8435.tar.gz powwow-58bb541d08a0efa32ec8d1f3265209ca3f3c8435.tar.bz2 |
Added 1.2.8 news, fixed but in upcase/downcase word (Dain)
-rw-r--r-- | NEWS | 5 | ||||
-rw-r--r-- | edit.c | 32 |
2 files changed, 22 insertions, 15 deletions
@@ -0,0 +1,5 @@ +1.2.8 Mar-21-2005 +- Incorporated patch for locale support and some cleanup from Dain +- Fixed #module to use RLTD_GLOBAL so that symbols from modules ar + available to other modules +- Minor bugfixes and documentation fixes @@ -687,17 +687,18 @@ void del_word_left __P1 (char *,dummy) void upcase_word __P1 (char *,dummy) { int opos = pos; + int npos = pos; if (last_edit_cmd == (function_any)upcase_word) - pos = 0; + npos = 0; else { - while (pos > 0 && IS_DELIM(edbuf[pos])) pos--; - while (pos > 0 && !IS_DELIM(edbuf[pos - 1])) pos--; + while (npos > 0 && IS_DELIM(edbuf[npos])) npos--; + while (npos > 0 && !IS_DELIM(edbuf[npos - 1])) npos--; } - input_moveto(pos); - while (!IS_DELIM(edbuf[pos]) || - (last_edit_cmd == (function_any)upcase_word && edbuf[pos])) - input_overtype_follow(toupper(edbuf[pos])); + input_moveto(npos); + while (!IS_DELIM(edbuf[npos]) || + (last_edit_cmd == (function_any)upcase_word && edbuf[npos])) + input_overtype_follow(toupper(edbuf[npos++])); input_moveto(opos); } @@ -707,17 +708,18 @@ void upcase_word __P1 (char *,dummy) void downcase_word __P1 (char *,dummy) { int opos = pos; - + int npos = pos; + if (last_edit_cmd == (function_any)downcase_word) - pos = 0; + npos = 0; else { - while (pos > 0 && IS_DELIM(edbuf[pos])) pos--; - while (pos > 0 && !IS_DELIM(edbuf[pos - 1])) pos--; + while (npos > 0 && IS_DELIM(edbuf[npos])) npos--; + while (npos > 0 && !IS_DELIM(edbuf[npos - 1])) npos--; } - input_moveto(pos); - while (!IS_DELIM(edbuf[pos]) || - (last_edit_cmd == (function_any)downcase_word && edbuf[pos])) { - input_overtype_follow(tolower(edbuf[pos])); + input_moveto(npos); + while (!IS_DELIM(edbuf[npos]) || + (last_edit_cmd == (function_any)downcase_word && edbuf[npos])) { + input_overtype_follow(tolower(edbuf[npos++])); } input_moveto(opos); } |