[fltk.general] How do you disable a button?

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.general  ]
 
Previous Message ]New Message | Reply ]Next Message ]

How do you disable a button? "'Mark' via fltk.general" 03:38 Jan 13 top right image
 
I have a "history" menubutton that I want to enable when the menu has items and disable when it doesn't. It will start out with no entries and gradually they'll be added depending on what the user does. Similarly, I have other buttons which should be enabled/disabled depending on context.

I've tried setting the trigger to none but that didn't do it. I also tried calling deactivate but that didn't stop clicking it from working.

Searching for 'enable' and 'disable' in the docs didn't help.

So maybe fltk has a way of doing this using terminology/functions I'm unfamiliar with? (I'm pretty new to fltk; I'm much more familiar with Tk, Qt, and wxWidgets.)

--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkgeneral/7b3d977e-598e-4f74-a138-528cf4337fffn%40googlegroups.com.
Direct Link to Message ]
 
bottom left image   bottom right image
Previous Message ]New Message | Reply ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2022 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.