YSTest  PreAlpha_b380_20130211
The YSLib Test Project
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
YSLib::Components::ScrollableContainer Class Reference

带滚动条的容器。 More...

#include <scroll.h>

Inheritance diagram for YSLib::Components::ScrollableContainer:
Collaboration diagram for YSLib::Components::ScrollableContainer:

Public Types

typedef
ystdex::subscriptive_iterator
< ScrollableContainer, IWidget
Iterator
 

Public Member Functions

 ScrollableContainer (const Rect &={})
 
 ScrollableContainer (ScrollableContainer &&)=default
 
Iterator GetBegin ()
 
Iterator GetEnd ()
 
WidgetRange GetChildren () override
 
IWidgetoperator[] (size_t idx) ynoexcept
 
size_t GetChildrenCount () const ynothrow
 
- Public Member Functions inherited from YSLib::Components::Control
 Control (const Rect &={})
 构造:使用指定边界,默认背景(同 Widget 默认构造)。
 
 Control (const Rect &, NoBackgroundTag)
 构造:使用指定边界,无背景。
 
 Control (const Control &)
 复制构造:除容器为空外深复制。
 
 Control (Control &&)=default
 
virtual IWidgetGetBoundControlPtr (const KeyInput &)
 取按键-指针设备输入默认事件组映射。
 
void OnTouch_Close (TouchEventArgs &&)
 处理屏幕事件:关闭显示。
 
- Public Member Functions inherited from YSLib::Components::Widget
 Widget (const Rect &={}, Color=Drawing::ColorSpace::White, Color=Drawing::ColorSpace::Black)
 
template<typename _tView , typename _tRenderer , typename _tController >
 Widget (_tView &&pView_=make_unique< View >(), _tRenderer &&pRenderer_=make_unique< Renderer >(), _tController &&pController_={})
 构造:使用视图指针、渲染器指针和控制器指针,无背景。
 
 Widget (const Widget &)
 复制构造:除容器指针为空外深复制。
 
 Widget (Widget &&)=default
 
virtual ~Widget ()
 析构:虚实现。
 
SPos GetX () const ynothrow
 
SPos GetY () const ynothrow
 
SDst GetWidth () const ynothrow
 
SDst GetHeight () const ynothrow
 
virtual RendererGetRenderer () const ynothrow
 取渲染器。
 
virtual ViewGetView () const ynothrow
 取部件视图。
 
virtual AControllerGetController () const override
 取控制器。
 
void SetX (SDst _tempArgName)
 
void SetY (SDst _tempArgName)
 
void SetWidth (SDst _tempArgName)
 
void SetHeight (SDst _tempArgName)
 
void SetRenderer (unique_ptr< Renderer > &&)
 设置渲染器为指定指针指向的对象,同时更新渲染器状态。
 
void SetView (unique_ptr< View > &&)
 设置渲染器为指定指针指向的对象,同时更新渲染器状态。
 
virtual void Refresh (PaintEventArgs &&)
 刷新:按指定参数绘制界面并更新状态。
 
- Public Member Functions inherited from YSLib::Components::IWidget
virtual ~IWidget ()
 

Protected Member Functions

Size FixLayout (const Size &)
 固定布局。
 

Protected Attributes

HorizontalScrollBar hsbHorizontal
 控制水平可视区域的水平滚动条。
 
VerticalScrollBar vsbVertical
 控制竖直可视区域的竖直滚动条。
 

Additional Inherited Members

- Public Attributes inherited from YSLib::Components::Control
std::function< IWidget *(const
KeyInput &)> 
BoundControlPtr
 按键-指针设备输入事件组映射。
 

Detailed Description

带滚动条的容器。

Since
build 192

Definition at line 409 of file scroll.h.

Member Typedef Documentation

Constructor & Destructor Documentation

YSLib::Components::ScrollableContainer::ScrollableContainer ( const Rect = {})
explicit
Since
build 337
YSLib::Components::ScrollableContainer::ScrollableContainer ( ScrollableContainer &&  )
inlinedefault

Member Function Documentation

Iterator YSLib::Components::ScrollableContainer::GetBegin ( )
inline
Since
build 356

Definition at line 435 of file scroll.h.

WidgetRange YSLib::Components::ScrollableContainer::GetChildren ( )
inlineoverridevirtual
Since
build 357

Reimplemented from YSLib::Components::Widget.

Definition at line 435 of file scroll.h.

size_t YSLib::Components::ScrollableContainer::GetChildrenCount ( ) const
inline

Definition at line 435 of file scroll.h.

Iterator YSLib::Components::ScrollableContainer::GetEnd ( )
inline

Definition at line 435 of file scroll.h.

IWidget& YSLib::Components::ScrollableContainer::operator[] ( size_t  idx)
inline

Definition at line 435 of file scroll.h.

Member Data Documentation

HorizontalScrollBar YSLib::Components::ScrollableContainer::hsbHorizontal
protected

控制水平可视区域的水平滚动条。

Since
build 315

Definition at line 421 of file scroll.h.

VerticalScrollBar YSLib::Components::ScrollableContainer::vsbVertical
protected

控制竖直可视区域的竖直滚动条。

Since
build 315

Definition at line 426 of file scroll.h.


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