- Main Page
- Classes
- Files
- Related Pages

- Class List
- Class Hierarchy
- Class Members

# CScrollView Class Reference

a scrollable view More...

`#include <cscrollview.h>`

Inheritance diagram for CScrollView:

List of all members.

## Public Types
enum | { kHorizontalScrollbar = 1 << 1, kVerticalScrollbar = 1 << 2 }
## Public Member Functions
| CScrollView (const CRect &size, const CRect &containerSize, CFrame *pParent, long style, long scrollbarWidth=16, CBitmap *pBackground=0)
virtual | ~CScrollView ()
virtual void | setContainerSize (const CRect &cs)
| set the virtual size of this container
virtual void | addView (CView *pView)
| add a child view
virtual void | drawBackgroundRect (CDrawContext *pContext, CRect &_updateRect)
| draw the background
virtual bool | onWheel (CDrawContext *pContext, const CPoint &where, const CMouseWheelAxis axis, float distance)
| called if a mouse wheel event is happening over this view
virtual void | valueChanged (CDrawContext *pContext, CControl *pControl)
virtual CScrollbar * | getVerticalScrollbar () const
virtual CScrollbar * | getHorizontalScrollbar () const
## Protected Attributes
CScrollContainer * | sc
CScrollbar * | vsb
CScrollbar * | hsb
CRect | containerSize
long | style

## Detailed Description

a scrollable view

## Member Enumeration Documentation

anonymous enum

  | Enumerator:
  kHorizontalScrollbar | add a horizontal scrollbar
  kVerticalScrollbar | add a vertical scrollbar

## Constructor & Destructor Documentation

CScrollView::CScrollView | ( | const CRect & | size,
|  | const CRect & | containerSize,
|  | CFrame * | pParent,
|  | long | style,
|  | long | scrollbarWidth = `16`,
|  | CBitmap * | pBackground = `0`
| ) |

CScrollView::~CScrollView | ( |  | ) | `[virtual]`

## Member Function Documentation

void CScrollView::addView | ( | CView * | pView | ) | `[virtual]`

  | add a child view Parameters:
  | pView | the view object to add to this container
Reimplemented from CViewContainer.

void CScrollView::drawBackgroundRect | ( | CDrawContext * | pContext,
|  | CRect & | _updateRect
| ) | `[virtual]`

  | draw the background Parameters:
  | pContext | the context which to use to draw the background
  | _updateRect | the area which to draw
Reimplemented from CViewContainer.

virtual CScrollbar* CScrollView::getHorizontalScrollbar | ( |  | ) | const`[inline, virtual]`

virtual CScrollbar* CScrollView::getVerticalScrollbar | ( |  | ) | const`[inline, virtual]`

bool CScrollView::onWheel | ( | CDrawContext * | pContext,
|  | const CPoint & | where,
|  | const CMouseWheelAxis | axis,
|  | float | distance
| ) | `[virtual]`

| called if a mouse wheel event is happening over this view Reimplemented from CViewContainer.

void CScrollView::setContainerSize | ( | const CRect & | cs | ) | `[virtual]`

| set the virtual size of this container

void CScrollView::valueChanged | ( | CDrawContext * | pContext,
|  | CControl * | pControl
| ) | `[virtual]`

| Implements CControlListener.

## Member Data Documentation

CRect CScrollView::containerSize`[protected]`

CScrollbar* CScrollView::hsb`[protected]`

CScrollContainer* CScrollView::sc`[protected]`

long CScrollView::style`[protected]`

CScrollbar* CScrollView::vsb`[protected]`

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

- cscrollview.h
- cscrollview.cpp

Empty

Copyright ©2006 Steinberg Media Technologies. All Rights Reserved.