44 virtual void HScroll(
unsigned total,
unsigned visible,
unsigned start ) {}
49 virtual void VScroll(
unsigned total,
unsigned visible,
unsigned start ) {}
51 virtual void ScrollHead(
NCursesWindow & w,
unsigned ccol ) {}
53 virtual void AdjustPadSize(
wsze & minsze ) {}
76 redirect->ScrollHead( w, ccol );
79 void VSet(
unsigned total,
unsigned visible,
unsigned start )
81 redirect->
VScroll( total, visible, start );
84 void HSet(
unsigned total,
unsigned visible,
unsigned start )
86 redirect->
HScroll( total, visible, start );
89 virtual void SetPadSize(
wsze & minsze )
91 redirect->AdjustPadSize( minsze );
99 virtual void SendHead() {}
151 virtual int dirtyPad() { dirty =
false;
return setpos( CurPos() ); }
159 return setpos( CurPos() + offset );
162 virtual void updateScrollHint();
188 virtual void resize(
wsze nsze );
191 virtual int resize(
int lines,
int columns ) {
return NCursesWindow::resize(
lines, columns );}
192 virtual void wRecoded();
193 virtual void setDirty() { dirty =
true; }
198 virtual wpos CurPos()
const {
return srect.Pos; }
200 int ScrlTo(
const wpos & newpos )
217 int ScrlDown(
int lines = 1 )
222 int ScrlUp(
int lines = 1 )
227 int ScrlRight(
int cols = 1 )
232 int ScrlLeft(
int cols = 1 )
242 virtual bool handleInput( wint_t key );
C++ class for windows.
Definition: ncursesw.h:906
virtual void directDraw(NCursesWindow &w, const wrect at, unsigned lineno)
Definition: NCPad.h:173
int ScrlLine(int line)
Scroll to a line, keeping the column.
Definition: NCPad.h:206
int vheight() const
Definition: NCPad.h:146
static int lines()
Definition: ncursesw.h:1044
int height() const
Definition: ncursesw.h:1072
static int cols()
Definition: ncursesw.h:1049
int adjpos(const wpos &offset)
Adjust CurPos relatively by offset
Definition: NCPad.h:157
NCursesWindow * destwin
Destination rectangle: (Pos is always 0, 0)
Definition: NCPad.h:135
Screen position pair in the order line, column: (L, C)
Definition: position.h:109
virtual void HScroll(unsigned total, unsigned visible, unsigned start)
Definition: NCPad.h:44
NCPad(int lines, int cols, const NCWidget &p)
Definition: NCPad.cc:40
Interface for scroll callbacks.
Definition: NCPad.h:35
virtual int setpos(const wpos &newpos)
Set the visible position to newpos (but clamp by maxspos), then update.
Definition: NCPad.cc:158
A rectangle is defined by its position and size: wpos Pos, wsze Sze.
Definition: position.h:193
wrect srect
Source rectangle: the visible part of this pad.
Definition: NCPad.h:138
virtual void VScroll(unsigned total, unsigned visible, unsigned start)
Definition: NCPad.h:49
Screen dimension (screen size) in the order height, width: (H, W)
Definition: position.h:153
WINDOW * w
Definition: ncursesw.h:949
bool paging() const
Definition: NCPad.h:149
Definition: ncursesw.h:1831
int ScrlCol(int col)
Scroll to a column, keeping the line.
Definition: NCPad.h:212
bool dclear
should destwin be cleared before contents is copied there
Definition: NCPad.h:142