diff options
author | nyamatongwe <devnull@localhost> | 2003-08-14 11:16:20 +0000 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2003-08-14 11:16:20 +0000 |
commit | a0d70703067f16bae80b6666156ee3ff66ff46f5 (patch) | |
tree | a93e176f8d418a860c114b6643b8b42e8e58790a /src | |
parent | 66e730976d262e895dcd5ad495ac1b0f687b1a77 (diff) | |
download | scintilla-mirror-a0d70703067f16bae80b6666156ee3ff66ff46f5.tar.gz |
Fixed bug where characters >= 128 were being displayed as
down arrows.
Diffstat (limited to 'src')
-rw-r--r-- | src/CallTip.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/CallTip.cxx b/src/CallTip.cxx index 314f9bfa7..2f299afff 100644 --- a/src/CallTip.cxx +++ b/src/CallTip.cxx @@ -48,6 +48,10 @@ void CallTip::RefreshColourPalette(Palette &pal, bool want) { pal.WantFind(colourLight, want); } +static bool IsArrowCharacter(char ch) { + return (ch >= 0) && (ch <= '\002'); +} + void CallTip::DrawChunk(Surface *surface, int &x, const char *s, int posStart, int posEnd, int ytext, PRectangle rcClient, bool highlight, bool draw) { @@ -56,7 +60,7 @@ void CallTip::DrawChunk(Surface *surface, int &x, const char *s, int maxEnd = 0; int ends[10]; for (int i=0;i<len;i++) { - if (s[i] <= '\002') { + if (IsArrowCharacter(s[i])) { if (i > 0) ends[maxEnd++] = i; ends[maxEnd++] = i+1; @@ -68,7 +72,7 @@ void CallTip::DrawChunk(Surface *surface, int &x, const char *s, for (int seg = 0; seg<maxEnd; seg++) { int endSeg = ends[seg]; if (endSeg > startSeg) { - if (s[startSeg] <= '\002') { + if (IsArrowCharacter(s[startSeg])) { xEnd = x + widthArrow; offsetMain = xEnd; if (draw) { |