mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-10-04 02:21:11 -04:00
added lighting mode tooltips
This commit is contained in:
parent
61a02d8a40
commit
490442cf62
@ -58,9 +58,23 @@ namespace CSVRender
|
|||||||
{
|
{
|
||||||
CSVWidget::SceneToolMode *tool = new CSVWidget::SceneToolMode (parent);
|
CSVWidget::SceneToolMode *tool = new CSVWidget::SceneToolMode (parent);
|
||||||
|
|
||||||
tool->addButton (":door.png", "day"); /// \todo replace icons
|
/// \todo replace icons
|
||||||
tool->addButton (":GMST.png", "night");
|
tool->addButton (":door.png", "day",
|
||||||
tool->addButton (":Info.png", "bright");
|
"Day"
|
||||||
|
"<ul><li>Cell specific ambient in interiors</li>"
|
||||||
|
"<li>Low ambient in exteriors</li>"
|
||||||
|
"<li>Strong directional light source/lir>"
|
||||||
|
"<li>This mode closely resembles day time in-game</li></ul>");
|
||||||
|
tool->addButton (":GMST.png", "night",
|
||||||
|
"Night"
|
||||||
|
"<ul><li>Cell specific ambient in interiors</li>"
|
||||||
|
"<li>Low ambient in exteriors</li>"
|
||||||
|
"<li>Weak directional light source</li>"
|
||||||
|
"<li>This mode closely resembles night time in-game</li></ul>");
|
||||||
|
tool->addButton (":Info.png", "bright",
|
||||||
|
"Bright"
|
||||||
|
"<ul><li>Maximum ambient</li>"
|
||||||
|
"<li>Strong directional light source</li></ul>");
|
||||||
|
|
||||||
connect (tool, SIGNAL (modeChanged (const std::string&)),
|
connect (tool, SIGNAL (modeChanged (const std::string&)),
|
||||||
this, SLOT (selectLightingMode (const std::string&)));
|
this, SLOT (selectLightingMode (const std::string&)));
|
||||||
|
@ -29,10 +29,11 @@ void CSVWidget::SceneToolMode::showPanel (const QPoint& position)
|
|||||||
mButtons.begin()->first->setFocus (Qt::OtherFocusReason);
|
mButtons.begin()->first->setFocus (Qt::OtherFocusReason);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CSVWidget::SceneToolMode::addButton (const std::string& icon, const std::string& id)
|
void CSVWidget::SceneToolMode::addButton (const std::string& icon, const std::string& id,
|
||||||
|
const std::string& tooltip)
|
||||||
{
|
{
|
||||||
PushButton *button = new PushButton (QIcon (QPixmap (icon.c_str())), PushButton::Type_Mode,
|
PushButton *button = new PushButton (QIcon (QPixmap (icon.c_str())), PushButton::Type_Mode,
|
||||||
"", mPanel);
|
tooltip, mPanel);
|
||||||
button->setSizePolicy (QSizePolicy (QSizePolicy::Fixed, QSizePolicy::Fixed));
|
button->setSizePolicy (QSizePolicy (QSizePolicy::Fixed, QSizePolicy::Fixed));
|
||||||
button->setIconSize (QSize (mIconSize, mIconSize));
|
button->setIconSize (QSize (mIconSize, mIconSize));
|
||||||
button->setFixedSize (mButtonSize, mButtonSize);
|
button->setFixedSize (mButtonSize, mButtonSize);
|
||||||
|
@ -29,7 +29,8 @@ namespace CSVWidget
|
|||||||
|
|
||||||
virtual void showPanel (const QPoint& position);
|
virtual void showPanel (const QPoint& position);
|
||||||
|
|
||||||
void addButton (const std::string& icon, const std::string& id);
|
void addButton (const std::string& icon, const std::string& id,
|
||||||
|
const std::string& tooltip = "");
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user