Whilst playing my "C++ wrappers for xforms" game, I got bored of the additional and unnecessary compilations resulting from the fdesign generated build functions being class methods.
We did this originally to ensure that function names were unique, but the simple naming scheme below does the trick too. I also cleaned up the fdfixh.sed script a little. Apparently I know sed a bit better than when I hacked it last time! I append the resulting .h file and note that the .C file no londer #includes the FormXxx header. Note, no global callbacks, because the wrappers use signals. Ditto, the d-tors have gone because the form wrapper class takes care of that. Angus aleem@pneumon:forms-> more form_aboutlyx.h // File generated by fdesign from form_aboutlyx.fd // and modified by fdfix.sh for use by LyX. // WARNING! All changes made to this file will be lost! // Copyright 2002 the LyX Team // Read the file COPYING #ifndef FD_aboutlyx_h_ #define FD_aboutlyx_h_ #include "forms_fwd.h" struct FD_aboutlyx { FL_FORM * form; FL_OBJECT * button_close; FL_OBJECT * tabfolder; }; FD_aboutlyx * build_aboutlyx(); struct FD_aboutlyx_version { FL_FORM * form; FL_OBJECT * text_copyright; FL_OBJECT * text_version; }; FD_aboutlyx_version * build_aboutlyx_version(); struct FD_aboutlyx_credits { FL_FORM * form; FL_OBJECT * browser_credits; }; FD_aboutlyx_credits * build_aboutlyx_credits(); struct FD_aboutlyx_license { FL_FORM * form; FL_OBJECT * text_license; FL_OBJECT * text_warranty; }; FD_aboutlyx_license * build_aboutlyx_license(); #endif /* FD_aboutlyx_h_ */