4 ms·
The main issue with toggle buttons is that you have an object that at the same contain the state of the system and the action to change it. The consequence is
by mrighele 3y ago
The main issue with toggle buttons is that you have an object that at the same contain the state of the system and the action to change it.
The consequence is that it is not clear if the "ON" that you see on it is the current state (so pressing on it will turn it to "OFF"), or the action that you will invoke when you press it.
The solution is to separate (part of) state and action, and this can be done in a few ways. One possibility is to do like one of the answers in the link suggests, and write the label _outside_ the button. If you don't have a switch but a toggle button (like the teams example in some other comment), leave the icon alone, and change some other properties of the button (for example leaving it pressed to signal the "ON" state, like it has been done for decades without any issue....)
- vleaflet 3y agoSystem sound properties in Windows 11 has an option "Allow apps and Windows to use this device for audio" and a button labeled "Don't allow" next to it. So what is the current state? I have no idea.