Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
  • Help Room /
avatar image
0
Question by ecesis_llc · Apr 25, 2017 at 09:15 PM · textlayoutverticalchangesredraw

Change text in layout group with no redraw weirdness

I have a main vertical layout group.

Inside the that group is a UI Text and another vertical layout group (player options). The UI Text can be any size of text, from a single line to a paragraph. The player options group can have 1 or a few elements with in it.

The UI Text (yellow area below) has a content size fitter with vertical set to preferred. This does throw a warning because it is already inside a layout group.

alt text

When an player option is clicked new text replaces the yellow UI Text area. Sometimes the new text flows in find and pushes down the player options group. Other times the the text pops up and then snaps into place. I'm guessing Unity is recalculating the content fitter and while that is happening the layout goes to hell.

In the image below you can see how the text pushes out of the vertical container. A moment later the text snaps back into the correct location. I'm guessing that is how long it takes Unity to calculate the new text vertical height.

Question

Is there a way to avoid flickering text (gameobject active/inactive) or weird layout redrawing processes and maintain a decent layout?

I've tried a number of different ways to solve this issue. I've tried removing the main vertical group, removing the text content fitter (using vertical overflow) and adjusting the position of the player options based on the new text preferred size. But again it takes too long to calculate the new height and the player options either float in the next for a moment or I have to toggle its active state which then creates a "flicker" or blink of the player options.

Is there a correct way to do this? Or is it impossible without causing some type of flicker or blinking of text or player options.

alt text

dialogue-layout1.png (82.8 kB)
dialogue-layout2.png (122.1 kB)
Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Garnette · Jun 07, 2019 at 05:29 PM 0
Share

Hi @ecesis_llc , Did you figure out a solution to this? I am having the same challenge and think I've exhausted all possible solutions with no luck. Would love to know how you solved this. Thanks!

0 Replies

· Add your reply
  • Sort: 

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

103 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Why is this List only showing one int? 0 Answers

Messenger-like layout grid 0 Answers

How to keep panel inside scroll area when panel is shrunk? 0 Answers

Prevent expandable object from shrinking 1 Answer

Unity UI Prevent Layout component Update 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges