本文整理汇总了C++中wt::WContainerWidget::setStyleClass方法的典型用法代码示例。如果您正苦于以下问题:C++ WContainerWidget::setStyleClass方法的具体用法?C++ WContainerWidget::setStyleClass怎么用?C++ WContainerWidget::setStyleClass使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类wt::WContainerWidget
的用法示例。
在下文中一共展示了WContainerWidget::setStyleClass方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Result
Wt::WWidget* Tester::Result()
{
Wt::WContainerWidget* c = new Wt::WContainerWidget();
c->setStyleClass("result_container");
Wt::WText* t = new Wt::WText("Results", c);
t->setStyleClass("area_title");
mResult = new Wt::WContainerWidget(c);
mResult->setStyleClass("result_output");
return c;
}
示例2: setTheme
Tester::Tester(const Wt::WEnvironment& env)
: Wt::WApplication(env)
{
setTheme(new Wt::WBootstrapTheme());
useStyleSheet("resources/lpeg_tester.css");
Wt::WContainerWidget* container = new Wt::WContainerWidget();
container->setStyleClass("page");
Wt::WVBoxLayout* vbox = new Wt::WVBoxLayout();
container->setLayout(vbox);
vbox->addWidget(Title(), 1);
Wt::WHBoxLayout* hbox = new Wt::WHBoxLayout();
vbox->addLayout(hbox);
hbox->addWidget(Input(), 1);
hbox->addWidget(Result(), 1);
root()->addWidget(container);
HandleInternalPath(internalPath());
internalPathChanged().connect(this, &Tester::HandleInternalPath);
}
示例3: Input
Wt::WWidget* Tester::Input()
{
Wt::WContainerWidget* container = new Wt::WContainerWidget();
container->setStyleClass("input_container");
Wt::WText* t = new Wt::WText("Input", container);
t->setStyleClass("area_title");
new Wt::WBreak(container);
mInput = new Wt::WTextArea(container);
mInput->setText("20131220T094700");
new Wt::WBreak(container);
t = new Wt::WText("Grammar", container);
t->setStyleClass("area_title");
new Wt::WBreak(container);
mGrammar = new Wt::WTextArea(container);
mGrammar->setRows(15);
mGrammar->setText("local l = require 'lpeg'\nl.locale(l)\ngrammar = l.C(l.digit^-4)");
Wt::WPushButton* button = new Wt::WPushButton("Test Grammar", container);
button->clicked().connect(this, &Tester::GrammarButton);
button = new Wt::WPushButton("Benchmark Grammar", container);
button->clicked().connect(this, &Tester::BenchmarkButton);
button = new Wt::WPushButton("Share Grammar", container);
button->clicked().connect(this, &Tester::ShareGrammar);
return container;
}
示例4:
Wt::WContainerWidget *PopupChatWidget::createBar()
{
Wt::WContainerWidget *bar = new Wt::WContainerWidget();
bar->setStyleClass("chat-bar");
Wt::WText *toggleButton = new Wt::WText();
toggleButton->setInline(false);
toggleButton->setStyleClass("chat-minmax");
bar->clicked().connect(this, &PopupChatWidget::toggleSize);
bar->clicked().connect(this, &PopupChatWidget::goOnline);
bar->addWidget(toggleButton);
title_ = new Wt::WText(bar);
bar_ = bar;
return bar;
}