Unit CastleUIControls
Description
User interface basic classes: TCastleUserInterface, TCastleContainer.
Uses
- SysUtils
- Classes
- Generics.Collections
- CastleKeysMouse
- CastleUtils
- CastleClassUtils
- CastleGLUtils
- CastleFonts
- CastleRectangles
- CastleTimeUtils
- CastleInternalPk3DConnexion
- CastleColors
- CastleImages
- CastleVectors
- CastleJoysticks
- CastleApplicationProperties
- CastleGLImages
- CastleRenderContext
- CastleComponentSerialize
- CastleMessaging
- CastleStringUtils
Overview
Classes, Interfaces, Objects and Records
Name | Description |
---|---|
Record TTouch |
Tracking of a touch by a single finger, used by TTouchList. |
Class TTouchList |
Tracking of multi-touch, a position of each finger on the screen. |
Class TInputInspector |
How to invoke the inspector, see TCastleContainer.InputInspector. |
Class TCastleContainer |
Abstract user interface container. |
Class TCastleUserInterface |
Basic user-interface class. |
Class TCastleUserInterfaceList |
List of TCastleUserInterface instances. |
Class TCastleView |
"View" represents the current state of your application user interface. |
Class TCastleViewList |
|
Class TInternalChildrenControls |
List of UI controls, with a parent control and container. |
Class TCastleTheme |
Theme for user interface controls. |
Functions and Procedures
function Theme: TCastleTheme; |
function FallbackTheme: TCastleTheme; |
procedure UserInterfaceSave(const C: TCastleUserInterface; const Url: String); |
function UserInterfaceLoad(const Url: String; const Owner: TComponent): TCastleUserInterface; |
function OnGLContextOpen: TGLContextEventList; deprecated 'use ApplicationProperties.OnGLContextOpen'; |
function OnGLContextClose: TGLContextEventList; deprecated 'use ApplicationProperties.OnGLContextClose'; |
function IsGLContextOpen: boolean; deprecated 'use ApplicationProperties.IsGLContextOpen'; |
function RenderControlToImage(const Container: TCastleContainer; const Control: TCastleUserInterface; const ViewportRect: TRectangle; const BackgroundColor: TCastleColor): TRGBAlphaImage; overload; |
Types
TBorder = CastleVectors.TBorder; |
TContainerObjectEvent = procedure (Container: TCastleContainer) of object; |
TUiNotifyEvent = procedure (const Sender: TCastleUserInterface) of object; |
TUiUpdateEvent = procedure (const Sender: TCastleUserInterface; const SecondsPassed: Single; var HandleInput: Boolean) of object; |
TUiPressReleaseEvent = procedure (const Sender: TCastleUserInterface; const Event: TInputPressRelease; var Handled: Boolean) of object; |
TUiMotionEvent = procedure (const Sender: TCastleUserInterface; const Event: TInputMotion; var Handled: Boolean) of object; |
TUIScaling = (...); |
TCastleUserInterfaceChange = (...); |
TCastleUserInterfaceChanges = set of TCastleUserInterfaceChange; |
TCastleUserInterfaceChangeEvent = procedure(const Sender: TCastleUserInterface; const Changes: TCastleUserInterfaceChanges; const ChangeInitiatedByChildren: boolean) of object; |
TPositionRelative = (...) deprecated; |
PTouch = ˆTTouch; |
TCastleUserInterfaceClass = class of TCastleUserInterface; |
TUIControlPos = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
TUIRectangularControl = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
TUIControl = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
TUIControlSizeable = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
TCastleUserInterfaceRect = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
TInputListener = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
TUIControlChange = TCastleUserInterfaceChange deprecated 'use TCastleUserInterfaceChange'; |
TUIControlChanges = TCastleUserInterfaceChanges deprecated 'use TCastleUserInterfaceChanges'; |
TUIControlList = TCastleUserInterfaceList deprecated 'use TCastleUserInterfaceList'; |
TUIControlChangeEvent = TCastleUserInterfaceChangeEvent deprecated 'use TCastleUserInterfaceChangeEvent'; |
TUIContainer = TCastleContainer deprecated 'use TCastleContainer'; |
TThemeImage = (...); |
Constants
DefaultDpi = 96.0; |
DefaultTooltipDelay = 1.0; |
DefaultTooltipDistance = 10; |
tiSlider = tiSliderBackground deprecated 'use tiSliderBackground'; |
tiSliderPosition = tiSliderThumb deprecated 'use tiSliderThumb'; |
prLeft = prLow deprecated; |
prRight = prHigh deprecated; |
prBottom = prLow deprecated; |
prTop = prHigh deprecated; |
hpLeft = CastleRectangles.hpLeft ; |
hpMiddle = CastleRectangles.hpMiddle; |
hpRight = CastleRectangles.hpRight ; |
vpBottom = CastleRectangles.vpBottom; |
vpMiddle = CastleRectangles.vpMiddle; |
vpTop = CastleRectangles.vpTop ; |
Description
Functions and Procedures
function Theme: TCastleTheme; |
Theme that you can customize, used by default by all UI controls. |
function FallbackTheme: TCastleTheme; |
Fallback (do not change this, ever) theme. Default state of Theme. |
procedure UserInterfaceSave(const C: TCastleUserInterface; const Url: String); |
Save / load TCastleUserInterface (or descendant) to a .castle-user-interface file. |
function UserInterfaceLoad(const Url: String; const Owner: TComponent): TCastleUserInterface; |
This item has no description. |
function OnGLContextOpen: TGLContextEventList; deprecated 'use ApplicationProperties.OnGLContextOpen'; |
Warning: this symbol is deprecated: use ApplicationProperties.OnGLContextOpen Called when first OpenGL context opens. |
function OnGLContextClose: TGLContextEventList; deprecated 'use ApplicationProperties.OnGLContextClose'; |
Warning: this symbol is deprecated: use ApplicationProperties.OnGLContextClose Called when last OpenGL context closes. |
function IsGLContextOpen: boolean; deprecated 'use ApplicationProperties.IsGLContextOpen'; |
Warning: this symbol is deprecated: use ApplicationProperties.IsGLContextOpen Is any OpenGL context open. |
function RenderControlToImage(const Container: TCastleContainer; const Control: TCastleUserInterface; const ViewportRect: TRectangle; const BackgroundColor: TCastleColor): TRGBAlphaImage; overload; |
Render control contents to an RGBA image, using off-screen rendering. The background behind the control is filled with BackgroundColor (which may be transparent, e.g. with alpha = 0). The rendering is done using off-screen FBO. Which means that you can request any size, you are not limited to your current window / control size. Make sure that the control is nicely positioned to fill the ViewportRect. Usually you want to adjust control size and position, and disable UI scaling (set TCastleUserInterface.EnableUIScaling = This is the easiest way to make off-screen rendering, i.e. to render 3D things (like TCastleScene in TCastleViewport) into an image. This is not the fastest way, as it creates new TGLRenderToTexture instance each time, and it grabs the image contents to CPU. If you want a faster approach, use TCastleContainer.RenderControl and render into TDrawableImage using TDrawableImage.RenderToImageBegin and TDrawableImage.RenderToImageEnd. |
Types
TBorder = CastleVectors.TBorder; |
type |
TContainerObjectEvent = procedure (Container: TCastleContainer) of object; |
This item has no description. |
TUiNotifyEvent = procedure (const Sender: TCastleUserInterface) of object; |
This item has no description. |
TUiUpdateEvent = procedure (const Sender: TCastleUserInterface; const SecondsPassed: Single; var HandleInput: Boolean) of object; |
This item has no description. |
TUiPressReleaseEvent = procedure (const Sender: TCastleUserInterface; const Event: TInputPressRelease; var Handled: Boolean) of object; |
This item has no description. |
TUiMotionEvent = procedure (const Sender: TCastleUserInterface; const Event: TInputMotion; var Handled: Boolean) of object; |
This item has no description. |
TUIScaling = (...); |
Possible values for TCastleContainer.UIScaling. Values
|
TCastleUserInterfaceChange = (...); |
Things that can cause TCastleUserInterface.VisibleChange notification. Values
|
TCastleUserInterfaceChanges = set of TCastleUserInterfaceChange; |
This item has no description. |
TCastleUserInterfaceChangeEvent = procedure(const Sender: TCastleUserInterface; const Changes: TCastleUserInterfaceChanges; const ChangeInitiatedByChildren: boolean) of object; |
This item has no description. |
TPositionRelative = (...) deprecated; |
Warning: this symbol is deprecated. Position for relative layout of one control in respect to another. Deprecated, rather use cleaner THorizontalPosition and TVerticalPosition. Values
|
PTouch = ˆTTouch; |
This item has no description. |
TCastleUserInterfaceClass = class of TCastleUserInterface; |
This item has no description. |
TUIControlPos = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
Warning: this symbol is deprecated: use TCastleUserInterface This item has no description. |
TUIRectangularControl = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
Warning: this symbol is deprecated: use TCastleUserInterface This item has no description. |
TUIControl = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
Warning: this symbol is deprecated: use TCastleUserInterface This item has no description. |
TUIControlSizeable = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
Warning: this symbol is deprecated: use TCastleUserInterface This item has no description. |
TCastleUserInterfaceRect = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
Warning: this symbol is deprecated: use TCastleUserInterface This item has no description. |
TInputListener = TCastleUserInterface deprecated 'use TCastleUserInterface'; |
Warning: this symbol is deprecated: use TCastleUserInterface This item has no description. |
TUIControlChange = TCastleUserInterfaceChange deprecated 'use TCastleUserInterfaceChange'; |
Warning: this symbol is deprecated: use TCastleUserInterfaceChange This item has no description. |
TUIControlChanges = TCastleUserInterfaceChanges deprecated 'use TCastleUserInterfaceChanges'; |
Warning: this symbol is deprecated: use TCastleUserInterfaceChanges This item has no description. |
TUIControlList = TCastleUserInterfaceList deprecated 'use TCastleUserInterfaceList'; |
Warning: this symbol is deprecated: use TCastleUserInterfaceList This item has no description. |
TUIControlChangeEvent = TCastleUserInterfaceChangeEvent deprecated 'use TCastleUserInterfaceChangeEvent'; |
Warning: this symbol is deprecated: use TCastleUserInterfaceChangeEvent This item has no description. |
TUIContainer = TCastleContainer deprecated 'use TCastleContainer'; |
Warning: this symbol is deprecated: use TCastleContainer This item has no description. |
TThemeImage = (...); |
Type of theme image, use of TCastleTheme.ImagesPersistent. Values
|
Constants
DefaultDpi = 96.0; |
Default value for container's Dpi, as is usually set on desktops. |
DefaultTooltipDelay = 1.0; |
This item has no description. |
DefaultTooltipDistance = 10; |
This item has no description. |
tiSlider = tiSliderBackground deprecated 'use tiSliderBackground'; |
Warning: this symbol is deprecated: use tiSliderBackground This item has no description. |
tiSliderPosition = tiSliderThumb deprecated 'use tiSliderThumb'; |
Warning: this symbol is deprecated: use tiSliderThumb This item has no description. |
prLeft = prLow deprecated; |
Warning: this symbol is deprecated. This item has no description. |
prRight = prHigh deprecated; |
Warning: this symbol is deprecated. This item has no description. |
prBottom = prLow deprecated; |
Warning: this symbol is deprecated. This item has no description. |
prTop = prHigh deprecated; |
Warning: this symbol is deprecated. This item has no description. |
hpLeft = CastleRectangles.hpLeft ; |
This item has no description. |
hpMiddle = CastleRectangles.hpMiddle; |
This item has no description. |
hpRight = CastleRectangles.hpRight ; |
This item has no description. |
vpBottom = CastleRectangles.vpBottom; |
This item has no description. |
vpMiddle = CastleRectangles.vpMiddle; |
This item has no description. |
vpTop = CastleRectangles.vpTop ; |
This item has no description. |
Generated by PasDoc 0.16.0-snapshot.