summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGES2
-rw-r--r--src/fl_draw.cxx2
2 files changed, 3 insertions, 1 deletions
diff --git a/CHANGES b/CHANGES
index 156071721..3fbab9522 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,7 @@
CHANGES IN FLTK 1.1.8
+ - Fixed fl_measure which mistook a trailing '@@'
+ for a symbol (STR #1406)
- Fixed GLUT behavior on window creation (STR #1403)
- Fixed OS X bug that would hide tooltips before
they were shown (STR #1392)
diff --git a/src/fl_draw.cxx b/src/fl_draw.cxx
index 762a33b47..d1fe15839 100644
--- a/src/fl_draw.cxx
+++ b/src/fl_draw.cxx
@@ -305,7 +305,7 @@ void fl_measure(const char* str, int& w, int& h, int draw_symbols) {
symwidth[0] = h;
}
- if (str && (p = strrchr(str, '@')) != NULL && p > (str + 1)) {
+ if (str && (p = strrchr(str, '@')) != NULL && p > (str + 1) && p[-1]!='@') {
strlcpy(symbol[1], p, sizeof(symbol[1]));
symwidth[1] = h;
}