TextBox PlaceholderText doesn't support RichText

Description:
When attempting to give a RichText tag (such as bold) to the PlaceholderText of a TextBox which has RichText enabled, the RichText doesn’t apply to the PlaceholderText.

Reproduction Steps:

To replicate this without a script:

  1. Insert a ScreenGui into StarterGui (the default properties seem to trigger this behavior, so no tinkering is needed)
  2. Insert a TextBox which is parented to the previously created StarterGui
  3. Enable RichText in the TextBox
  4. Type some text into the PlaceholderText with RichText tags. For my example, I used the following text: <u><i><b><s>TEST</s></b></i></u>

The following script can be run in the command bar to replicate this bug as well:

local textbox = Instance.new("TextBox")

textbox.RichText = true 
textbox.Text = "" 
textbox.PlaceholderText = "<u><i><b><s>TEST</s></b></i></u>" 
textbox.Size = UDim2.new(.5,0,.5,0) 
textbox.BackgroundColor3 = Color3.fromRGB(0, 0, 0)

screengui.Parent = game:GetService("StarterGui")
textbox.Parent = screengui

Expected:


(The RichText tags are applied)
Actual:

(The RichText tags aren’t applied)

Date First Experienced: 2022-08-02 23:30:00 (-5:00)
Issue Area: Engine

An RBXM file replicating this issue is linked below:
TextBoxRichTextBug.rbxm (4.1 KB)

6 Likes

Hi @Rainbo1239 - thank you for the report. Rich text isn’t currently supported with placeholder text, so this behavior is expected for now. However, we will track this as a feature request as we think rich text would be a great enhancement to placeholder text!

3 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.