Represents the border around an element.
Public Member Functions | |
BorderProperty (Element element) | |
Creates a new border property for the given element. More... | |
void | ResetColour () |
override void | SetOverlayColour (Color colour) |
Called to apply the given colour overlay to this property. More... | |
override void | Paint () |
Called when a paint event occurs. Paint events don't relocate the whole UI so are quick and efficient. More... | |
void | BorderTransform (Transformation topTransform) |
Transforms all the blocks that this property has allocated. Note that transformations are a post process. Special case for borders as it may also internally transform its corners. More... | |
void | ApplyBorderTransform () |
Applies any transforms (rotate,scale etc) now. Note that tranforms are post-processes so they are very fast and mostly done by paint events. Special case for borders as it may also transform corners. More... | |
void | SetCorner (RoundCornerPosition position, int radius) |
void | RenderCorners () |
int | BorderWidth (int i) |
Gets the width of the numbered border. More... | |
Public Member Functions inherited from PowerUI.Css.DisplayableProperty | |
DisplayableProperty (Element element) | |
Creates a new displayable property for the given element. More... | |
void | SetVisibility (bool visible) |
Call this when the visibility of this property as a whole changes. More... | |
void | SetOverlayColour () |
Sets the overlay colour from the elements colour overlay property. More... | |
void | ColourChanged () |
Call this when any colour of this property has changed. More... | |
virtual void | OnBatchDestroy () |
Called when the isolation batch for this property gets removed. More... | |
void | Change (string property, Value newValue) |
Called when a named css property changes. More... | |
void | ClearBlocks () |
Clears all mesh blocks that this property has allocated. More... | |
void | WentOffScreen () |
Vector3 | MapPX (float x, float y, float z) |
Maps the given pixel location to a world location. More... | |
void | Render () |
Make this property visible by forcing it to redraw. More... | |
void | RequestPaint () |
Requests for a paint event to occur. Note that paint events are more efficient than a layout as they only refresh the mesh colours and uvs rather than the whole mesh. More... | |
void | RequestLayout () |
Requests for a layout event to occur. Note that paint events are more efficient than a layout as they only refresh the mesh colours and uvs rather than the whole mesh. More... | |
MeshBlock | Add () |
Allocates a new mesh block for this property to use. Mesh blocks are the core of how PowerUI displays content. More... | |
void | Transform (Transformation topTransform) |
Transforms all the blocks that this property has allocated. Note that transformations are a post process. More... | |
void | ApplyTransform () |
Applies any transforms (rotate,scale etc) now. Note that tranforms are post-processes so they are very fast and mostly done by paint events. More... | |
void | Isolate () |
Isolates this property from the rest of the UI such that it can have a custom mesh/shader/texture etc. More... | |
void | Include () |
Reverses PowerUI.Css.DisplayableProperty.Isolate by re-including this property in the main UI batch. More... | |
bool | IsIsolated () |
Checks if this is an isolated property - that's one which is seperate and takes its own drawcall. More... | |
void | SetupBatch (TextureAtlas graphics, TextureAtlas font) |
AtlasLocation | RequireImage (AtlasEntity image) |
Public Attributes | |
int | WidthTop |
The width of the border on the top edge. More... | |
int | WidthLeft |
The width of the border on the left edge. More... | |
int | WidthRight |
The width of the border on the right edge. More... | |
int | WidthBottom |
The width of the border on the bottom edge. More... | |
Color[] | Colour =null |
The colour the border should be with any colour overlay applied. Black if undefined. More... | |
Css.Value | BaseColour =null |
The colour of the border without the colour overlay. Black if undefined. More... | |
RoundedCorners | Corners =null |
The set of round corners if any. More... | |
BorderStyle | Style =BorderStyle.Solid |
How the border should appear. Note that only solid is currently used. More... | |
Public Attributes inherited from PowerUI.Css.DisplayableProperty | |
bool | Visible |
True if this is currently visible on screen. More... | |
bool | Changed |
True if this property has changed its appearance. More... | |
bool | Isolated |
True if this property is isolated and has a seperate mesh and material from everything else. More... | |
int | BlockCount |
The number of mesh blocks that this property has allocated. More... | |
Element | Element |
The parent element that this is a property of. More... | |
MeshBlock | FirstBlock |
The first mesh block that this property has allocated. This is the head of a linked list. More... | |
bool | GotBatchAlready |
Only applies to Isolated properties. Set to true when this property has allocated a UIBatch on the current layout. More... | |
Protected Member Functions | |
override void | Layout () |
Called when a layout event occurs. Layout events relocate the whole UI so should be used less frequently than a paint event. More... | |
Protected Member Functions inherited from PowerUI.Css.DisplayableProperty | |
virtual bool | NowOnScreen () |
Called when this element goes on screen. More... | |
virtual void | NowOffScreen () |
Called when this element goes off screen (or is removed from the DOM). More... | |
virtual void | OnChange (string property, Value newValue) |
Called when a named css property changes. More... | |
Additional Inherited Members | |
Properties inherited from PowerUI.Css.DisplayableProperty | |
bool | Paintable [get] |
Checks if this property can be repainted. More... | |
|
inline |
Creates a new border property for the given element.
element | The element to give a border to. |
|
inline |
Applies any transforms (rotate,scale etc) now. Note that tranforms are post-processes so they are very fast and mostly done by paint events. Special case for borders as it may also transform corners.
|
inline |
Transforms all the blocks that this property has allocated. Note that transformations are a post process. Special case for borders as it may also internally transform its corners.
topTransform | The transform that should be applied to this property. |
|
inline |
Gets the width of the numbered border.
i | The border index. Goes around clockwise: 0=Top, 1=Right, 2=Bottom, 3=Left. |
|
inlineprotectedvirtual |
Called when a layout event occurs. Layout events relocate the whole UI so should be used less frequently than a paint event.
Reimplemented from PowerUI.Css.DisplayableProperty.
|
inlinevirtual |
Called when a paint event occurs. Paint events don't relocate the whole UI so are quick and efficient.
Reimplemented from PowerUI.Css.DisplayableProperty.
|
inline |
|
inline |
|
inline |
|
inlinevirtual |
Called to apply the given colour overlay to this property.
colour | The colour overlay to apply. |
Reimplemented from PowerUI.Css.DisplayableProperty.
Css.Value PowerUI.Css.BorderProperty.BaseColour =null |
The colour of the border without the colour overlay. Black if undefined.
Color [] PowerUI.Css.BorderProperty.Colour =null |
The colour the border should be with any colour overlay applied. Black if undefined.
RoundedCorners PowerUI.Css.BorderProperty.Corners =null |
The set of round corners if any.
BorderStyle PowerUI.Css.BorderProperty.Style =BorderStyle.Solid |
How the border should appear. Note that only solid is currently used.
int PowerUI.Css.BorderProperty.WidthBottom |
The width of the border on the bottom edge.
int PowerUI.Css.BorderProperty.WidthLeft |
The width of the border on the left edge.
int PowerUI.Css.BorderProperty.WidthRight |
The width of the border on the right edge.
int PowerUI.Css.BorderProperty.WidthTop |
The width of the border on the top edge.