39 static IText text {34, COLOR_WHITE,
"Roboto-Regular", EAlign::Center, EVAlign::Top, 0};
49 IShadow shadow(COLOR_BLACK_DROP_SHADOW, 10.0, 3.0, 6.0, 0.7f,
true);
void StartLayer(IControl *pOwner, const IRECT &r, bool cacheable=false)
Create an IGraphics layer.
The lowest level base class of an IGraphics control.
Used to manage a rectangular area, independent of draw class/platform.
void ApplyLayerDropShadow(ILayerPtr &layer, const IShadow &shadow)
Applies a drop shadow directly onto a layer.
void DrawText(const IText &text, const char *str, const IRECT &bounds, const IBlend *pBlend=0)
Draw some text to the graphics context in a specific rectangle.
void Draw(IGraphics &g) override
Draw the control to the graphics context.
This file contains the base IControl implementation, along with some base classes for specific types ...
IText is used to manage font and text/text entry style for a piece of text on the UI...
bool CheckLayer(const ILayerPtr &layer)
Test to see if a layer needs drawing, for instance if the control's bounds were changed.
IControl(const IRECT &bounds, int paramIdx=kNoParameter, IActionFunction actionFunc=nullptr)
Constructor.
The lowest level base class of an IGraphics context.
Used to specify properties of a drop-shadow to a layer.
virtual void FillRect(const IColor &color, const IRECT &bounds, const IBlend *pBlend=0)
Fill a rectangular region of the graphics context with a color.
void DrawLayer(const ILayerPtr &layer, const IBlend *pBlend=nullptr)
Draw a layer to the main IGraphics context.
void Pad(float padding)
Pad this IRECT N.B.
ILayerPtr EndLayer()
End an IGraphics layer.
std::unique_ptr< ILayer > ILayerPtr
ILayerPtr is a managed pointer for transferring the ownership of layers.
Control to display the graphics backend.
virtual float MeasureText(const IText &text, const char *str, IRECT &bounds) const
Measure the rectangular region that some text will occupy.
virtual const char * GetDrawingAPIStr()=0