Search Issue Tracker

By Design

Votes

0

Found in

2017.4.0f1

2018.3.0a5

2018.3.11f1

2019.1.0a1

2019.2.0a1

Issue ID

1143009

Regression

No

RectTransform Width, Height values are changed when adding 'TMP-Text(UI)' component and 'TMP Essential Resources' are imported

uGUI

-

How to reproduce:
1. Create a new project
2. Import 'TMP Essential Resources' by going to top menu -> 'Window' -> 'TextMeshPro' -> 'Import TMP Essential Resources' and press 'Import' button
3. Create a 'Canvas' Game Object. Right-click in the Hierarchy 'UI' -> 'Canvas'
4. Add an empty game object to Canvas. Right-click on 'Canvas' -> 'Create Empty'
5. Add 'TextMeshPro - Text (UI)' component to the empty 'GameObject' in the Inspector tab

Expected result: No changes in Rect Transform
Actual result: Width and Height parameters are changed

Reproducible: 2017.4.25f1, 2018.3.12f1, 2019.1.0f1, 2019.2.0a11
Can't reproduce: 2018.3.0a1, 2018.3.0a2, 2018.3.0a4 because missing of UI creation

  1. Resolution Note:

    This behavior is by design in the sense that the default size of the text container (RectTransform) is defined in the TMP Settings. As such, when adding a Text component, it will lookup those defined default sizes and adjust the RectTransform accordingly.

    If the RectTransform is defined with a size other than 100 x 100 which is their default size, the Text Component will override that size by the TMP Settings default settings. If the RectTransform is created and changed to some other size, then adding the Text component will not override that size.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.