[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Groff-commit] groff ChangeLog src/roff/troff/input.cpp
From: |
Werner LEMBERG |
Subject: |
[Groff-commit] groff ChangeLog src/roff/troff/input.cpp |
Date: |
Sat, 09 Sep 2006 15:11:24 +0000 |
CVSROOT: /cvsroot/groff
Module name: groff
Changes by: Werner LEMBERG <wl> 06/09/09 15:11:24
Modified files:
. : ChangeLog
src/roff/troff : input.cpp
Log message:
* src/roff/troff/input.cpp (read_size): Fix `\s[-\n[.s]]' so that it
behave the same as `\s-[\n[.s]]' (this is, emit a warning and set
point size to 1). Reported by Gunnar Ritter.
Also catch `\s-[-...]' and friends (causing an error).
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/groff/ChangeLog?cvsroot=groff&r1=1.991&r2=1.992
http://cvs.savannah.gnu.org/viewcvs/groff/src/roff/troff/input.cpp?cvsroot=groff&r1=1.40&r2=1.41
Patches:
Index: ChangeLog
===================================================================
RCS file: /cvsroot/groff/groff/ChangeLog,v
retrieving revision 1.991
retrieving revision 1.992
diff -u -b -r1.991 -r1.992
--- ChangeLog 6 Sep 2006 15:27:01 -0000 1.991
+++ ChangeLog 9 Sep 2006 15:11:24 -0000 1.992
@@ -1,3 +1,10 @@
+2006-09-09 Werner LEMBERG <address@hidden>
+
+ * src/roff/troff/input.cpp (read_size): Fix `\s[-\n[.s]]' so that it
+ behave the same as `\s-[\n[.s]]' (this is, emit a warning and set
+ point size to 1). Reported by Gunnar Ritter.
+ Also catch `\s-[-...]' and friends (causing an error).
+
2006-09-06 Werner LEMBERG <address@hidden>
* src/roff/troff/env.cpp (environment::do_break): Insert zero-width
Index: src/roff/troff/input.cpp
===================================================================
RCS file: /cvsroot/groff/groff/src/roff/troff/input.cpp,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -b -r1.40 -r1.41
--- src/roff/troff/input.cpp 29 Jun 2006 09:09:18 -0000 1.40
+++ src/roff/troff/input.cpp 9 Sep 2006 15:11:24 -0000 1.41
@@ -4902,9 +4902,19 @@
else {
token start(tok);
tok.next();
- if (!(inc
- ? get_number(&val, 'z')
- : get_number(&val, 'z', curenv->get_requested_point_size())))
+ // catch `\s-[-...]' and friends
+ c = tok.ch();
+ if (c == '-' || c == '+') {
+ if (inc) {
+ error("two relative changes not allowed in \\s escape");
+ return 0;
+ }
+ else {
+ inc = c == '+' ? 1 : -1;
+ tok.next();
+ }
+ }
+ if (!get_number(&val, 'z'))
return 0;
if (!(start.ch() == '[' && tok.ch() == ']') && start != tok) {
if (start.ch() == '[')
@@ -4935,7 +4945,7 @@
}
if (*x <= 0) {
warning(WARN_RANGE,
- "\\s request results in non-positive point size; set to 1");
+ "\\s escape results in non-positive point size; set to 1");
*x = 1;
}
return 1;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Groff-commit] groff ChangeLog src/roff/troff/input.cpp,
Werner LEMBERG <=