summaryrefslogtreecommitdiff
path: root/test/symbols.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2004-08-09 21:05:45 +0000
committerMatthias Melcher <fltk@matthiasm.com>2004-08-09 21:05:45 +0000
commit522f98d5230e78f983ffcc8f05391c060661cf1a (patch)
treee207037fa8233eeb7e4f79b9287b3fbc6293de88 /test/symbols.cxx
parent504abf708fdcddd938537de1ec1fa7bdbbf0120c (diff)
Str #490: fixed little bug in Symbol test code
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3774 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'test/symbols.cxx')
-rw-r--r--test/symbols.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/symbols.cxx b/test/symbols.cxx
index c3d0acf4f..6500eef54 100644
--- a/test/symbols.cxx
+++ b/test/symbols.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: symbols.cxx,v 1.4.2.3.2.7 2004/07/04 06:49:34 matthiaswm Exp $"
+// "$Id: symbols.cxx,v 1.4.2.3.2.8 2004/08/09 21:05:45 matthiaswm Exp $"
//
// Symbol test program for the Fast Light Tool Kit (FLTK).
//
@@ -53,13 +53,13 @@ void slider_cb(Fl_Widget *w, void *) {
if ( *l == '@' ) { // all children with '@'
if ( *(++l) == '@' ) { // ascii legend?
l++;
- while (isdigit(*l)||*l=='+'||*l=='-') { l++; }
+ while (isdigit(*l)||(*l=='+'&&l[1])||*l=='-') { l++; }
if (val&&sze) sprintf(buf, "@@%+d%d%s", sze, val, l);
else if (val) sprintf(buf, "@@%d%s", val, l);
else if (sze) sprintf(buf, "@@%+d%s", sze, l);
else sprintf(buf, "@@%s", l);
} else { // box with symbol
- while (isdigit(*l)||*l=='+'||*l=='-') { l++; }
+ while (isdigit(*l)||(*l=='+'&&l[1])||*l=='-') { l++; }
if (val&&sze) sprintf(buf, "@%+d%d%s", sze, val, l);
else if (val) sprintf(buf, "@%d%s", val, l);
else if (sze) sprintf(buf, "@%+d%s", sze, l);
@@ -141,5 +141,5 @@ bt("@FLTK");
}
//
-// End of "$Id: symbols.cxx,v 1.4.2.3.2.7 2004/07/04 06:49:34 matthiaswm Exp $".
+// End of "$Id: symbols.cxx,v 1.4.2.3.2.8 2004/08/09 21:05:45 matthiaswm Exp $".
//