I'm having a lot of trouble getting FLTK to be compliant when I try to write code in Code::Blocks. I'm guessing this is because I downloaded/installed it incorrectly. I've tried to look for installation guides like
http://hpux.connect.org.uk/hppd/hpux/Development/Tools/fltk-1.1.9/readme.html
but I don't really know what it means. I've been obtaining my source files from here.
http://www.stroustrup.com/Programming/FLTK/
What I've tried so far is downloading the zipped folder and extracting it to my C++ folder, and then setting the IDE to search for directories in the fltk folder, but that doesn't work - I think it's a bigger problem than just looking for headers.
Can anyone with experience using FLTK point me in the right direction? Here is an example of the code used to create a simple window.
#include "Simple_window.h" // get access to our windows library
#include "Graph.h" // get access to graphics library facilities
int main()
{
using namespace Graph_lib; // our graphics facilities are in Graph_lib
Point tl(100,100); // to become top left corner of window
Simple_window win(tl,600,400,"Canvas"); // make a simple window
Polygon poly; // make a shape (a polygon)
poly.add(Point(300,200)); // add a point
poly.add(Point(350,100)); // add another point
poly.add(Point(400,200)); // add a third point
poly.set_color(Color::red); // adjust properties of poly
win.attach(poly); // connect poly to the window
win.wait_for_button(); // give control to display engine
}
The headers in the program can be found here if you're interested.