diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 2003-06-15 04:13:17 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 2003-06-15 04:13:17 +0000 |
| commit | 1bde669d7517dead6d542c75c7aac37f8842d413 (patch) | |
| tree | 874ac3aca13bfb99dea188c8f1714e686456beae /src | |
| parent | 84b2499c38e5ddb1ab77bb6a0e68a814d2bf1e6c (diff) | |
Fix @@ drawing (STR #84)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3029 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/fl_draw.cxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/fl_draw.cxx b/src/fl_draw.cxx index f55c1fc75..3ecddec8f 100644 --- a/src/fl_draw.cxx +++ b/src/fl_draw.cxx @@ -1,5 +1,5 @@ // -// "$Id: fl_draw.cxx,v 1.6.2.4.2.13 2003/01/30 21:43:39 easysw Exp $" +// "$Id: fl_draw.cxx,v 1.6.2.4.2.14 2003/06/15 04:13:17 easysw Exp $" // // Label drawing code for the Fast Light Tool Kit (FLTK). // @@ -143,7 +143,7 @@ void fl_draw( symwidth[0] = min(w,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] = min(w,h); } @@ -156,7 +156,7 @@ void fl_draw( e = expand(p, buf, w - symtotal, buflen, width, align&FL_ALIGN_WRAP, draw_symbols); lines++; - if (!*e || (*e == '@' && draw_symbols)) break; + if (!*e || (*e == '@' && e[1] != '@' && draw_symbols)) break; p = e; } } else lines = 0; @@ -211,7 +211,7 @@ void fl_draw( if (underline_at) callthis("_",1,xpos+int(fl_width(buf,underline_at-buf)),ypos-desc); - if (!*e || *e == '@') break; + if (!*e || (*e == '@' && e[1] != '@')) break; p = e; } } @@ -325,5 +325,5 @@ void fl_measure(const char* str, int& w, int& h, int draw_symbols) { } // -// End of "$Id: fl_draw.cxx,v 1.6.2.4.2.13 2003/01/30 21:43:39 easysw Exp $". +// End of "$Id: fl_draw.cxx,v 1.6.2.4.2.14 2003/06/15 04:13:17 easysw Exp $". // |
