|
|
On 27 Apr 2021, at 14:44, Ian MacArthur wrote:
>
> 3: Derive your own button class and add a (static) method that allows the style to be changed "globally" on the fly. Now, I've done this in the past, but don't really recall the details. ISTR that I had to tweak the draw() method of the derived class to check the "global" style for each redraw(), such that setting the "global" flag and calling redraw() on the main window had the desired effect. But... I can't find the an actual example here.
OK, still never found the original... Anyway, I set about hacking together a demo., but ran out of steam. It is more complicated than it needs to be because I *was* going to add all manner of bells’n'whistles, but never did.
It also has a “dark” mode (cough, sorta...) because there’s been some chat about that recently.
What this “dark mode” actually illustrates is mainly how hard it is to do a decent dark mode...
See attached...
--
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/E347B228-B4DB-4F56-88B1-3D6F5747B0F8%40gmail.com.
--
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/E347B228-B4DB-4F56-88B1-3D6F5747B0F8%40gmail.com.
[ Direct Link to Message ] | |
|
| |