|
YSTest
PreAlpha_b500_20140530
The YSLib Test Project
|
标签容器控件。 更多...
#include <TabControl.h>


Public 类型 | |
| using | iterator = ystdex::subscriptive_iterator< TabControl, IWidget > |
Public 属性 | |
| SDst | BarHeight = 24 |
| 标签栏初始高。 更多... | |
| size_t | |
| TabCount | |
| const vector< Panel * > | Pages |
Public 属性 继承自 YSLib::UI::Widget | |
| HBrush | Background |
| 背景。 更多... | |
| Color | ForeColor = Drawing::ColorSpace::Black |
| 默认前景色。 更多... | |
| WidgetRange | |
| Children | |
| AController | Controller |
| AController *controller_ptr Renderer | Renderer |
| AController *controller_ptr Renderer *renderer_ptr View | View |
| AController *controller_ptr Renderer *renderer_ptr View *view_ptr | SPos |
| AController *controller_ptr Renderer *renderer_ptr View *view_ptr | X |
| AController *controller_ptr Renderer *renderer_ptr View *view_ptr | Y |
| AController *controller_ptr Renderer *renderer_ptr View *view_ptr | Height |
| AController *controller_ptr Renderer *renderer_ptr View *view_ptr | Width |
Private 属性 | |
| unique_ptr< TabBar > | p_bar |
| 标签栏。 更多... | |
| Panel * | p_page {} |
| vector< Panel * > | tab_pages {} |
额外继承的成员函数 | |
Protected 成员函数 继承自 YSLib::UI::Control | |
| Control (const Rect &, HBrush, Drawing::Color=Drawing::ColorSpace::Black) | |
| 构造:使用指定边界、背景画刷和前景色。 更多... | |
| Control (const Control &) | |
| 复制构造:除容器为空外深复制。 更多... | |
| DefDeMoveCtor (Control) virtual PDefH(IWidget * | |
| 取按键-指针设备输入默认事件组映射。 更多... | |
| const KeyInput & | ImplRet (nullptr) void OnTouch_Close(CursorEventArgs &&) |
| 处理屏幕事件:关闭显示。 更多... | |
Protected 属性 继承自 YSLib::UI::Control | |
| GetBoundControlPtr | |
| using YSLib::UI::TabControl::iterator = ystdex::subscriptive_iterator<TabControl, IWidget> |
在文件 TabControl.h 第 115 行定义.
|
explicit |
在文件 TabControl.cpp 第 130 行定义.
| void YSLib::UI::TabControl::Attach | ( | Control & | ctl | ) |
附加:添加 TouchDown 事件处理器。
在文件 TabControl.cpp 第 144 行定义.
参考 YSLib::UI::Invalidate() , 以及 SwitchTab().
参考自 YReader::AddButtonToTabBar().


| YSLib::UI::TabControl::DefDeMoveCtor | ( | TabControl | ) |
取页面边界。
| YSLib::UI::TabControl::DefGetter | ( | const ynothrow | , |
| TabBar & | , | ||
| TabBarRef | , | ||
| (YAssertNonnull(p_bar),*p_bar) | |||
| ) | const |
取标签数。
| size_t YSLib::UI::TabControl::Find | ( | IWidget & | wgt | ) | const |
查找页面部件。
在文件 TabControl.cpp 第 162 行定义.
参考 tab_pages , 以及 YSLib::UI::wgt.
参考自 SwitchPage() , 以及 SwitchTab().

| YSLib::UI::TabControl::GetTabBarRef | ( | ) | const |
| size_t idx ynoexcept YSLib::UI::TabControl::ImplRet | ( | YAssertNonnull(idx==0||p_page) | , |
| *ystdex::forward_as_array< IWidget * > | (p_bar.get(), p_page).begin()[idx] | ||
| ) |
| bool YSLib::UI::TabControl::SwitchPage | ( | size_t | idx | ) |
切换页面。
在文件 TabControl.cpp 第 177 行定义.
参考自 SwitchTab().

| bool YSLib::UI::TabControl::SwitchPage | ( | Control & | ctl | ) |
在文件 TabControl.cpp 第 187 行定义.
参考 Find(), p_bar, p_page, YSLib::UI::SetBoundsOf(), tab_pages, YAssert , 以及 YAssertNonnull.

| bool YSLib::UI::TabControl::SwitchTab | ( | Control & | ctl | ) |
按标签切换页面。
在文件 TabControl.cpp 第 169 行定义.
参考 Find(), GetTabBarRef() , 以及 SwitchPage().
参考自 Attach().


| void YSLib::UI::TabControl::UpdateTabPages | ( | ) |
更新标签页状态。
调整标签栏布局;选中第一个存在对应页面的标签; 若存在选中页面则设置可视状态并调整大小;最后无效化。
在文件 TabControl.cpp 第 207 行定义.
参考 GetTabBarRef(), YSLib::UI::Invalidate(), p_page, YSLib::UI::SetBoundsOf(), tab_pages , 以及 yunseq.

| SDst YSLib::UI::TabControl::BarHeight = 24 |
|
private |
|
private |
在文件 TabControl.h 第 126 行定义.
参考自 SwitchPage() , 以及 UpdateTabPages().
| const vector<Panel*> YSLib::UI::TabControl::Pages |
在文件 TabControl.h 第 160 行定义.
| YSLib::UI::TabControl::size_t |
在文件 TabControl.h 第 159 行定义.
|
private |
在文件 TabControl.h 第 127 行定义.
参考自 Find(), SwitchPage() , 以及 UpdateTabPages().
| YSLib::UI::TabControl::TabCount |
在文件 TabControl.h 第 159 行定义.