From ec3795a55c24685ec732fada3d1f5ba75ecd1cd5 Mon Sep 17 00:00:00 2001 From: rubenwardy Date: Fri, 15 Mar 2019 19:03:12 +0000 Subject: Add style[] tag with button support --- src/gui/guiFormSpecMenu.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/gui/guiFormSpecMenu.h') diff --git a/src/gui/guiFormSpecMenu.h b/src/gui/guiFormSpecMenu.h index 9c1ecb635..b310f8a77 100644 --- a/src/gui/guiFormSpecMenu.h +++ b/src/gui/guiFormSpecMenu.h @@ -30,6 +30,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "client/joystick_controller.h" #include "util/string.h" #include "util/enriched_string.h" +#include "StyleSpec.h" class InventoryManager; class ISimpleTextureSource; @@ -401,6 +402,11 @@ protected: const std::vector &v_pos); v2s32 getRealCoordinateGeometry(const std::vector &v_geom); + std::unordered_map theme_by_type; + std::unordered_map theme_by_name; + + StyleSpec getThemeForElement(const std::string &type, const std::string &name); + v2s32 padding; v2f32 spacing; v2s32 imgsize; @@ -537,6 +543,7 @@ private: void parsePosition(parserData *data, const std::string &element); bool parseAnchorDirect(parserData *data, const std::string &element); void parseAnchor(parserData *data, const std::string &element); + bool parseStyle(parserData *data, const std::string &element, bool style_type); void tryClose(); -- cgit v1.2.3