summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGreg Ercolano <erco@seriss.com>2024-03-11 12:57:45 -0700
committerGreg Ercolano <erco@seriss.com>2024-03-11 12:57:45 -0700
commitb1910ccfff81a1d8bc6a6126257d284d94e7f879 (patch)
tree7c04d1a7956f4074e0b877b21dd369abcf91f905
parent6668c7ef42b36259a9675c0c8fd38666443c2bc4 (diff)
Refit display rows/cols preset, remove test code
-rw-r--r--src/Fl_Terminal.cxx9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/Fl_Terminal.cxx b/src/Fl_Terminal.cxx
index 153b0a72d..2cd99e993 100644
--- a/src/Fl_Terminal.cxx
+++ b/src/Fl_Terminal.cxx
@@ -1483,6 +1483,7 @@ void Fl_Terminal::display_rows(int drows) {
if (drows == disp_rows()) return; // no change? early exit
ring_.resize(drows, disp_cols(), hist_rows(), *current_style_);
update_screen(false); // false: no font change ?NEED?
+ refit_disp_to_screen();
}
/**
@@ -1514,6 +1515,7 @@ void Fl_Terminal::display_columns(int dcols) {
// Change cols, preserves previous content if possible
ring_.resize(disp_rows(), dcols, hist_rows(), *current_style_);
update_screen(false); // false: no font change ?NEED?
+ refit_disp_to_screen();
}
/** Return reference to internal current style for rendering text. */
@@ -3655,13 +3657,6 @@ void Fl_Terminal::draw(void) {
current_style_->update(); // do deferred update here
update_screen(true); // update fonts
}
- // See if global scrollbar changed size, if so recalc
- if (scrollbar_size_ == 0 &&
- ( scrollbar->w() != Fl::scrollbar_size() ||
- hscrollbar->h() != Fl::scrollbar_size())) {
- update_scrollbar();
- refit_disp_to_screen();
- }
// Draw group first, terminal last
Fl_Group::draw();
// Draw that little square between the scrollbars: