1
0
mirror of https://github.com/minetest/minetest.git synced 2024-09-26 06:20:32 +02:00

Fix background color of formspec text fields

This commit is contained in:
sfan5 2021-05-25 21:03:51 +02:00
parent a0047d6edc
commit 758e3aa1ca

View File

@ -1577,11 +1577,10 @@ void GUIFormSpecMenu::createTextField(parserData *data, FieldSpec &spec,
} }
e->setNotClipped(style.getBool(StyleSpec::NOCLIP, false)); e->setNotClipped(style.getBool(StyleSpec::NOCLIP, false));
e->setDrawBorder(style.getBool(StyleSpec::BORDER, true));
e->setOverrideColor(style.getColor(StyleSpec::TEXTCOLOR, video::SColor(0xFFFFFFFF))); e->setOverrideColor(style.getColor(StyleSpec::TEXTCOLOR, video::SColor(0xFFFFFFFF)));
if (style.get(StyleSpec::BGCOLOR, "") == "transparent") { bool border = style.getBool(StyleSpec::BORDER, true);
e->setDrawBackground(false); e->setDrawBorder(border);
} e->setDrawBackground(border);
e->setOverrideFont(style.getFont()); e->setOverrideFont(style.getFont());
e->drop(); e->drop();