Author: matt
Date: 2011-09-30 03:20:09 -0700 (Fri, 30 Sep 2011)
New Revision: 9094
Log:
Text area width needs to be recalculated if vertical scrollbar changes
visibility.
Modified:
branches/branch-1.3/src/Fl_Text_Display.cxx
Modified: branches/branch-1.3/src/Fl_Text_Display.cxx
===================================================================
--- branches/branch-1.3/src/Fl_Text_Display.cxx 2011-09-30 10:20:03 UTC (rev
9093)
+++ branches/branch-1.3/src/Fl_Text_Display.cxx 2011-09-30 10:20:09 UTC (rev
9094)
@@ -295,6 +295,7 @@
text_area.y = Y+TOP_MARGIN;
text_area.w = W-LEFT_MARGIN-RIGHT_MARGIN;
text_area.h = H-TOP_MARGIN-BOTTOM_MARGIN;
+ const int oldTAWidth = text_area.w;
int i;
/* Find the new maximum font height for this text display */
@@ -341,6 +342,7 @@
// figure the scrollbars
if (scrollbar_width()) {
/* Decide if the vertical scrollbar needs to be visible */
+ int vbvis = mVScrollBar->visible();
if (scrollbar_align() & (FL_ALIGN_LEFT|FL_ALIGN_RIGHT) &&
mNBufferLines >= mNVisibleLines - 1)
{
@@ -357,6 +359,7 @@
scrollbar_width(),
text_area.h+TOP_MARGIN+BOTTOM_MARGIN);
}
}
+ if (vbvis != mVScrollBar->visible()) again = 1;
/*
Decide if the horizontal scrollbar needs to be visible. If the text
_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit