1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Add formspec testing to test mod in minimal

This commit is contained in:
rubenwardy 2019-07-02 03:43:46 +01:00
parent 9541165752
commit 4f7fa8d417
5 changed files with 334 additions and 140 deletions

View file

@ -1458,11 +1458,7 @@ void GUIFormSpecMenu::parseLabel(parserData* data, const std::string &element)
auto style = getStyleForElement("label", spec.fname);
e->setNotClipped(style.getBool(StyleSpec::NOCLIP, false));
e->setDrawBorder(style.getBool(StyleSpec::BORDER, false));
e->setOverrideColor(style.getColor(StyleSpec::TEXTCOLOR, video::SColor(0xFFFFFFFF)));
if (style.isNotDefault(StyleSpec::BGCOLOR)) {
e->setBackgroundColor(style.getColor(StyleSpec::BGCOLOR));
}
m_fields.push_back(spec);
}
@ -1538,11 +1534,7 @@ void GUIFormSpecMenu::parseVertLabel(parserData* data, const std::string &elemen
auto style = getStyleForElement("vertlabel", spec.fname, "label");
e->setNotClipped(style.getBool(StyleSpec::NOCLIP, false));
e->setDrawBorder(style.getBool(StyleSpec::BORDER, false));
e->setOverrideColor(style.getColor(StyleSpec::TEXTCOLOR, video::SColor(0xFFFFFFFF)));
if (style.isNotDefault(StyleSpec::BGCOLOR)) {
e->setBackgroundColor(style.getColor(StyleSpec::BGCOLOR));
}
m_fields.push_back(spec);
return;