| title | Text & image labels |
|---|---|
| description | Explore how labels display customizable text and images in user interfaces. |
import TextFiltering from '../includes/text-filtering/text-filtering.md'
Labels are Class.GuiObject|GuiObjects that let you display customizable text and images on‑screen or in‑experience. There are two types of labels:
-
A
Class.TextLabelis a rectangle with text that you can style through customizable properties. This is the primary way to display text in an experience. -
An
Class.ImageLabelis a rectangle with an image asset that you can style through customizable properties. Alongside textures and decals, this lets you display images in an experience.
Labels on a screen are useful for things like displaying images of characters with dialog.
To add a label to a screen:
-
In the Explorer window, select StarterGui and add a ScreenGui.
-
Hover over StarterGui and click the ⊕ button. A contextual menu displays.
-
From the menu, insert a ScreenGui.
-
-
Select the new ScreenGui and add a label.
-
Hover over ScreenGui and click the ⊕ button. A contextual menu displays.
-
From the menu, insert a TextLabel or ImageLabel.
-
Labels on a part are useful for things like creating billboards, posters, and wallpaper.
To add a label to the face of a part:
-
In the Explorer window, insert a SurfaceGui onto the part.
-
Hover over the part instance and click the ⊕ button. A contextual menu displays.
-
From the menu, insert a SurfaceGui.
-
-
Select the new SurfaceGui and add a label.
-
Hover over the SurfaceGui and click the ⊕ button. A contextual menu displays.
-
From the menu, insert a TextLabel or ImageLabel.
If you don't see the button, try [choosing a different face](../parts/textures-decals.md#choose-a-face) in the Face property of the SurfaceGui.
-
All images within an Class.ImageLabel must be assets that have been imported to Studio. While the image automatically scales to fit the area of the rectangle, the image looks best when it displays at its native resolution.
You can customize the visual appearance of an image with the following properties:
-
Class.ImageLabel.ImageColor3|ImageColor3 -
Class.ImageLabel.ImageTransparency|ImageTransparency -
Class.GuiObject.BackgroundTransparency|BackgroundTransparency
For example, to display only the image and hide the rectangle, set the Class.GuiObject.BackgroundTransparency|BackgroundTransparency property to 1.
