Encapsulation of the visual elements of a Frame.
More...
#include <Frame.h>
|
| enum | SelectedCorners : uint32_t {
NoCorners = 0,
TopLeftCorner = 0x8,
TopRightCorner = 0x4,
TopCorners = TopLeftCorner | TopRightCorner,
BottomLeftCorner = 0x2,
BottomRightCorner = 0x1,
BottomCorners = BottomLeftCorner | BottomRightCorner,
LeftCorners = TopLeftCorner | BottomLeftCorner,
RightCorners = TopRightCorner | BottomRightCorner,
AllCorners = 0xf
} |
| | Specify corners selected for some process, usually drawing.
|
| |
| enum | SelectedSides : uint32_t {
NoSides = 0,
TopSide = 1,
BotSide = 2,
LeftSide = 4,
RightSide = 8,
AllSides = TopSide | BotSide | LeftSide | RightSide,
TabTopSides = TopSide | LeftSide | RightSide
} |
| | Specify sides selected for some process, usually drawing.
|
| |
|
| void | renderSelectedSides (gm::Context &context, FrameElements::SelectedSides selectedSides, BorderStyle useBorder, ImageId corner, const Size &size, int extend=0) |
| | Render sides as part of a border around the frame. More...
|
| |
| void | drawBackground (gm::Context &context, Rectangle &src, Rectangle &dst) |
| | Draw the background for the Frame. More...
|
| |
|
gm::Texture | createBackgroundTexture (gm::Context &context, Rectangle &src, Rectangle &dst, const color::RGBA &color) |
| |
|
std::tuple< UseBorder, SelectedCorners > | decoration () |
| |
| void | drawFrame (gm::Context &context, Rectangle widgetRect) |
| | Draw the Frame and background. More...
|
| |
| void | buttonDisplayStateChange (ButtonDisplayState buttonDisplayState) |
| | Make visual changes to FrameElements for button display. More...
|
| |
Encapsulation of the visual elements of a Frame.
◆ buttonDisplayStateChange()
| void rose::FrameElements::buttonDisplayStateChange |
( |
ButtonDisplayState |
buttonDisplayState | ) |
|
|
protected |
Make visual changes to FrameElements for button display.
- Parameters
-
| buttonDisplayState | The button display state. |
◆ drawBackground()
Draw the background for the Frame.
The Frame background is the background color and the border.
- Parameters
-
| renderer | The renderer to use. |
| src | The source rectangle. |
| dst | The destination rectangle. |
◆ drawFrame()
Draw the Frame and background.
- Parameters
-
| renderer | The Renderer used to draw the Frame. |
| widgetRect | The Rectangle available to draw in. |
◆ renderSelectedCorners()
Render corner images as part of a border around the frame.
- Parameters
-
| renderer | The Renderer to use |
| selectedCorners | The corners to render, others are left undecorated. |
| corner | The RoseImageId of the corner Texture sheet |
| size | The destination rectangle for the complete frame. |
◆ renderSelectedSides()
Render sides as part of a border around the frame.
- Parameters
-
| renderer | The Renderer to use |
| selectedSides | The sides to render, others are left undecorated. |
| useBorder | The border style used. |
| corner | The RoseImageId of the corner Texture sheet, to get the size of corner images. |
| size | The destination rectangle for the complete frame. |
| extend | If true, extend the side(s) in the direction of increasing Y or X (down or right). |
◆ trimCorners()
Trim corners on a background surface to allow for rounded corners.
- Parameters
-
| surface | The surface to trim |
| color | The background fill color. |
| selectedCorners | Which corners should be trimmed, others are left square. |
| cornerSize | The size of the corner in piexels |
| frameSize | The size of the frame. |
The documentation for this class was generated from the following files: