UI Toolkit/Builder feedback

Unity 2020.1.2f1, UI Builder 1.0.0-preview.3, UI Toolkit 1.0.0-preview.6

Feedback comes after making a main menu and a load game menu for in-game use, after watching the Unite video. Generally good impressions so far! It’s relatively comfortable to build UI and binding stuff seems to not be an issue.

Feedback items:

  • It’s really strange that the UI Document doesn’t render anything unless you add an “Event System (UI Toolkit)”. I get that it’s neccessary for UI buttons to work, but nothing showing up with no error messages was unexpected to say the least. I know that you get the correct setup if you create the gameobject from Create/UI Toolkit/UI Document, but I tried adding UI Document through Add Component.

  • Related, please support the new input system already! Had to revert the system to use both input systems, not too happy about that.

  • In the UI Builder Hierarchy, there doesn’t seem to be a keyboard shortcut to rename the selected element. You should use f2 for that since that’s what’s used in the normal hierarchy.

  • I keep selecting elements in the hierarchy, forgetting that I’m editing inline, editing their settings, and then having to revert that setting and open the selector.
    I’d really love it if I could right-click a property and select “apply to selector”, in the same way I can right-click a property on a MonoBehaviour and “apply to prefab”. In the same way, there should be an option to add it to each relevant selector.
    It’d also be great to have some shortcut to jump to the selected element’s selector without having to use the mouse, but to be fair I’m not sure what would be ideal in situations where there’s more selectors that apply to the element.

  • I seem to not be able to target active UI Documents in play mode with the debugger?

  • Live updating of the UI Documents when I change it in the UI builder is a bit sketchy, and doesn’t seem to always work. ctrl+s seems to both try to save the scene and the files open in the builder?

  • In the Unite talk with the tanks demo, Damian says that he’s listening to an event raised when the document is changed in order to rebind buttons, but I couldn’t find the code from that talk, nor examples for that exact feature. Is it just a general AssetDatabase callback, or is there something specifically for this in UI Toolkit?

  • The Flex buttons are kinda not the best. They’re pretty good illustrations, but I’m not a web designer, so whenever I work with UI Toolkit, I have this webpage: A Complete Guide To Flexbox | CSS-Tricks open on the other monitor. So to figure out what I want for justify-content, I go to that webpage, check the image that does the right thing, and use that. When I’m writing uss, I can just write the thing, but when using the UI builder, I have to hover my mouse over each little window to figure out which one is which.
    So for me, it’d be a lot easier if align-items, justify-content, etc. had a dropdown instead of the little images.

Are you saying it’s not rendering anything at all, even when going into playmode, or just in the Game view at edit time? If it’s “at all”, I think a fix is already in or on its way. If it’s just edit-time Game view (no playmode), this is because we don’t have a Live Reload feature working just yet, but are actively working on this feature (so changes in the UI Builder, for example, will instantly be reflected in the Game view without having to enter playmode).

We hear you. It’s coming.

The UI Builder Hierarchy is already bound to the “rename” action in the Editor. You can assign the F2 key to the “Main Menu/Edit/Rename” Command in the Shortcuts manager and it will work in the Builder. I do agree that it’s a major inconsistency that the normal Hierarchy does not use standard shortcuts from the Shortcuts Manager but instead seems to just eat a hard-coded F2. I’ll see about doing the same in the Builder.

More than agree on the right-click and “apply to selector” suggestion. Seems something relatively simple we can do to improve this workflow. Not sure yet about the shortcut key. Will need to investigate that a bit more.

The “Pick” tool is not fully functional at runtime right now, but you can manually select the runtime panel via the top-right dropdown in the Debugger. Note that it will be listed by the PanelSettings Asset name, not the UIDocument component or GameObject name.

See my reply to your first point above.

This also relates to my reply to your first point above, regarding Live Reload. In the Unite demo last year, using the now obsolete com.unity.ui.runtime package, we had a callback in the API to inform anyone of a need to “reload the UI” due to changes to either UXML or USS (like when a change was made in the Builder). This is part of the Live Reload feature I mention above. In the new com.unity.ui package, and with UIDocument, we wanted to refine this API and pattern, hence why it’s not yet in the released package. All 3: the automatic change tracking, auto-reloading, and the ability for users be notified of said changes, will come with the Live Reload feature in a future package drop. (It’s already mostly working but I can’t promise it will come in the very next package drop).

Good point. We’ll see about making this an option (like an advanced view for the Inspector). We have some plans to integrate the UI Debugger style of property editing (where you search for it and only see a list of the modified properties), which could also address this request.

Thanks for the great feedback. Happy to expand on any response above.

1 Like

At all! Empty game window in play mode. If you have a fix on the way, I won’t bother reporting it yet.

I mean, the right thing would be to not add a hard-coded thing to the builder, but instead change the hierarchy. I don’t know the amount of red tape that’s needed to make that change, though :stuck_out_tongue:

Yep, it’s actually already fixed in our master branch. Just has made it to a release yet.

Ya…that would be the proper thing to do. :slight_smile:

1 Like