How do I set “StyleBoxEmpty” on buttons in Godot?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By behelit

I’m trying to remove the blue box that appears around focused buttons in Godot. I saw here that it can be done with “StyleBoxEmpty”, but the example picture is a broken link. I have looked through all the node properties, but I cannot find it. Can someone clarify how to enable this property?

:bust_in_silhouette: Reply From: behelit

Okay, I figured it out…

To remove the unwanted blue “style box” border around focused buttons, do the following:

  1. In the inspector for the button node, scroll down until you find “Custom Styles”, expand.
  2. Under the focus property, set the null value to StyleBoxEmpty.
  3. Done.

I feel like this was harder to find than it should have been, the documentation simply says “Empty stylebox (does not display anything).”.

Registered here only to say thank you!
For Godot 3.2.3:
Custom Styles - check Focus - choose StyleBoxEmpty
It is not property of Hover, Pressed, etc. It is just one of the button states that needs to be configured.

Divergence19 | 2020-11-29 20:06

The answer is perfect, I just want to add a screenshot:

enter image description here

Above solution also works for CheckButton.

AllanWindmill | 2021-01-25 01:14

1 Like