dear fltk programers:
I copy arc.cxx in test directory to fltk-1.1.10 directory
then compile it by g++ under ubuntu linux
-------
r...@eric-laptop:/home/eric/Dfltk/fltk-1.1.10# ls
ANNOUNCEMENT config.log fltk-config.in lib test
arc.cxx config.status fltk.list Makefile vc2005
borlandc configure fltk.list.in makefiles vcnet
ch12try1.cpp configure.in fltk.spec makeinclude visualc
CHANGES COPYING fltk.spec.in makeinclude.in watcom
CMake CREDITS fltk.xpm png watcom.mif
CMakeLists.txt DartConfig.cmake fluid README zlib
config.h documentation forms.h README.mac
configh.cmake.in FL install-sh README.win32
configh.in fltk-config jpeg src
r...@eric-laptop:/home/eric/Dfltk/fltk-1.1.10# g++ arc.cxx
arc.cxx:28:19: error: FL/Fl.H: No such file or directory
arc.cxx:29:33: error: FL/Fl_Double_Window.H: No such file or directory
arc.cxx:30:36: error: FL/Fl_Hor_Value_Slider.H: No such file or directory
arc.cxx:31:24: error: FL/fl_draw.H: No such file or directory
arc.cxx:36: error: expected class-name before â{â token
arc.cxx: In member function âvoid Drawing::draw()â:
arc.cxx:38: error: âxâ was not declared in this scope
arc.cxx:38: error: âyâ was not declared in this scope
arc.cxx:38: error: âwâ was not declared in this scope
arc.cxx:38: error: âhâ was not declared in this scope
arc.cxx:38: error: âfl_clipâ was not declared in this scope
arc.cxx:39: error: âFL_DARK3â was not declared in this scope
arc.cxx:39: error: âfl_colorâ was not declared in this scope
arc.cxx:40: error: âfl_rectfâ was not declared in this scope
arc.cxx:41: error: âfl_push_matrixâ was not declared in this scope
arc.cxx:43: error: âfl_translateâ was not declared in this scope
arc.cxx:44: error: âfl_rotateâ was not declared in this scope
arc.cxx:47: error: âFL_WHITEâ was not declared in this scope
arc.cxx:48: error: âfl_translateâ was not declared in this scope
arc.cxx:49: error: âfl_begin_complex_polygonâ was not declared in this scope
arc.cxx:50: error: âfl_arcâ was not declared in this scope
arc.cxx:51: error: âfl_gapâ was not declared in this scope
arc.cxx:53: error: âfl_end_complex_polygonâ was not declared in this scope
arc.cxx:54: error: âFL_REDâ was not declared in this scope
arc.cxx:55: error: âfl_begin_lineâ was not declared in this scope
arc.cxx:57: error: âfl_end_lineâ was not declared in this scope
arc.cxx:58: error: âfl_pop_matrixâ was not declared in this scope
arc.cxx:59: error: âfl_pop_clipâ was not declared in this scope
arc.cxx: In constructor âDrawing::Drawing(int, int, int, int)â:
arc.cxx:62: error: class âDrawingâ does not have any field named
âFl_Widgetâ
arc.cxx: At global scope:
arc.cxx:67: error: variable or field âslider_cbâ declared void
arc.cxx:67: error: âFl_Widgetâ was not declared in this scope
arc.cxx:67: error: âoâ was not declared in this scope
arc.cxx:67: error: expected primary-expression before âvoidâ
arc.cxx: In function âint main(int, char**)â:
arc.cxx:74: error: âFl_Double_Windowâ was not declared in this scope
arc.cxx:74: error: expected â;â before âwindowâ
arc.cxx:80: error: âFl_Sliderâ was not declared in this scope
arc.cxx:80: error: âsâ was not declared in this scope
arc.cxx:80: error: expected type-specifier before âFl_Hor_Value_Sliderâ
arc.cxx:80: error: expected â;â before âFl_Hor_Value_Sliderâ
arc.cxx:86: error: âFL_ALIGN_LEFTâ was not declared in this scope
arc.cxx:87: error: âslider_cbâ was not declared in this scope
arc.cxx:90: error: âwindowâ was not declared in this scope
arc.cxx:92: error: âFlâ has not been declared
r...@eric-laptop:/home/eric/Dfltk/fltk-1.1.10#
-----------------------------------------------------------
also did anyone know
graphic
lib (fltk) requested in Mr. Bjarne Stroustrup book-"programming--principle and
practice
using c++" 4th ed, '09. I tried to copy and run first example program
in your ch12 Display model. but my compiler g++ return a lot of error
first of all where are the include files, Simple_window.h and Graph.h?
---------
r...@eric-laptop:/home/eric/Dfltk/fltk-1.1.10# g++ ch12try1.cpp
ch12try1.cpp:1:27: error: Simple_window.h: No such file or directory
ch12try1.cpp:2:19: error: Graph.h: No such file or directory
ch12try1.cpp: In function âint main()â:
ch12try1.cpp:7: error: âGraph_libâ is not a namespace-name
ch12try1.cpp:7: error: expected namespace-name before â;â token
ch12try1.cpp:8: error: âPointâ was not declared in this scope
ch12try1.cpp:8: error: expected â;â before âtlâ
ch12try1.cpp:10: error: âSimple_windowâ was not declared in this scope
ch12try1.cpp:10: error: expected â;â before âwinâ
ch12try1.cpp:11: error: âPolygonâ was not declared in this scope
ch12try1.cpp:11: error: expected â;â before âpolyâ
ch12try1.cpp:12: error: âpolyâ was not declared in this scope
ch12try1.cpp:15: error: âColorâ has not been declared
ch12try1.cpp:17: error: âwinâ was not declared in this scope
-------
r...@eric-laptop:/home/eric/Dfltk/fltk-1.1.10# cat ch12try1.cpp
#include "Simple_window.h"
#include "Graph.h"
// get access to our window library
// get access to our 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 the display engine
}
------------------------------------------------------
plz help, Eric, [email protected]
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk