OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
owl::TFlatScroller Class Reference

Class TFlatScroller implements the actual scroller object. More...

#include <owl/fscroll.h>

Inheritance diagram for owl::TFlatScroller:
owl::TScroller owl::TStreamableBase

Public Member Functions

 TFlatScroller (TWindow *window, int xUnit, int yUnit, long xRange, long yRange)
 
virtual ~TFlatScroller ()
 
virtual void SetWindow (TWindow *win)
 
virtual bool EnableScrollBar (uint flags=SB_BOTH, uint arrow=ESB_ENABLE_BOTH)
 
virtual void ShowScrollBar (int code, bool show=true)
 
void EnableFlatStyle (bool enable=true)
 
bool GetScrollProp (uint index, int &value)
 
bool SetScrollProp (uint index, int value, bool redraw=true)
 
- Public Member Functions inherited from owl::TScroller
 TScroller (TWindow *window, int xUnit, int yUnit, long xRange, long yRange)
 Constructs a TScroller object with window as the owner window, and xUnit, yUnit, xRange, and yRange as xUnit, yUnit, xRange and yRange, respectively.
 
virtual ~TScroller ()
 Destructs a TScroller object. Sets owning window's Scroller number variable to 0.
 
virtual void SetUnits (int xUnit, int yUnit)
 Sets the XUnit and YUnit data members to TheXUnit and TheYUnit, respectively.
 
virtual void SetPageSize ()
 Sets the XPage and YPage data members (amount by which to scroll on a page scroll request) to the width and height (in XUnits and YUnits) of the owner window's client area.
 
virtual void SetSBarRange ()
 Sets the range of the owner window's scroll bars to match the range of the TScroller and repaints as necessary.
 
virtual void SetRange (long xRange, long yRange)
 Sets the xRange and yRange of the TScroller to the parameters specified.
 
virtual void SetTotalRangeOfUnits (long xTotalUnits, long yTotalUnits)
 
virtual void BeginView (TDC &dc, TRect &rect)
 If TScroller_AutoOrg is true (default condition), BeginView automatically offsets the origin of the logical coordinates of the client area by XPos, YPos during a paint operation.
 
virtual void EndView ()
 Updates the position of the owner window's scroll bars to be coordinated with the position of the TScroller.
 
virtual void VScroll (uint scrollEvent, int thumbPos)
 Responds to the specified vertical scrollEvent by calling ScrollBy or ScrollTo.
 
virtual void HScroll (uint scrollEvent, int thumbPos)
 Responds to the specified horizontal scrollEvent by calling ScrollBy or ScrollTo.
 
virtual void ScrollTo (long x, long y)
 Scrolls the rectangle to the position specified in x and y after checking boundary conditions.
 
void ScrollBy (long dx, long dy)
 Scrolls to a position calculated using the passed delta values.
 
virtual bool IsAutoMode ()
 IsAutoMode is true if automatic scrolling is activated.
 
virtual void AutoScroll ()
 Performs "auto-scrolling" (dragging the mouse from within the client client area of the Window to without results in auto-scrolling when the AutoMode data member of the Scroller is true)
 
bool IsVisibleRect (long x, long y, int xExt, int yExt)
 Returns a bool value indicating whether or not the passed area (in units) is currently visible.
 
- Public Member Functions inherited from owl::TStreamableBase
virtual ~TStreamableBase ()
 

Protected Member Functions

virtual void SetScrollPage (int bar, int page, bool redraw=true)
 
virtual int GetScrollPage (int bar) const
 
virtual void GetScrollRange (int bar, int &minPos, int &maxPos) const
 
virtual void SetScrollRange (int bar, int minPos, int maxPos, bool redraw=true)
 
virtual int GetScrollPos (int bar) const
 
virtual int SetScrollPos (int bar, int pos, bool redraw=true)
 
virtual int GetScrollTrackPos (int bar) const
 

Additional Inherited Members

- Public Attributes inherited from owl::TScroller
TWindowWindow
 Points to the window whose client area scroller is to be managed.
 
long XPos
 Specifies the current position of the rectangle in horizontal scroll units.
 
long YPos
 Specifies the current position of the rectangle in vertical scroll units.
 
long XRange
 Specifies the number of horizontal scroll units.
 
long YRange
 Specifies the number of vertical scroll units.
 
long XTotalUnits
 Total number of horizontal scroll units.
 
long YTotalUnits
 Total number of vertical scroll units.
 
int XUnit
 Specifies the amount (in logical device units) to scroll the rectangle in the horizontal (X) direction.
 
int YUnit
 Specifies the amount (in logical device units) to scroll the rectangle in the vertical (Y) direction.
 
int XLine
 Specifies the number of logical device units per line to scroll the rectangle in the horizontal (X) direction.
 
int YLine
 Specifies the number of logical device units per line to scroll the rectangle in the vertical (Y) direction.
 
int XPage
 Specifies the number of logical device units per page to scroll the rectangle in the horizontal (X) direction.
 
int YPage
 Specifies the number of logical device units per page to scroll the rectangle in the vertical (Y) direction.
 
bool AutoMode
 Is true if automatic scrolling is activated.
 
bool TrackMode
 Is true if track scrolling is activated.
 
bool AutoOrg
 Is true if scroller offsets origin.
 
bool HasHScrollBar
 Is true if scroller has horizontal scroll.
 
bool HasVScrollBar
 Is true if scroller has vertical scroll.
 

Detailed Description

Class TFlatScroller implements the actual scroller object.

All functions are inline or virtual to avoid pulling in code when no scrollers have been constructed.

Definition at line 32 of file fscroll.h.

Constructor & Destructor Documentation

◆ TFlatScroller()

owl::TFlatScroller::TFlatScroller ( TWindow * window,
int xUnit,
int yUnit,
long xRange,
long yRange )

Definition at line 39 of file fscroll.cpp.

◆ ~TFlatScroller()

owl::TFlatScroller::~TFlatScroller ( )
virtual

Definition at line 52 of file fscroll.cpp.

Member Function Documentation

◆ EnableFlatStyle()

void owl::TFlatScroller::EnableFlatStyle ( bool enable = true)
inline

Definition at line 77 of file fscroll.h.

References owl::TWindow::GetHandle(), and owl::TScroller::Window.

◆ EnableScrollBar()

bool owl::TFlatScroller::EnableScrollBar ( uint flags = SB_BOTH,
uint arrow = ESB_ENABLE_BOTH )
inlinevirtual

Reimplemented from owl::TScroller.

Definition at line 102 of file fscroll.h.

References owl::TWindow::GetHandle(), PRECONDITION, and owl::TScroller::Window.

◆ GetScrollPage()

int owl::TFlatScroller::GetScrollPage ( int bar) const
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 66 of file fscroll.cpp.

References owl::TScroller::Window.

◆ GetScrollPos()

int owl::TFlatScroller::GetScrollPos ( int bar) const
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 93 of file fscroll.cpp.

References owl::TScroller::Window.

◆ GetScrollProp()

bool owl::TFlatScroller::GetScrollProp ( uint index,
int & value )
inline

Definition at line 88 of file fscroll.h.

References owl::TWindow::GetHandle(), PRECONDITION, and owl::TScroller::Window.

◆ GetScrollRange()

void owl::TFlatScroller::GetScrollRange ( int bar,
int & minPos,
int & maxPos ) const
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 74 of file fscroll.cpp.

References owl::TScroller::Window.

◆ GetScrollTrackPos()

int owl::TFlatScroller::GetScrollTrackPos ( int bar) const
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 109 of file fscroll.cpp.

References owl::TScroller::Window.

◆ SetScrollPage()

void owl::TFlatScroller::SetScrollPage ( int bar,
int page,
bool redraw = true )
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 58 of file fscroll.cpp.

References owl::TScroller::Window.

◆ SetScrollPos()

int owl::TFlatScroller::SetScrollPos ( int bar,
int pos,
bool redraw = true )
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 101 of file fscroll.cpp.

References owl::TScroller::Window.

◆ SetScrollProp()

bool owl::TFlatScroller::SetScrollProp ( uint index,
int value,
bool redraw = true )
inline

Definition at line 95 of file fscroll.h.

References owl::TWindow::GetHandle(), PRECONDITION, and owl::TScroller::Window.

◆ SetScrollRange()

void owl::TFlatScroller::SetScrollRange ( int bar,
int minPos,
int maxPos,
bool redraw = true )
protectedvirtual

Reimplemented from owl::TScroller.

Definition at line 84 of file fscroll.cpp.

References owl::TScroller::Window.

◆ SetWindow()

void owl::TFlatScroller::SetWindow ( TWindow * win)
inlinevirtual

Reimplemented from owl::TScroller.

Definition at line 70 of file fscroll.h.

References EnableFlatStyle(), and owl::TScroller::SetWindow().

◆ ShowScrollBar()

void owl::TFlatScroller::ShowScrollBar ( int code,
bool show = true )
inlinevirtual

Reimplemented from owl::TScroller.

Definition at line 109 of file fscroll.h.

References owl::TWindow::GetHandle(), PRECONDITION, and owl::TScroller::Window.


The documentation for this class was generated from the following files: