There is no spoon

UE3:UIScrollFrame (UDK)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
UDK Object >> UIRoot >> UIScreenObject >> UIObject >> UIContainer >> UIScrollFrame
Package: 
Engine
Direct subclass:
UTUIStatsList
This class in other games:
UT3

This widget defines a region in which its child widgets can be placed. If any of its children lay outside of its defined region then a scroll bar will be made visible to allow the region to be scrolled to the outside widgets.

Properties

Property group 'Components'

StaticBackgroundImage

Type: UIComp_DrawImage

Modifiers: editinline, const

Component for rendering the background image. If given a value, this image will not move when the user scrolls, whereas the background image for the client panel will.

Property group 'ZDebug'

HorizontalClientRegion

Type: UIRoot.UIScreenValue_Extent

Modifiers: editinline, editconst, private, transient

The horizontal extent of the region which contains this widget's children. If this region is greater than the horizontal extent of this scrollframe, the horizontal scrollbar will be made visible.

VerticalClientRegion

Type: UIRoot.UIScreenValue_Extent

Modifiers: editinline, editconst, private, transient

The vertical extent of the region which contains this widget's children. If this region is greater than the vertical extent of this scrollframe, the vertical scrollbar will be made visible.

Default value:

Member Value
Orientation UIORIENT_Vertical

Internal variables

bRecalculateClientRegion

Type: bool

Modifiers: private, const, transient

indicates that the client region is out of date and needs to be recalculated

bRefreshScrollbars

Type: bool

Modifiers: private, const, transient

indicates when the scrollbars need to be updated

ClientRegionPosition

Type: Object.Vector2D

Modifiers: private, transient

Represents the position of the client region with respect to this scrollframe. Values are from 0.0 - 1.0, where 0,0 means that the top-left of the client region is at the top-left corner of this widget, and a value of 1,1 means that the bottom-right of the client region is at the top-left corner of this widget.

FrameBounds

Type: float

Array size: 4 (EUIWidgetFace.UIFACE_MAX)

Modifiers: private, transient

caches the value of the frame's bounding region extent (includes any rotation)

ScrollbarHorizontal

Type: UIScrollbar

Modifiers: const, private

A scrollbar widget that allows the entire RegionExtent to be scrolled to for the horizontal dimension.

Default value: UIScrollbar'Engine.Default__UIScrollFrame:HorzScrollbarTemplate'

ScrollbarVertical

Type: UIScrollbar

Modifiers: const, private

A scrollbar widget that allows the entire RegionExtent to be scrolled to for the horizontal dimension.

Default value: UIScrollbar'Engine.Default__UIScrollFrame:VertScrollbarTemplate'

Default values

Property Value
bSupportsPrimaryStyle False
DefaultStates[2] Class'Engine.UIState_Focused'
PrimaryStyle
Member Value
DefaultStyleTag 'DefaultImageStyle'
RequiredStyleClass Class'Engine.UIStyle_Image'

Subobjects

WidgetEventComponent

Class: Engine.UIComp_Event

Inherits from: UIContainer.WidgetEventComponent

No new values.

Functions

Native functions

GetClientRegionPosition

native final function float GetClientRegionPosition (UIRoot.EUIOrientation Orientation) const

Gets the position of either the left or top side of the client region.

Parameters:

  • Orientation - specify UIORIENT_Horizontal to retrieve the position of the left side; specify UIORIENT_Vertical to retrieve the position of the top side.

Returns:

the position of the client region, in canvas coordinates relative to the top left corner of this widget.

GetClientRegionPositionVector

native final function Object.Vector2D GetClientRegionPositionVector () const

Gets the position of the upper-left corner of the client region.

Returns:

the position of the client region, in canvas coordinates relative to the top left corner of this widget.

GetClientRegionSize

native final function float GetClientRegionSize (UIRoot.EUIOrientation Orientation) const

Returns the size of a single orientation of the client region, in pixels.

Parameters:

  • Orientation - specify UIORIENT_Horizontal to retrieve the width of the client region or UIORIENT_Vertical to get the height of the client region.

Returns:

the width or height of the client region, in pixels.

GetClientRegionSizeVector

native final function Object.Vector2D GetClientRegionSizeVector () const

Returns the size of the client region, in pixels.

Returns:

the size of the client region, in pixels.

GetClipRegion

native function GetClipRegion (out float MinX, out float MinY, out float MaxX, out float MaxY) const

Returns a vector containing the size of the region (in pixels) available for rendering inside this scrollframe, taking account whether the scrollbars are visible.

GetVisibleRegionPercentage

native final function float GetVisibleRegionPercentage (UIRoot.EUIOrientation Orientation) const

Returns the percentage of the client region that is visible within the scrollframe's bounds.

Parameters:

  • Orientation - specifies whether to return the vertical or horizontal percentage.

Returns:

a value from 0.0 to 1.0 representing the percentage of the client region that can be visible at once.

ReapplyFormatting

native final function ReapplyFormatting (optional bool bImmediately)

Sets the flag indicating that the client region needs to be recalculated. Does not necessarily trigger a scene update.

Parameters:

  • bImmediately - specify TRUE to immediately recalculate the client region instead of batching up and waiting until the next scene update.

RefreshScrollbars

native final function RefreshScrollbars (optional bool bImmediately)

Sets the flag indicating that the scrollbars need to be re-resolved. Does not necessarily trigger a scene update.

Parameters:

  • bImmediately - specify TRUE to resolve the scrollbars immediately instead of batching until the next scene update.

ScrollRegion

native final function bool ScrollRegion (UIScrollbar Sender, float PositionChange, optional bool bPositionMaxed)

Scrolls all of the child widgets by the specified amount in the specified direction.

Parameters:

  • Sender - the scrollbar that generated the event.
  • PositionChange - indicates the amount that the scrollbar has travelled.
  • bPositionMaxed - indicates that the scrollbar's marker has reached its farthest available position, used to achieve pixel exact scrolling

SetClientRegionPosition

native final function bool SetClientRegionPosition (UIRoot.EUIOrientation Orientation, float NewPosition)

Changes the position of the client region and synchronizes the scrollbars to the new position.

Parameters:

  • Orientation - specify UIORIENT_Horizontal to set the position of the left side; specify UIORIENT_Vertical to set the position of the top side.
  • NewPosition - the position to move the client region to, in pixels.

Returns:

TRUE if the client region was moved successfully.

SetClientRegionPositionVector

native final function bool SetClientRegionPositionVector (Object.Vector2D NewPosition)

Changes the position of the client region and synchronizes the scrollbars to the new position.

Parameters:

  • NewPosition - the position to move the client region to, in pixels.

Returns:

TRUE if the client region was moved successfully.

Events

AddedChild

event AddedChild (UIScreenObject WidgetOwner, UIObject NewChild)

Overrides: UIScreenObject.AddedChild

Called immediately after a child has been added to this screen object. Sets up NotifyPositionChanged delegate in the added child

Parameters:

  • WidgetOwner - the screen object that the NewChild was added as a child for
  • NewChild - the widget that was added

RemovedChild

event RemovedChild (UIScreenObject WidgetOwner, UIObject OldChild, optional array<UIObjectExclusionSet)

Overrides: UIScreenObject.RemovedChild

Called immediately after a child has been removed from this screen object. Clears the NotifyPositionChanged delegate in the removed child

Parameters:

  • WidgetOwner - the screen object that the widget was removed from.
  • OldChild - the widget that was removed
  • ExclusionSet - used to indicate that multiple widgets are being removed in one batch; useful for preventing references between the widgets being removed from being severed. NOTE: If a value is specified, OldChild will ALWAYS be part of the ExclusionSet, since it is being removed.

ScrollZoneClicked

private event ScrollZoneClicked (UIScrollbar Sender, float PositionPerc, int PlayerIndex)

Handler for the scrollbars' OnClickedScrollZone delegate. Scrolls the client region by a full page.

Parameters:

  • Sender - the scrollbar that was clicked.
  • PositionPerc - a value from 0.0 - 1.0, representing the location of the click within the region between the increment and decrement buttons. Values closer to 0.0 means that the user clicked near the decrement button; values closer to 1.0 are nearer the increment button.
  • PlayerIndex - index of the player that generated the scrollzone click.

Other instance functions

OnChildRepositioned

final function OnChildRepositioned (UIScreenObject Sender)

Handler for NotifyPositionChanged delegate for children of this panel. Sets the flag indicating that the panel should recalculate the client region.

Parameters:

  • Sender - Child widget which has been repositioned