> However, I should have looked at the links you provided.
> They are pretty useful.
> As far as I can see, FLTK indeed supports 2D programming.
It has a 2D drawing API that is kinda like PS, that you can use to draw into your widget.
Or you can create an Fl_GL surface and use GL to do your drawing - for complex scenes this will usually be (much) faster, and allow for anti-aliasing, compositing, etc. more readily than fltk's internal 2D API does.
I've also used Cairo to render into fltk windows (I was looking for better anti-aliasing, and trying not to use GL!) and others have used AGG similarly. I can’t comment on AGG, but for me Cairo was painfully slow and I have heard that AGG is also very slow. (They both do a Very Nice Job though.)
So if you need to render a complex scene with fancy blending, use GL.
If it is just a 2D API you need, try the fltk API.
Others have passed this way before (chip layouts in fltk etc.) so there may be interesting stuff in the mail archives.
And I guess Greg's node graph demo might be somewhat pertinent.
http://www.seriss.com/people/erco/fltk/Fl_OpDesk/
On 10.11.2014 15:29 A.J. Bonnema wrote:
The GUI should work across platforms w/o platform specific code. That's
what FLTK is designed for.
A good start for looking at examples and tutorials is always "Erco's
FLTK Cheat Page". There you can also find some video tutorials.
http://seriss.com/people/erco/fltk/
You may want to do a test installation of FLTK 1.3.3, the latest
release, as of Nov 3, 2014. There is a lot of working test and example
code in the directories 'test' and 'examples'.
On 2014-11-10 12:52 PM, "A.J. Bonnema" wrote:
>
> I do have a C++ newbie question though: why do the header files have uppercase H as suffix in stead of lowercase h? Why do the file name have uppercase at all? The FAQ doesn't show this query so I am probably the only one wondering about it.
Traditionally uppercase H files are used for c++ headers, although the practice seems to have faded somewhat.
As a member of the FLTK user community who has also used Wx and QT I would like to say there is much to like in FLTK. It does one thing, GUIs, and it does it well. It doesn't clutter up its code base with networking code or database code, or whatever. If you need those things, there are other places you can get them. For example I use soci for database access and boost signals2 for that observer pattern you want. I'm a fan of boost. It does many things, all cross platform. Everything I do is cross platform without any platform specific code on my part. What's not to like about that.
One of the great things about FLTK though is if you run into a problem the group is a great resource. I see that it took about two hours for one of the devs to answer your original question. That's not unusual.
That's not to say the other toolkits you mention don't have their good points. I learnt the observer pattern through Qt's signals and slots and built my first MVC project using Wx. Neither of those are included in FLTK. Still if I understand what your application is, FLTK is definitely worth a close look.