Author: manolo
Date: 2010-12-18 00:32:37 -0800 (Sat, 18 Dec 2010)
New Revision: 8052
Log:
Fix STR #2486: cursor position was wrong in some tab-containing wrapped lines.
Modified:
branches/branch-1.3/src/Fl_Input_.cxx
Modified: branches/branch-1.3/src/Fl_Input_.cxx
===================================================================
--- branches/branch-1.3/src/Fl_Input_.cxx 2010-12-17 15:06:25 UTC (rev
8051)
+++ branches/branch-1.3/src/Fl_Input_.cxx 2010-12-18 08:32:37 UTC (rev
8052)
@@ -358,6 +358,8 @@
if (Fl::focus() == this && selstart == selend &&
position() >= p-value() && position() <= e-value()) {
fl_color(cursor_color());
+ // cursor position may need to be recomputed (see STR #2486)
+ curx = int(expandpos(p, value()+position(), buf, 0)+.5);
if (readonly()) {
fl_line((int)(xpos+curx-2.5f), Y+ypos+height-1,
(int)(xpos+curx+0.5f), Y+ypos+height-4,
_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit