Пример #1
0
	VNormalButton::VNormalButton(const std::string& name)
		:osgWidget::Label(name)
	{
		setColor(osgWidget::Color(1, 1, 1, 1));
		setCanFill(true);
		setEventMask(osgWidget::EVENT_MOUSE_OVER | osgWidget::EVENT_MOUSE_LEAVE | osgWidget::EVENT_MOUSE_PUSH | osgWidget::EVENT_MOUSE_RELEASE);
	}
Пример #2
0
 ColorLabel(const char* label):
 osgWidget::Label("", "") {
     setFont("fonts/Vera.ttf");
     setFontSize(14);
     setFontColor(1.0f, 1.0f, 1.0f, 1.0f);
     setColor(0.3f, 0.3f, 0.3f, 1.0f);
     addHeight(18.0f);
     setCanFill(true);
     setLabel(label);
     setEventMask(osgWidget::EVENT_MOUSE_PUSH | osgWidget::EVENT_MASK_MOUSE_MOVE);
 }
    ColorLabel(const char* label):
        osgWidget::Label(label, "") {
        setFont("fonts/VeraMono.ttf");
        setFontSize(14);
        setFontColor(1.0f, 1.0f, 1.0f, 1.0f);

        setColor(0.3f, 0.3f, 0.3f, 1.0f);
        setPadding(2.0f);
        setCanFill(true);

        addSize(150.0f, 25.0f);

        setLabel(label);
        setEventMask(osgWidget::EVENT_MOUSE_PUSH | osgWidget::EVENT_MASK_MOUSE_MOVE);
    }
Пример #4
0
Frame::Border::Border(BorderType border, point_type width, point_type height):
    Widget  (borderTypeToString(border), width, height),
    _border (border)
{
    setCanFill(true);
}