# Button Disabled Background Color

**URL:** <https://forum.inductiveautomation.com/t/button-disabled-background-color/104292>\
**Category:** Ignition\
**Tags:** vision\
**Created:** [March 27, 2025, 8:35am UTC](https://forum.inductiveautomation.com/t/button-disabled-background-color/104292 "2025-03-27T08:35:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![drey](https://avatars.discourse-cdn.com/v4/letter/d/858c86/32.png) [@drey](https://forum.inductiveautomation.com/u/drey)\
**Post date:** [March 27, 2025, 8:35am UTC](https://forum.inductiveautomation.com/t/button-disabled-background-color/104292/1 "2025-03-27T08:35:07Z")

</div>

I'm having Button component in Vision window. When I disable the buttons, it turns greyish color. How do I edit its background? I want the background to remain the same.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 27, 2025, 12:15pm UTC](https://forum.inductiveautomation.com/t/button-disabled-background-color/104292/2 "2025-03-27T12:15:38Z")

</div>

> [@drey](#):
>
> I want the background to remain the same.

That's a really bad idea, and not necessarily possible with the Swing Look and Feel layer Ignition uses. Why do you want this?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [March 27, 2025, 2:29pm UTC](https://forum.inductiveautomation.com/t/button-disabled-background-color/104292/3 "2025-03-27T14:29:26Z")

</div>

While I agree with Phil in general, in the spirit of answering the question posed, you _may_ get a more accurate color representation when disabled using a different blend mode; look at this thread for more details:

> [@Upgrade version makes buttons dissapear (possible bug?)](https://forum.inductiveautomation.com/t/upgrade-version-makes-buttons-dissapear-possible-bug/54921/10):
>
> Okay, let’s make sure I have things correct. By my count, there’s three problems you’re describing in this thread. Upon upgrade, some of your buttons disappear outright. I think I understand what’s gone wrong. There’s an issue in the LaF with the borderPainted property (causing the button to become invisible) so we removed the property entirely. However, older windows could still have a change from the default value serialized, so you end up with your issue - invisible buttons. We’ll see if…

I say _may_ because I haven't ever tested this with a disabled button...because as Phil said, non-standard styling for disabled components tends to confuse end users.

---

<div class="post-metadata">

**Author:** ![justinedwards.jle](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/justinedwards.jle/32/37854_2.png) [@justinedwards.jle](https://forum.inductiveautomation.com/u/justinedwards.jle)\
**Post date:** [March 31, 2025, 6:44am UTC](https://forum.inductiveautomation.com/t/button-disabled-background-color/104292/4 "2025-03-31T06:44:15Z")

</div>

As a general rule, I avoid hacking the look and feel because when unexpected behaviors occur as a result, they are difficult to troubleshoot. If I had a requirement like this, I would probably leave the enabled property set to true and qualify the `actionPerformed` event handler of the button with a simple `if` statement, so the button doesn't take action if the required conditions aren't met.

That said, if there's no clear indicator to show that the button can't perform its action, I imagine it will become a point of frustration for the user.
