White Border around scrollers on Runtime with the UI-Builder

Hello,

im facing some issues with the UI-Toolkit. Inside the UI-Builder everything works fine. As soon as i go into runtime is see white borders around scrollers, buttons and Textfields. I already tried to fix it by changing my panel-settings, but that didn`t work. I don´t know where to look for a fix.
Any help i welcome.

Could you mark what’s not as expected respectively post a side-by-side screenshot? I can’t see any white lines in the screenshot, unless you mean the light gray that’s the same color as the “Label” backgrounds.

To further investigate we’d also need to see the UI Builder settings respectively the USS. This might be a styling issue but no idea why it would differ at runtime, unless runtime uses a different style or adds/removes styles by script.

Hello! If you enter preview mode in the builder (there’s a button at the top right corner of the viewport), and interact with your UI, do you see the white borders pop up? It could be pseudo state styling (if the element is focused, hovered, etc) you can unset those styles by creating selectors like .unity-label:hover and setting the border color there.


I hope its better Visible with this screenshot. Its about the light grey border around the Scrollbar. You can see it in the Build and not in the UI-Builder.

i don´t see the borders pop up when i enter preview mode, but when i click on the dropdown next to the preview button and select “unity default runtime theme” the border around the scrollview pops up. Do i have to edit the the unity default runtime theme and if yes what exactly do i have to change?

Thanks for your help

I don’t know what to change, if anything. I’d suggest to create an empty UI Builder document with just enough to see a scrollbar, and then check if the same issue appears there. You may also want to take that test into a new, empty project to ensure nothing else interferes.

Perhaps some styling got overridden in your document, or the runtime in the project is not using the same theme as the editor.

Yes, i think the problem is, that during runtime the “unity default runtime theme” is used. Is there a way to use the active editor theme during runtime?