ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

ThemeParser.cpp File Reference

#include "gui/ThemeEngine.h"
#include "gui/ThemeEval.h"
#include "gui/ThemeParser.h"
#include "graphics/VectorRenderer.h"
#include "common/system.h"
#include "common/tokenizer.h"
Include dependency graph for ThemeParser.cpp:

Go to the source code of this file.

Classes

struct  GUI::TextDataInfo
struct  GUI::TextColorDataInfo

Namespaces

namespace  GUI

Defines

#define PARSER_ASSIGN_INT(struct_name, key_name, force)
#define PARSER_ASSIGN_RGB(struct_name, key_name)

Functions

static TextData GUI::parseTextDataId (const Common::String &name)
static TextColor GUI::parseTextColorId (const Common::String &name)
static Graphics::TextAlign GUI::parseTextHAlign (const Common::String &val)
static
GUI::ThemeEngine::TextAlignVertical 
GUI::parseTextVAlign (const Common::String &val)
static
Graphics::DrawingFunctionCallback 
GUI::getDrawingFunctionCallback (const Common::String &name)

Variables

static const TextDataInfo GUI::kTextDataDefaults []
static const TextColorDataInfo GUI::kTextColorDefaults []

Define Documentation

#define PARSER_ASSIGN_INT (   struct_name,
  key_name,
  force 
)
Value:
if (stepNode->values.contains(key_name)) { \
        if (!parseIntegerKey(stepNode->values[key_name], 1, &x)) \
            return parserError("Error parsing key value for '" + Common::String(key_name) + "'."); \
        \
        drawstep->struct_name = x; \
    } else if (force) { \
        return parserError("Missing necessary key '" + Common::String(key_name) + "'."); \
    }
#define PARSER_ASSIGN_RGB (   struct_name,
  key_name 
)
Value:
if (stepNode->values.contains(key_name)) { \
        val = stepNode->values[key_name]; \
        if (_palette.contains(val)) { \
            red = _palette[val].r; \
            green = _palette[val].g; \
            blue = _palette[val].b; \
        } else if (parseIntegerKey(val, 3, &red, &green, &blue) == false || \
            red < 0 || red > 255 || green < 0 || green > 255 || blue < 0 || blue > 255) \
            return parserError("Error parsing color struct '" + val + "'");\
        \
        drawstep->struct_name.r = red; \
        drawstep->struct_name.g = green; \
        drawstep->struct_name.b = blue; \
        drawstep->struct_name.set = true; \
    }


Generated on Sat Feb 16 2019 05:02:53 for ResidualVM by doxygen 1.7.1
curved edge   curved edge