现在的位置: 首页 > 综合 > 正文

(CEGUI)如何创建控件 ——ScrollablePane(滚动区域)

2013年09月06日 ⁄ 综合 ⁄ 共 387字 ⁄ 字号 评论关闭

    CEGUI::Window* d_root;     

    CEGUI::ScrollablePane* d_pane;

    // 创建滚动区
    d_pane = static_cast<ScrollablePane*>(d_wm->createWindow("WindowsLook/ScrollablePane"));
    d_pane->setArea(URect(UDim(0,0),bar_bottom,UDim(0.8,0),UDim(0.8,0)));

    // 关闭自动滚动
    d_pane->setContentPaneAutoSized(false);

    // 滚动区域大小
    d_pane->setContentPaneArea(CEGUI::Rect(0,0,1000,500));
    d_root->addChildWindow(d_pane);

抱歉!评论已关闭.