Beispiel #1
0
UILabel* UI::addLabel(int id, int x, int y, int width, int height, const char* text)
{
    UILabel* label = new UILabel(mRootNode);
    label->nodeID = id;
    label->setPos(x, y);
    label->setText(text);
    label->setSize(width, height);
    nodeList.push_back(label);
    return label;
}
Beispiel #2
0
void UICanvas::showMessageBox(const String& message)
{
	Widget* modalBackground = new Widget();
	
	UIWindow* surface = addSurface("modal");
	surface->attach(modalBackground);
	modalBackground->setRect(surface->getRect());

	UILabel* label = new UILabel(message);
	label->setSize(700,50);
	//label->setCenter(modalBackground->getMiddlePosition());
	modalBackground->attach(label);
};