From 3142eb2fda9f24910ddfbc9160653473df05c72c Mon Sep 17 00:00:00 2001 From: Greg Ercolano Date: Mon, 15 Jan 2024 14:15:00 -0800 Subject: Small code fixups > Enabled -Wall -Wextra -Wpedantic to catch errors - Silenced resulting "unused parameters" warnings - Fixed char omission in protected Fl_Terminal::insert_char() methods > Self doc code and better comments in RingBuffer::resize() > Changed private RingBuffer::clear_disp_row() -> clear_disp_rows() > Added private RingBuffer::hist_rows()/disp_rows() setter methods > Added private RingBuffer::offset_adjust() method for adjusting RingBuffer offset_ > Fixed comment typos > Remove white space inside outer parens of while()/if()/etc --- FL/Fl_Terminal.H | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'FL') diff --git a/FL/Fl_Terminal.H b/FL/Fl_Terminal.H index e012c061f..06a8b211f 100644 --- a/FL/Fl_Terminal.H +++ b/FL/Fl_Terminal.H @@ -616,6 +616,10 @@ private: inline int disp_srow(void) const { return((offset_ + hist_rows_) % ring_rows_); } inline int disp_erow(void) const { return((offset_ + hist_rows_ + disp_rows_ - 1) % ring_rows_); } inline int offset(void) const { return offset_; } + void offset_adjust(int rows); + void hist_rows(int val) { hist_rows_ = val; } + void disp_rows(int val) { disp_rows_ = val; } + // History use inline int hist_use(void) const { return hist_use_; } inline void hist_use(int val) { hist_use_ = val; } @@ -627,7 +631,7 @@ private: bool is_disp_ring_row(int grow) const; //DEBUG void show_ring_info(void) const; void move_disp_row(int src_row, int dst_row); - void clear_disp_row(int drow, const CharStyle& style); + void clear_disp_rows(int sdrow, int edrow, const CharStyle& style); void scroll(int rows, const CharStyle& style); const Utf8Char* u8c_ring_row(int row) const; -- cgit v1.2.3