21#include <vstgui4/vstgui/uidescription/iviewcreator.h>
22#include <vstgui4/vstgui/uidescription/uiviewcreator.h>
23#include <vstgui4/vstgui/uidescription/uiviewfactory.h>
24#include <vstgui4/vstgui/uidescription/uiattributes.h>
25#include <vstgui4/vstgui/uidescription/detail/uiviewcreatorattributes.h>
26#include <vstgui4/vstgui/lib/crect.h>
27#include <vstgui4/vstgui/lib/ccolor.h>
28#include <vstgui4/vstgui/lib/cbitmap.h>
33#include <pongasoft/logging/logging.h>
43using namespace VSTGUI;
62 fName(std::move(iName))
68 virtual IViewCreator::AttrType
getType() = 0;
85 virtual bool apply(CView *iView,
const UIAttributes &iAttributes,
const IUIDescription *iDescription) = 0;
94 virtual bool getAttributeValue(CView *iView,
const IUIDescription *iDescription, std::string &oStringValue)
const = 0;
99 virtual bool getPossibleListValues(std::list<const std::string *> &iValues)
const
113template<CViewSub
class TView>
115 const UIAttributes &iAttributes,
116 const IUIDescription * ) {
return new TView(iSize); }
161template<
typename TView>
179 template<
typename T,
typename TGetter,
typename TSetter>
198 return IViewCreator::kUnknownType;
205 virtual bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue, T &oValue)
const
211 bool apply(CView *iView,
const UIAttributes &iAttributes,
const IUIDescription *iDescription)
override
213 auto *tv =
dynamic_cast<TView *
>(iView);
216 auto attributeValue = iAttributes.getAttributeValue(
getName());
220 if(
fromString(iDescription, *attributeValue, value))
222 std::invoke(
fSetter, tv, value);
235 virtual bool toString(IUIDescription
const *iDescription, T
const &iValue, std::string &oStringValue)
const
242 bool getAttributeValue(CView *iView,
const IUIDescription *iDescription, std::string &oStringValue)
const override
244 auto *tv =
dynamic_cast<TView *
>(iView);
247 auto value = std::invoke(fGetter, tv);
248 return toString(iDescription, value, oStringValue);
271 using ByRefAttribute = TAttribute<T, T
const &(TView::*)() const,
void (TView::*)(T const &)>;
288 return IViewCreator::kTagType;
292 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
TagID &oValue)
const override
294 if(iAttributeValue.length() != 0)
296 auto tag =
static_cast<TagID>(iDescription->getTagForName(iAttributeValue.c_str()));
299 char *endPtr =
nullptr;
300 tag =
static_cast<TagID>(strtol(iAttributeValue.c_str(), &endPtr, 10));
301 if(endPtr == iAttributeValue.c_str())
317 bool toString(IUIDescription
const *iDescription,
const TagID &iValue, std::string &oStringValue)
const override
321 UTF8StringPtr controlTag = iDescription->lookupControlTagName(iValue);
324 oStringValue = controlTag;
338 template<Utils::IntegralOrEnum TInt>
352 return IViewCreator::kIntegerType;
356 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue, TInt &oValue)
const override
358 char *endPtr =
nullptr;
359 auto value =
static_cast<TInt
>(strtol(iAttributeValue.c_str(), &endPtr, 10));
360 if(endPtr == iAttributeValue.c_str())
362 DLOG_F(WARNING,
"could not convert <%s> to an integer", iAttributeValue.c_str());
371 bool toString(IUIDescription
const *iDescription,
const TInt &iValue, std::string &oStringValue)
const override
373 std::stringstream str;
375 oStringValue = str.str();
385 template<std::
floating_po
int TFloat>
399 return IViewCreator::kFloatType;
403 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue, TFloat &oValue)
const override
411 DLOG_F(WARNING,
"could not convert <%s> to a float", iAttributeValue.c_str());
417 bool toString(IUIDescription
const *iDescription,
const TFloat &iValue, std::string &oStringValue)
const override
419 std::stringstream str;
421 oStringValue = str.str();
444 return IViewCreator::kColorType;
448 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue, CColor &oValue)
const override
451 if(UIViewCreator::stringToColor(&iAttributeValue, color, iDescription))
461 bool toString(IUIDescription
const *iDescription,
const CColor &iValue, std::string &oStringValue)
const override
463 return UIViewCreator::colorToString(iValue, oStringValue, iDescription);
485 return IViewCreator::kGradientType;
489 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
GradientPtr &oValue)
const override
491 auto gradient = iDescription->getGradient(iAttributeValue.c_str());
502 bool toString(IUIDescription
const *iDescription,
GradientPtr const &iValue, std::string &oStringValue)
const override
506 auto name = iDescription->lookupGradientName(iValue);
535 return IViewCreator::kBooleanType;
539 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
bool &oValue)
const override
541 if(iAttributeValue ==
"true")
547 if(iAttributeValue ==
"false")
558 bool toString(IUIDescription
const *iDescription,
const bool &iValue, std::string &oStringValue)
const override
560 oStringValue = iValue ?
"true" :
"false";
582 return IViewCreator::kBitmapType;
586 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
BitmapPtr &oValue)
const override
589 if(UIViewCreator::stringToBitmap(&iAttributeValue, bitmap, iDescription))
599 bool toString(IUIDescription
const *iDescription,
BitmapPtr const &iValue, std::string &oStringValue)
const override
602 return UIViewCreator::bitmapToString(iValue, oStringValue, iDescription);
625 return IViewCreator::kFontType;
629 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
FontPtr &oValue)
const override
631 auto font = iDescription->getFont(iAttributeValue.c_str());
642 bool toString(IUIDescription
const *iDescription,
FontPtr const &iValue, std::string &oStringValue)
const override
646 auto fontName = iDescription->lookupFontName(iValue);
649 oStringValue = fontName;
671 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
Margin &oValue)
const override
679 if(std::find_if(parts.cbegin(), parts.cend(), [] (
auto f) {return std::isnan(f);}) != parts.cend())
682 if(parts.size() == 1)
684 oValue =
Margin{parts[0]};
691 oValue =
Margin{parts[0], parts[1], parts[2], parts[3]};
699 bool toString(IUIDescription
const *iDescription,
const Margin &iValue, std::string &oStringValue)
const override
701 std::stringstream str;
714 oStringValue = str.str();
733 bool fromString(IUIDescription
const *iDescription, std::string
const &iAttributeValue,
Range &oValue)
const override
741 if(std::find_if(parts.cbegin(), parts.cend(), [] (
auto f) {return std::isnan(f);}) != parts.cend())
744 if(parts.size() == 1)
745 oValue =
Range{parts[0]};
747 oValue =
Range{parts[0], parts[1]};
754 bool toString(IUIDescription
const *iDescription,
const Range &iValue, std::string &oStringValue)
const override
756 std::stringstream str;
765 oStringValue = str.str();
783 char iDelimiter =
',',
784 bool iSkipEmptyEntries =
false) :
792 std::string
const &iAttributeValue,
793 std::vector<std::string> &oValue)
const override
801 bool toString(IUIDescription
const *iDescription,
802 const std::vector<std::string> &iValue,
803 std::string &oStringValue)
const override
805 oStringValue.clear();
807 for(
auto &entry : iValue)
813 oStringValue += entry;
843 ,fAttributeValuesList{iAttributeValues}
851 return IViewCreator::kListType;
856 std::string
const &iAttributeValue,
857 T &oValue)
const override
865 DLOG_F(WARNING,
"Attribute value '%s' is not valid for '%s'", iAttributeValue.c_str(),
ViewAttribute::getName().c_str());
871 bool toString(IUIDescription
const *iDescription,
873 std::string &oStringValue)
const override
875 auto pos = std::find_if(std::begin(fAttributeValuesList),
876 std::end(fAttributeValuesList),
877 [&iValue](
auto entry) ->
bool {
878 return entry.second == iValue;
880 if(pos != std::end(fAttributeValuesList))
882 oStringValue = pos->first;
890 bool getPossibleListValues(std::list<const std::string *> &iValues)
const override
892 for(
auto const &p : fAttributeValuesList)
894 iValues.emplace_back(&p.first);
903 std::vector<typename AttrValMap<T>::value_type>
const fAttributeValuesList;
910 char const *iDisplayName =
nullptr,
911 char const *iBaseViewName = VSTGUI::UIViewCreator::kCView) :
918 if(iViewName !=
nullptr && iDisplayName !=
nullptr)
919 VSTGUI::UIViewFactory::registerViewCreator(*
this);
951 template<CViewSub
class XView>
959 if(std::string(
fBaseViewName) == std::string(VSTGUI::UIViewCreator::kCView))
1029 char iDelimiter =
',',
1030 bool iSkipEmptyEntries =
false)
1051 template<
typename T>
1053 ListAttribute<T>::Getter iGetter,
1054 ListAttribute<T>::Setter iSetter,
1073 template<Utils::IntegralOrEnum TInt>
1124 CView *
create(
const UIAttributes &attributes,
const IUIDescription *description)
const override
1126#ifdef JAMBA_DEBUG_LOGGING
1127 DLOG_F(INFO,
"CustomViewCreator<%s>::create()",
getViewName());
1137 bool apply(CView *view,
const UIAttributes &attributes,
const IUIDescription *description)
const override
1139 auto *tv =
dynamic_cast<TView *
>(view);
1146 attribute.second->apply(tv, attributes, description);
1157 attributeNames.emplace_back(attribute.first);
1168 return iter->second->getType();
1170 return kUnknownType;
1177 bool getAttributeValue(CView *iView,
1178 const std::string &iAttributeName,
1179 std::string &oStringValue,
1180 const IUIDescription *iDescription)
const override
1182 auto *cdv =
dynamic_cast<TView *
>(iView);
1190 return iter->second->getAttributeValue(cdv, iDescription, oStringValue);
1199 bool getPossibleListValues(
const std::string &iAttributeName, std::list<const std::string *> &iValues)
const override
1204 return iter->second->getPossibleListValues(iValues);
1213 template<
typename XView>
1225 fAttributes[iAttribute->getName()] = std::move(iAttribute);
1231 template<
typename TViewAttribute,
typename... Args>
1233 TViewAttribute::Getter iGetter,
1234 TViewAttribute::Setter iSetter,
1237 std::shared_ptr<ViewAttribute> cva;
1238 cva.reset(
new TViewAttribute(iName, iGetter, iSetter, std::forward<Args>(iArgs)...));
1253 template<
typename T>
1255 requires {
typename T::Creator; } && std::default_initializable<typename T::Creator>; }
1326template<
typename TView,
typename TBaseView =
void>
1331 char const *iDisplayName =
nullptr,
1332 char const *iBaseViewName = VSTGUI::UIViewCreator::kCView) :
CustomViewCreator(char const *iViewName=nullptr, char const *iDisplayName=nullptr, char const *iBaseViewName=VSTGUI::UIViewCreator::kCView)
Definition CustomViewCreator.h:1330
BitmapAttribute(std::string const &iName, ByValAttribute< BitmapPtr >::Getter iGetter, ByValAttribute< BitmapPtr >::Setter iSetter)
Definition CustomViewCreator.h:574
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:580
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, BitmapPtr &oValue) const override
Definition CustomViewCreator.h:586
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:533
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, bool &oValue) const override
Definition CustomViewCreator.h:539
BooleanAttribute(std::string const &iName, ByValAttribute< bool >::Getter iGetter, ByValAttribute< bool >::Setter iSetter)
Definition CustomViewCreator.h:527
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, CColor &oValue) const override
Definition CustomViewCreator.h:448
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:442
ColorAttribute(std::string const &iName, ByRefAttribute< CColor >::Getter iGetter, ByRefAttribute< CColor >::Setter iSetter)
Definition CustomViewCreator.h:436
FloatAttribute(std::string const &iName, Getter iGetter, Setter iSetter)
Definition CustomViewCreator.h:393
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:397
ByValAttribute< TFloat >::Setter Setter
Definition CustomViewCreator.h:390
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, TFloat &oValue) const override
Definition CustomViewCreator.h:403
ByValAttribute< TFloat >::Getter Getter
Definition CustomViewCreator.h:389
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:623
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, FontPtr &oValue) const override
Definition CustomViewCreator.h:629
FontAttribute(std::string const &iName, ByValAttribute< FontPtr >::Getter iGetter, ByValAttribute< FontPtr >::Setter iSetter)
Definition CustomViewCreator.h:617
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:483
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, GradientPtr &oValue) const override
Definition CustomViewCreator.h:489
GradientAttribute(std::string const &iName, ByValAttribute< GradientPtr >::Getter iGetter, ByValAttribute< GradientPtr >::Setter iSetter)
Definition CustomViewCreator.h:477
ByValAttribute< TInt >::Setter Setter
Definition CustomViewCreator.h:343
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:350
ByValAttribute< TInt >::Getter Getter
Definition CustomViewCreator.h:342
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, TInt &oValue) const override
Definition CustomViewCreator.h:356
IntegerAttribute(std::string const &iName, Getter iGetter, Setter iSetter)
Definition CustomViewCreator.h:346
ListAttribute(std::string const &iName, super_type::Getter iGetter, super_type::Setter iSetter, AttrValInitList< T > const &iAttributeValues)
Definition CustomViewCreator.h:836
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, T &oValue) const override
Subclasses need to implement this method to convert a string (iAttributeValue) to a T.
Definition CustomViewCreator.h:855
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:849
ByValAttribute< T > super_type
Definition CustomViewCreator.h:832
AttrValMap< T > const fAttributeValuesMap
Definition CustomViewCreator.h:901
MarginAttribute(std::string const &iName, ByRefAttribute< Margin >::Getter iGetter, ByRefAttribute< Margin >::Setter iSetter)
Definition CustomViewCreator.h:665
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, Margin &oValue) const override
Definition CustomViewCreator.h:671
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, Range &oValue) const override
Definition CustomViewCreator.h:733
RangeAttribute(std::string const &iName, ByRefAttribute< Range >::Getter iGetter, ByRefAttribute< Range >::Setter iSetter)
Definition CustomViewCreator.h:727
Setter fSetter
Definition CustomViewCreator.h:258
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:196
TAttribute(std::string const &iName, Getter iGetter, Setter iSetter)
Definition CustomViewCreator.h:187
TGetter Getter
Definition CustomViewCreator.h:183
virtual bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, T &oValue) const
Definition CustomViewCreator.h:205
TSetter Setter
Definition CustomViewCreator.h:184
bool apply(CView *iView, const UIAttributes &iAttributes, const IUIDescription *iDescription) override
Definition CustomViewCreator.h:211
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, TagID &oValue) const override
Definition CustomViewCreator.h:292
IViewCreator::AttrType getType() override
Definition CustomViewCreator.h:286
TagAttribute(std::string const &iName, ByValAttribute< TagID >::Getter iGetter, ByValAttribute< TagID >::Setter iSetter)
Definition CustomViewCreator.h:280
bool fSkipEmptyEntries
Definition CustomViewCreator.h:823
bool fromString(IUIDescription const *iDescription, std::string const &iAttributeValue, std::vector< std::string > &oValue) const override
Definition CustomViewCreator.h:791
ByRefAttribute< std::vector< std::string > > super_type
Definition CustomViewCreator.h:776
VectorStringAttribute(std::string const &iName, super_type::Getter iGetter, super_type::Setter iSetter, char iDelimiter=',', bool iSkipEmptyEntries=false)
Definition CustomViewCreator.h:780
char fDelimiter
Definition CustomViewCreator.h:822
TAttribute< T, T const &(CustomViewAdapter::*)() const, void(CustomViewAdapter::*)(T const &)> ByRefAttribute
Definition CustomViewCreator.h:271
void registerFloatAttribute(std::string const &iName, FloatAttribute< float >::Getter iGetter, FloatAttribute< float >::Setter iSetter)
Registers a float attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1094
void registerBitmapAttribute(std::string const &iName, BitmapAttribute::Getter iGetter, BitmapAttribute::Setter iSetter)
Registers a bitmap attribute with the given name and getter/setter.
Definition CustomViewCreator.h:986
void registerBooleanAttribute(std::string const &iName, BooleanAttribute::Getter iGetter, BooleanAttribute::Setter iSetter)
Registers a boolean attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1114
char const * fBaseViewName
Definition CustomViewCreator.h:1245
void registerMarginAttribute(std::string const &iName, MarginAttribute::Getter iGetter, MarginAttribute::Setter iSetter)
Registers a Margin attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1006
UTF8StringPtr getDisplayName() const override
Definition CustomViewCreator.h:937
CView * create(const UIAttributes &attributes, const IUIDescription *description) const override
This is the factory method which will instantiate the view.
Definition CustomViewCreator.h:1124
void registerVectorStringAttribute(std::string const &iName, VectorStringAttribute::Getter iGetter, VectorStringAttribute::Setter iSetter, char iDelimiter=',', bool iSkipEmptyEntries=false)
Registers a Range attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1026
void registerColorAttribute(std::string const &iName, ColorAttribute::Getter iGetter, ColorAttribute::Setter iSetter)
Registers a color attribute with the given name and getter/setter.
Definition CustomViewCreator.h:966
void registerDoubleAttribute(std::string const &iName, FloatAttribute< double >::Getter iGetter, FloatAttribute< double >::Setter iSetter)
Registers a double attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1104
void registerRangeAttribute(std::string const &iName, RangeAttribute::Getter iGetter, RangeAttribute::Setter iSetter)
Registers a Range attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1016
void registerFontAttribute(std::string const &iName, FontAttribute::Getter iGetter, FontAttribute::Setter iSetter)
Registers a font attribute with the given name and getter/setter.
Definition CustomViewCreator.h:996
~TCustomViewCreator() override
Definition CustomViewCreator.h:923
void registerIntegerAttribute(std::string const &iName, IntegerAttribute< TInt >::Getter iGetter, IntegerAttribute< TInt >::Setter iSetter)
Registers an Integer (any kind) attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1074
IdStringPtr getViewName() const override
Definition CustomViewCreator.h:931
void registerAttributes(TCustomViewCreator< XView > const &iOther)
This method is called to register all the attributes from another CustomViewCreator (used in case of ...
Definition CustomViewCreator.h:952
friend class TCustomViewCreator
Definition CustomViewCreator.h:1214
bool getAttributeNames(std::list< std::string > &attributeNames) const override
Definition CustomViewCreator.h:1153
IdStringPtr getBaseViewName() const override
Definition CustomViewCreator.h:943
void registerIntAttribute(std::string const &iName, IntegerAttribute< int32_t >::Getter iGetter, IntegerAttribute< int32_t >::Setter iSetter)
Registers an int attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1084
AttrType getAttributeType(const std::string &attributeName) const override
Definition CustomViewCreator.h:1163
void registerTagAttribute(std::string const &iName, TagAttribute::Getter iGetter, TagAttribute::Setter iSetter)
Registers a tag attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1063
void registerAttribute(std::shared_ptr< ViewAttribute > iAttribute)
Internal method to register an attribute... check that names are not duplicate!
Definition CustomViewCreator.h:1219
void registerAttribute(std::string const &iName, TViewAttribute::Getter iGetter, TViewAttribute::Setter iSetter, Args &&...iArgs)
Generic register attribute.
Definition CustomViewCreator.h:1232
TAttribute< T, T(CustomViewAdapter::*)() const, void(CustomViewAdapter::*)(T)> ByValAttribute
Definition CustomViewCreator.h:265
void registerGradientAttribute(std::string const &iName, GradientAttribute::Getter iGetter, GradientAttribute::Setter iSetter)
Registers a gradient attribute with the given name and getter/setter.
Definition CustomViewCreator.h:976
std::map< std::string, std::shared_ptr< ViewAttribute > > fAttributes
Definition CustomViewCreator.h:1248
void registerListAttribute(std::string const &iName, ListAttribute< T >::Getter iGetter, ListAttribute< T >::Setter iSetter, AttrValInitList< T > const &iAttributeValues)
Registers a list attribute with the given name and getter/setter.
Definition CustomViewCreator.h:1052
char const * fViewName
Definition CustomViewCreator.h:1243
char const * fDisplayName
Definition CustomViewCreator.h:1244
TCustomViewCreator(char const *iViewName=nullptr, char const *iDisplayName=nullptr, char const *iBaseViewName=VSTGUI::UIViewCreator::kCView)
Definition CustomViewCreator.h:909
bool apply(CView *view, const UIAttributes &attributes, const IUIDescription *description) const override
Extract all the attribute values and apply them to the view.
Definition CustomViewCreator.h:1137
Base abstract class for an attribute of a view.
Definition CustomViewCreator.h:55
std::string fName
Definition CustomViewCreator.h:106
virtual ~ViewAttribute()=default
Destructor (needed for polymorphic base type).
virtual bool apply(CView *iView, const UIAttributes &iAttributes, const IUIDescription *iDescription)=0
Extracts the value from iAttributes for getName() attribute and "apply" it on the view provided.
std::string getName() const
Name of the attribute (which ends up being an attribute in the xml file) Ex: <view back-color="~ Blac...
Definition CustomViewCreator.h:74
virtual IViewCreator::AttrType getType()=0
ViewAttribute(std::string iName)
Definition CustomViewCreator.h:61
Checks that T has a nested Creator class and that it can be default constructed.
Definition CustomViewCreator.h:1254
std::vector< std::string > splitString(const std::string &iString, char iDelimiter, bool iSkipEmptyEntries)
Split a string according to a delimiter and returns a vector.
Definition StringUtils.cpp:31
std::vector< T > splitFloats(const std::string &iString, char iDelimiter, bool iSkipEmptyEntries=false)
Converts the string to an array of floating points (floats or doubles).
Definition StringUtils.h:109
bool stringToFloat(const std::string &iString, T &oValue)
Converts the string to a floating point (float or double).
Definition StringUtils.h:77
Definition CustomViewCreator.h:1251
Definition CustomController.h:26
std::initializer_list< typename AttrValMap< T >::value_type > AttrValInitList
Defines the type to initialize an [AttrValMap], for an example check [TCustomViewCreator::registerLis...
Definition CustomViewCreator.h:127
std::map< std::string, T > AttrValMap
Defines a map of string to attribute value.
Definition CustomViewCreator.h:121
TView * createCustomView(CRect const &iSize, const UIAttributes &iAttributes, const IUIDescription *)
Factory method which creates the actual view.
Definition CustomViewCreator.h:114
CGradient * GradientPtr
Definition Types.h:56
CFontDesc * FontPtr
Definition Types.h:52
CBitmap * BitmapPtr
Definition Types.h:48
Utils::Range< CCoord > Range
Defines a Range.
Definition Types.h:62
ParamID TagID
Defining a type for tags.
Definition Types.h:58
constexpr TagID UNDEFINED_TAG_ID
Constant used to test whether the TagID represents a valid id or an undefined one.
Definition Types.h:62
constexpr ParamID UNDEFINED_PARAM_ID
Constant used throughout the code to test whether the ParamID represents a valid id or an undefined o...
Definition Types.h:48
T fFrom
Definition Lerp.h:350
T fTo
Definition Lerp.h:351
Margin is a similar concept to css: used to create space around elements, outside of any defined bord...
Definition LookAndFeel.h:34
CCoord fLeft
Definition LookAndFeel.h:62
CCoord fTop
Definition LookAndFeel.h:59
CCoord fRight
Definition LookAndFeel.h:60
CCoord fBottom
Definition LookAndFeel.h:61