(04-03-2018, 07:24 AM)Jerry link Wrote: I haven't seen that option in either Yad or Zenity and I've explained in the past to [member=6629]ralphy[/member] why we will only use those (with the exception of Lite User Manager) for GUI programming. If they are in Yad or Zenity, I'd love to see a code sample.
![[Image: Screenshot_2018_04_03_14_56_42.png]](https://preview.ibb.co/eqxqsH/Screenshot_2018_04_03_14_56_42.png)
It is offered as idea for (lots of) improvement.
I used to begin from here https://www.linux.org/threads/zenity-gui...ipts.9802/
I changed the step to 1, start value to zero, end value to 1, changed --text to On Off, added an --hide-value to hide the 0,1 and number above the scale.
So it can have possible 2 values, 0 or 1 (to switch on/off value, using kb left/right arrow x1 tap in direction of wished value)
Then I just using many spaces on --text until the On/Off text fitted to the scale size, as unsure how to shrink the scale width, or to change its title bar.(edit - done)
I done it just using trial and error as not used Zenity before today.
Code without the 70+ spaces between On Off
Code:
VALUE=`zenity --scale --text="On Off" --hide-value --value="0" --min-value="0" --max-value="1" –step="1"`