ImageLabel
A non-interactive GUI image with shared text-layout properties.
- Creatable
Instance.new("ImageLabel")- Inherits
- GuiLabelGuiObjectGuiBase2dGuiBaseInstance
- Replication
- Standard
Behavior
ImageLabel displays an image without button activation. The text-layout fields
are available when the label carries text content.
Summary
The resolved top-left position of this interface element in pixels.
The resolved rotation of this interface element in degrees, including ancestor rotation.
The resolved width and height of this interface element in pixels.
Whether this interface accepts and consumes input.
The normalized point within the element used as the origin for Position.
The dimensions that resize to fit the element's content.
The color used to fill the element's background.
The background transparency, from 0 for opaque to 1 for invisible.
The color of the element's border.
Whether the border is drawn outside, across, or inside the element's bounds.
The border thickness in pixels.
Whether descendant rendering is clipped to this element's bounds.
The corner radius used for the element's rounded background.
The individual corner radii used for the element's rounded background.
Whether pointer dragging can move the element.
The share of remaining main-axis space assigned to this child in flow layout.
The element's current idle, hover, pressed, or non-interactable state.
The content identifier of the displayed image.
The tint multiplied into the image color.
The top-left pixel offset of the image region to display.
The size in pixels of the image region to display.
The image transparency, from 0 for opaque to 1 for invisible.
Which input events this element consumes before they reach elements behind it.
Whether the element accepts interaction.
Whether children use flow layout or their explicit positions.
The numeric order of this element when a parent layout sorts by layout order.
The interface element selected when navigating down from this element.
The interface element selected when navigating left from this element.
The interface element selected when navigating right from this element.
The interface element selected when navigating up from this element.
The opacity multiplier applied to this element and its descendants.
The element position relative to its parent.
The sampling method used when scaling the image.
The interface rotation in degrees.
Whether the image stretches, slices, tiles, fits, or crops to its bounds.
Whether interface navigation can select this element.
The interface element used to draw the selection indicator.
The numeric order used for interface selection traversal.
The element size relative to its parent.
The parent axes used to resolve relative interface size.
The inner rectangle used for nine-slice image scaling.
The scale applied to the borders of a nine-slice image.
The size of one repeated tile when the image uses tile scaling.
Whether this interface element is rendered.
The element's draw-order index.
Gives keyboard focus to this interface element.
Returns this instance if it is an ExecutionGroup.
Removes keyboard focus from this interface element.
Fires when pointer dragging of the element begins.
Fires when pointer dragging of the element ends.
Fires when input begins over or is dispatched to this interface element.
Fires when input dispatched to this element changes.
Fires when input dispatched to this element ends.
Fires when the mouse wheel scrolls backward over this element.
Fires when the mouse wheel scrolls forward over this element.
Fires when a pointer moves onto the label.
Fires when a pointer moves off the label.
Fires when the pointer moves across the label.
Fires when interface navigation selects this element.
Fires when this element loses interface selection.
Properties
AbsolutePosition
ImageLabel.AbsolutePosition: Vector2 = Vector2.new(0, 0)The resolved top-left position of this interface element in pixels.
AbsoluteRotation
ImageLabel.AbsoluteRotation: number = 0The resolved rotation of this interface element in degrees, including ancestor rotation.
AbsoluteSize
ImageLabel.AbsoluteSize: Vector2 = Vector2.new(0, 0)The resolved width and height of this interface element in pixels.
Active
ImageLabel.Active: boolean = falseWhether this interface accepts and consumes input.
AnchorPoint
ImageLabel.AnchorPoint: Vector2 = Vector2.new(0, 0)The normalized point within the element used as the origin for Position. (0, 0) is the top-left corner; (0.5, 0.5) is the center.
AutomaticSize
ImageLabel.AutomaticSize: Enum.AutomaticSize = Enum.AutomaticSize.NoneThe dimensions that resize to fit the element's content.
BackgroundColor3
ImageLabel.BackgroundColor3: Color3 = Color3.new(0.6392157, 0.63529414, 0.64705884)The color used to fill the element's background.
BackgroundTransparency
ImageLabel.BackgroundTransparency: number = 0The background transparency, from 0 for opaque to 1 for invisible.
BorderColor3
ImageLabel.BorderColor3: Color3 = Color3.new(0.105882354, 0.16470589, 0.20784314)The color of the element's border.
BorderMode
ImageLabel.BorderMode: Enum.BorderMode = Enum.BorderMode.OutlineWhether the border is drawn outside, across, or inside the element's bounds.
BorderSizePixel
ImageLabel.BorderSizePixel: number = 1The border thickness in pixels.
ClipsDescendants
ImageLabel.ClipsDescendants: boolean = falseWhether descendant rendering is clipped to this element's bounds.
CornerRadius
ImageLabel.CornerRadius: number = 0The corner radius used for the element's rounded background.
Corners
ImageLabel.Corners: { number } = {}The individual corner radii used for the element's rounded background.
Draggable
ImageLabel.Draggable: boolean = falseWhether pointer dragging can move the element.
Grow
ImageLabel.Grow: number = 0The share of remaining main-axis space assigned to this child in flow layout.
GuiState
ImageLabel.GuiState: Enum.GuiState = Enum.GuiState.IdleThe element's current idle, hover, pressed, or non-interactable state.
Image
ImageLabel.Image: Content = ""The content identifier of the displayed image.
ImageColor3
ImageLabel.ImageColor3: Color3 = Color3.new(1, 1, 1)The tint multiplied into the image color.
ImageRectOffset
ImageLabel.ImageRectOffset: Vector2 = Vector2.new(0, 0)The top-left pixel offset of the image region to display.
ImageRectSize
ImageLabel.ImageRectSize: Vector2 = Vector2.new(0, 0)The size in pixels of the image region to display.
ImageTransparency
ImageLabel.ImageTransparency: number = 0The image transparency, from 0 for opaque to 1 for invisible.
InputSink
ImageLabel.InputSink: Enum.InputSink = Enum.InputSink.NoneWhich input events this element consumes before they reach elements behind it.
Interactable
ImageLabel.Interactable: boolean = trueWhether the element accepts interaction.
Layout
ImageLabel.Layout: Enum.Layout = Enum.Layout.FlowWhether children use flow layout or their explicit positions.
LayoutOrder
ImageLabel.LayoutOrder: number = 0The numeric order of this element when a parent layout sorts by layout order.
NextSelectionDown
ImageLabel.NextSelectionDown: GuiObject? = nilThe interface element selected when navigating down from this element.
NextSelectionLeft
ImageLabel.NextSelectionLeft: GuiObject? = nilThe interface element selected when navigating left from this element.
NextSelectionRight
ImageLabel.NextSelectionRight: GuiObject? = nilThe interface element selected when navigating right from this element.
NextSelectionUp
ImageLabel.NextSelectionUp: GuiObject? = nilThe interface element selected when navigating up from this element.
Opacity
ImageLabel.Opacity: number = 1The opacity multiplier applied to this element and its descendants.
Position
The element position relative to its parent. Scale components use the parent size; offsets are in pixels.
ResampleMode
ImageLabel.ResampleMode: Enum.ResamplerMode = Enum.ResamplerMode.DefaultThe sampling method used when scaling the image.
Rotation
ImageLabel.Rotation: number = 0The interface rotation in degrees.
ScaleType
ImageLabel.ScaleType: Enum.ScaleType = Enum.ScaleType.StretchWhether the image stretches, slices, tiles, fits, or crops to its bounds.
Selectable
ImageLabel.Selectable: boolean = falseWhether interface navigation can select this element.
SelectionImageObject
ImageLabel.SelectionImageObject: GuiObject? = nilThe interface element used to draw the selection indicator.
SelectionOrder
ImageLabel.SelectionOrder: number = 0The numeric order used for interface selection traversal.
Size
The element size relative to its parent. Scale components use the parent size; offsets are in pixels.
SizeConstraint
ImageLabel.SizeConstraint: Enum.SizeConstraint = Enum.SizeConstraint.RelativeXYThe parent axes used to resolve relative interface size.
SliceCenter
The inner rectangle used for nine-slice image scaling.
SliceScale
ImageLabel.SliceScale: number = 1The scale applied to the borders of a nine-slice image.
TileSize
The size of one repeated tile when the image uses tile scaling.
Visible
ImageLabel.Visible: boolean = trueWhether this interface element is rendered.
ZIndex
ImageLabel.ZIndex: number = 1The element's draw-order index. Interpretation depends on the root's ZIndexBehavior.
Methods
CaptureFocus
ImageLabel:CaptureFocus(): ()Gives keyboard focus to this interface element.
GetExecutionGroup
ImageLabel:GetExecutionGroup(): ExecutionGroup?Returns this instance if it is an ExecutionGroup. Otherwise returns the nearest ancestor ExecutionGroup, or nil when no group contains the instance.
ReleaseFocus
ImageLabel:ReleaseFocus(): ()Removes keyboard focus from this interface element.
Events
DragBegin
ImageLabel.DragBegin: RBXScriptSignalFires when pointer dragging of the element begins.
DragStopped
ImageLabel.DragStopped: RBXScriptSignalFires when pointer dragging of the element ends.
InputBegan
ImageLabel.InputBegan: RBXScriptSignalFires when input begins over or is dispatched to this interface element.
InputChanged
ImageLabel.InputChanged: RBXScriptSignalFires when input dispatched to this element changes.
InputEnded
ImageLabel.InputEnded: RBXScriptSignalFires when input dispatched to this element ends.
MouseWheelBackward
ImageLabel.MouseWheelBackward: RBXScriptSignalFires when the mouse wheel scrolls backward over this element.
MouseWheelForward
ImageLabel.MouseWheelForward: RBXScriptSignalFires when the mouse wheel scrolls forward over this element.
PointerEntered
ImageLabel.PointerEntered: RBXScriptSignalFires when a pointer moves onto the label.
PointerExited
ImageLabel.PointerExited: RBXScriptSignalFires when a pointer moves off the label.
PointerMoved
ImageLabel.PointerMoved: RBXScriptSignalFires when the pointer moves across the label.
SelectionGained
ImageLabel.SelectionGained: RBXScriptSignalFires when interface navigation selects this element.
SelectionLost
ImageLabel.SelectionLost: RBXScriptSignalFires when this element loses interface selection.
Inherited members
- Properties
- CatchesPointer
- Properties
- ArchivableClassNameNameParent
- Methods
- AddComponent()AddTag()ClearAllChildren()ClearTags()Clone()Destroy()FindFirstAncestor()FindFirstAncestorOfClass()FindFirstAncestorWhichIsA()FindFirstChild()FindFirstChildOfClass()FindFirstChildWhichIsA()FindFirstDescendant()GetAttribute()GetAttributeChangedSignal()GetAttributes()GetChildren()GetComponent()GetComponentChangedSignal()GetComponents()GetDebugId()GetDescendants()GetFullName()GetPropertyChangedSignal()GetReferencing()GetTags()HasComponent()HasTag()IsA()IsAncestorOf()IsDescendantOf()RemoveComponent()RemoveTag()SetAttribute()WaitForChild()
- Events
- AncestryChangedAttributeChangedChangedChildAddedChildRemovedDescendantAddedDescendantRemovingDestroying
Example
local image = Instance.new("ImageLabel")
image.Image = "astasset://ui/logo.png"
image.Parent = game:GetService("Players").LocalPlayer.PlayerGui