Quantcast
Channel: UGUI & TextMesh Pro
Viewing all 23263 articles
Browse latest View live

TMP Text flickering in specific scenario.

$
0
0
One of my users (only one currently) is reporting that their text starts flickering specifically if they have a bunch of other apps open or when they get a push notification on their phone. It won't stop until the app is restarted. I have already verified its not z-fighting. I recently swapped text fonts in my game and then this started happening for this user, the other font was in use for months with no issues for them. I have set all of the settings for this font to be the same as the one...

TMP Text flickering in specific scenario.

TMPro SubMeshUI Error when changing scenes

$
0
0
My game recently updated to Unity 2019.4.28f1 and we added the latest TMPro 2.1.6 as well. What we have noticed is that we have been getting a lot of errors from SubMeshUI when leaving a scene but it's hard to reproduce and I haven't been able to reproduce it but my game gets 5000 errors a day. So it's basically when we open a scene and that scene contains a fallback character. When exiting the scene the error occurs.
In my code we also do a specific Destroy certain GameObjects that has been...

TMPro SubMeshUI Error when changing scenes

What is the cause and fix for jagged edges on a rotated image component?

$
0
0
This screenshot is from the Unity Editor > Scene window, showing a white rectangle image component with a rotation and a TextMeshProUGUI child gameobject. As per the title, can anyone please advise what is the cause and fix for jagged edges on such rotated image components? Thanks.

View attachment 1388671

Weird T mark appears with TextMesPro

$
0
0
Hi folk, Please help me.
Some weird T shaped mark appears on the top of the TextMeshPro - Text (UI).
It is even being displayed on a game scene and it only disappears when I hide it by clicking eye looking icon of the TextMeshPro
How can I remove this mark? I have attached an image for better understanding.
Thank you in advance.

[2023.2] Latest Development on TextMesh Pro

$
0
0
[2023.2] Latest Development on TextMesh Pro

As of 2023.2, the TextMesh Pro package (com.unity.textmeshpro) has been merged into the uGUI package (com.unity.ugui) and the TextMesh Pro package has been deprecated. Many have asked about the verification of TextMeshPro 3.2.0-pre.4, and we confirm that it is the version we used for the migration. Note that there won't be an official verification for this version as it will now be part of the core product, and...

[2023.2] Latest Development on TextMesh Pro

TextMesh Pro UGUI hidden characters?

$
0
0
I noticed the content pulled from a seemingly empty TMP UGUI Text object was not hitting my string.IsNullOrEmpty conditional. When I printed it to Debug it was empty, but when I got the length of it, it was 1. Is there a hidden character (new line, tab, space) that is automatically given to all TMP Text objects?

Unity doesn't use the version of .NET that includes string.IsNullOrWhitespace, so a text object not being equal to empty when you think it should creates unnecessary calls to Trim().

Shake Text Dont Work When Text Is Bold - Text Mesh Pro

$
0
0
Hey guys, I have a script that makes my text vertices shake, and when I make the text bold the shake effect just stops.

Here is the code I am using to make my text shake:

Code (CSharp):
  1. if (Dialogs[index].isToShake)
  2.         {
  3.             dialogText.ForceMeshUpdate();
  4.             mesh = dialogText.mesh;
  5.             vertices = mesh.vertices;
  6.            
  7.             for (int i = 0; i < dialogText.textInfo.characterCount; i++)
  8.             {
  9.                 TMP_CharacterInfo c =...
Shake Text Dont Work When Text Is Bold - Text Mesh Pro

Char-by-char printing troubles

$
0
0
Hey folks. My game's tutorial has some dialogue boxes that type out character-by-character, as in many games. I'm not great at dealing with UI stuff, so this has been a challenge. I've tried using Chat GPT to help, but it repeatedly makes mistakes that I don't know how to deal with. I'm really hoping somebody here can help me out.

The first problem is probably the simplest: I want the TypeLine method to make sure that there is enough space on the current line before attempting to print a...

Char-by-char printing troubles

How to prevent TextMeshPro vertex modifications from being reset by maxVisibleCharacter?

$
0
0
I wrote a coroutine that implements a typewriter function by incrementing maxVisibleCharacter every certain amount of time. In addition, I also implemented the effect of modifying the vertex color32 in another coroutine. These coroutines are usually called sequentially in a function using StartCoroutine.

But I found that after changing maxVisibleCharacter in the typewriter function, TextMeshPro would reset all vertex modifications at some point. This sometimes caused other coroutines that...

How to prevent TextMeshPro vertex modifications from being reset by maxVisibleCharacter?

big problem with lacking materialpropertyblock for ui image

$
0
0
Hi all. I need to use materialpropertyblock for UI images. How can I handle it?
I have a lot of UI square images that have different properties (Color property for example or another one). Thanks

The variable m_AtlasTextures of TMP_FontAsset doesn't exist anymore

$
0
0
I'm using a few dynamic fonts for Japanese, Chinese, Korean. They're set up as fallback fonts to my standard/non-Asian font. Sometimes, but not always, I get this error flooding my console. Here's the full call stack:

MissingReferenceException: The variable m_AtlasTextures of TMP_FontAsset doesn't exist anymore.
You probably need to reassign the m_AtlasTextures variable of the 'TMP_FontAsset' script in the inspector.
TMPro.TMP_FontAsset.TryAddCharacterInternal (System.UInt32 unicode,...

The variable m_AtlasTextures of TMP_FontAsset doesn't exist anymore

TextMeshPro UI text auto realigning after adding a character of a bigger font in char by char typing

$
0
0
I have a slight problem with my printing char by char to a TextMeshPro Text (UI) field. Everything works great except when I try to use the rich text editor feature <font=x> to make my text a bigger size (showcased by the red text in the side by size of the same text field before and after text of a bigger font is added). When I add the first character of a bigger size my text auto-resizes itself to align the top of the biggest font to the top of the TMP text box, which causes the smaller...

TextMeshPro UI text auto realigning after adding a character of a bigger font in char by char typing

Setting TMP Fallback Font failed to Refresh showing text in Unity 2023 and Unity6000 0b12

$
0
0
Hello everyone,

It seems that adjusting the order of Fallback Fonts via code does not refresh the font.
Even after adjusting and then searching for all TMP Text objects and calling
Code (CSharp):
  1. tmpText.ForceMeshUpdate(true);//this worked in 2022
, the font fails to refresh. Strangely enough, font refresh only seems to occur when manually adjusting the order in the Inspector.

I have tried similar methods, such as using
Code (CSharp):
  1. TMPro_EventManager.ON_FONT_PROPERTY_CHANGED(true,...
Setting TMP Fallback Font failed to Refresh showing text in Unity 2023 and Unity6000 0b12

ScrollRect Scroll Sensitivity become very slow in Unity 2023 and Unity6000

$
0
0
Hello everyone,

I've recently encountered an issue with the scroll sensitivity of ScrollRect in Unity 2023 and Unity6000. In the 2022 version, setting it to 129 allowed my inventory to scroll a whole page, but in 2023 and 6000, it only moves a few pixels at a time. I'm wondering how to revert back to the previous behavior or, if that's not possible, how to correctly calculate the new value.

Has anyone else faced a similar issue? Are there any effective alternative solutions or the correct...

ScrollRect Scroll Sensitivity become very slow in Unity 2023 and Unity6000

Is it okay to use the animator component on a UI object?

$
0
0
In my scene I have a dialogue box that pops up, I want to have an animated face of the character speaking within the dialogue box - similar to how Banjo Kazooie does it (
)

Usually I animate UI using the LeanTween library, as I'm aware you don't usually use an animator on a UI object, but that's for more animating UI movement.

How else would I go about having a frame by frame animation in a UI object? Could I instead have a regular Game Object within a UI...

Is it okay to use the animator component on a UI object?

Camera.Render() seems to trigger Canvas.SendWillRenderCanvases()

$
0
0
Hey there. I've got a background camera rendering out some meshes to a RenderTexture. There is also a complex uGUI doing stuff with the user. Both of these have to run in parallel. I've found through profiling that calling a Camera.Render() on this background camera triggers Canvas.SendWillRenderCanvases() on the rest of the UI.


What in tarnation! The background camera is set to have an empty event mask, and a culling mask of only one layer where...

Camera.Render() seems to trigger Canvas.SendWillRenderCanvases()

Help, when I change the Dilate in Text, it adds a black background!

$
0
0
Adjust the parameters of the outline of the font material for the letters to be displayed using Text Mesh Pro.
And also change the Dilate of the Face of the material so that the letters will not be too thin.

However, if the outline and Dilate values are changed and the font size is smaller, the text will have a black, garbage-like background.
See the following image.
View attachment 1366370
This is not shown in scene view, but in game view.
And it shows up when you run the build. I...

Help, when I change the Dilate in Text, it adds a black background!

Can't see anchors on UI?

$
0
0
I'd like to play around with anchors but I've noticed that they're not visible! I recall I was once able to see them, does anyone know what I should do to be able to see them again?

TMP_InputField's scrollbar doesn't update when changing text programmatically

$
0
0
I have a TMP_InputField with a vertical scrollbar and when I change the text programmatically (setting the InputField's text property) the position or size of the scrollbar doesn't update. I've tried several different things with no luck, such as
  • Rebuilding the layout
  • ForceMeshUpdate on the textComponent
  • ForceLabelUpdate
  • TMPro_EventManager.ON_TEXT_CHANGED

What is the best approach/practise for a tablet and phone responsive design?

$
0
0
Hi,

I need to make an App that can be use on tablets and on phones. So i have to deal with two kinds of designs of the layout of the app; one for tablets and one for phones.

Does someone has some tips, article links or movie instructions about what is the best approach to realize two UI styles in one app?

Thanks in advance!

Greetings,

Mark
Viewing all 23263 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>