Skip to content

Commit

Permalink
Fix background color of formspec text fields
Browse files Browse the repository at this point in the history
  • Loading branch information
sfan5 committed May 30, 2021
1 parent a0047d6 commit 758e3aa
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/gui/guiFormSpecMenu.cpp
Expand Up @@ -1577,11 +1577,10 @@ void GUIFormSpecMenu::createTextField(parserData *data, FieldSpec &spec,
}

e->setNotClipped(style.getBool(StyleSpec::NOCLIP, false));
e->setDrawBorder(style.getBool(StyleSpec::BORDER, true));
e->setOverrideColor(style.getColor(StyleSpec::TEXTCOLOR, video::SColor(0xFFFFFFFF)));
if (style.get(StyleSpec::BGCOLOR, "") == "transparent") {
e->setDrawBackground(false);
}
bool border = style.getBool(StyleSpec::BORDER, true);
e->setDrawBorder(border);
e->setDrawBackground(border);
e->setOverrideFont(style.getFont());

e->drop();
Expand Down

0 comments on commit 758e3aa

Please sign in to comment.