Separate the extra image functions into fltk_images.
Add new fl_register_images() function to register the extra file formats with Fl_Shared_Image. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2329 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
96094e5617
commit
6a6e4ab66c
4
CHANGES
4
CHANGES
@ -1,5 +1,9 @@
|
||||
CHANGES IN FLTK 1.1.0
|
||||
|
||||
- The JPEG and PNG image classes have been moved to the
|
||||
fltk_images library, a la FLTK 2.0. You can register
|
||||
all image file formats provided in fltk_images using
|
||||
the new fl_register_images() function.
|
||||
- Fl_XBM_Image didn't correctly load XBM files.
|
||||
- MacOS: Added Greg Ercolano's file descriptor support.
|
||||
- MacOS: Fixed text width bug.
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_Shared_Image.H,v 1.22.2.4 2002/05/25 13:38:24 easysw Exp $"
|
||||
// "$Id: Fl_Shared_Image.H,v 1.22.2.5 2002/06/28 21:04:35 easysw Exp $"
|
||||
//
|
||||
// Shared image header file for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -34,7 +34,7 @@ typedef Fl_Image *(*Fl_Shared_Handler)(const char *name, uchar *header,
|
||||
int headerlen);
|
||||
|
||||
// Shared images class.
|
||||
class Fl_Shared_Image : public Fl_Image {
|
||||
class FL_EXPORT Fl_Shared_Image : public Fl_Image {
|
||||
protected:
|
||||
|
||||
static Fl_Shared_Image **images_; // Shared images
|
||||
@ -81,8 +81,16 @@ class Fl_Shared_Image : public Fl_Image {
|
||||
static void remove_handler(Fl_Shared_Handler f);
|
||||
};
|
||||
|
||||
//
|
||||
// The following function is provided in the fltk_images library and
|
||||
// registers all of the "extra" image file formats that are not part
|
||||
// of the core FLTK library...
|
||||
//
|
||||
|
||||
FL_EXPORT void fl_register_images();
|
||||
|
||||
#endif // !Fl_Shared_Image_H
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_Shared_Image.H,v 1.22.2.4 2002/05/25 13:38:24 easysw Exp $"
|
||||
// End of "$Id: Fl_Shared_Image.H,v 1.22.2.5 2002/06/28 21:04:35 easysw Exp $"
|
||||
//
|
||||
|
18
configure.in
18
configure.in
@ -1,7 +1,7 @@
|
||||
dnl -*- sh -*-
|
||||
dnl the "configure" script is made from this by running GNU "autoconf"
|
||||
dnl
|
||||
dnl "$Id: configure.in,v 1.33.2.31.2.75 2002/06/26 12:03:27 easysw Exp $"
|
||||
dnl "$Id: configure.in,v 1.33.2.31.2.76 2002/06/28 21:04:35 easysw Exp $"
|
||||
dnl
|
||||
dnl Configuration script for the Fast Light Tool Kit (FLTK).
|
||||
dnl
|
||||
@ -79,18 +79,22 @@ esac
|
||||
dnl Define the libraries and link options we'll need.
|
||||
LINKFLTK="-lfltk"
|
||||
LINKFLTKGL="-lfltk_gl"
|
||||
LINKFLTKIMG="-lfltk_images"
|
||||
GLDEMOS="gldemos"
|
||||
|
||||
LIBNAME="../lib/libfltk.a"
|
||||
FLLIBNAME="../lib/libfltk_forms.a"
|
||||
GLLIBNAME="../lib/libfltk_gl.a"
|
||||
IMGLIBNAME="../lib/libfltk_images.a"
|
||||
|
||||
AC_SUBST(FLLIBNAME)
|
||||
AC_SUBST(GLDEMOS)
|
||||
AC_SUBST(GLLIBNAME)
|
||||
AC_SUBST(IMGLIBNAME)
|
||||
AC_SUBST(LIBNAME)
|
||||
AC_SUBST(LINKFLTK)
|
||||
AC_SUBST(LINKFLTKGL)
|
||||
AC_SUBST(LINKFLTKIMG)
|
||||
|
||||
dnl Handle compile-time options...
|
||||
AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]])
|
||||
@ -110,6 +114,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.$FL_API_VERSION.dylib"
|
||||
FLDSONAME="libfltk_forms.$FL_API_VERSION.dylib"
|
||||
GLDSONAME="libfltk_gl.$FL_API_VERSION.dylib"
|
||||
IMGDSONAME="libfltk_images.$FL_API_VERSION.dylib"
|
||||
DSOCOMMAND="ld $DSOFLAGS -dylib /usr/lib/dylib1.o -lc"
|
||||
if test "$libdir" != "/usr/lib"; then
|
||||
DSOLINK="-Wl,-rpath,$libdir"
|
||||
@ -120,6 +125,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.so.$FL_API_VERSION"
|
||||
FLDSONAME="libfltk_forms.so.$FL_API_VERSION"
|
||||
GLDSONAME="libfltk_gl.so.$FL_API_VERSION"
|
||||
IMGDSONAME="libfltk_images.so.$FL_API_VERSION"
|
||||
DSOCOMMAND="\$(CXX) -h \$@ \$(LDLIBS) -G $DEBUGFLAG -o"
|
||||
if test "$libdir" != "/usr/lib"; then
|
||||
DSOLINK="-R$libdir"
|
||||
@ -129,6 +135,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.sl.$FL_API_VERSION"
|
||||
FLDSONAME="libfltk_forms.sl.$FL_API_VERSION"
|
||||
GLDSONAME="libfltk_gl.sl.$FL_API_VERSION"
|
||||
IMGDSONAME="libfltk_images.sl.$FL_API_VERSION"
|
||||
DSOCOMMAND="ld -b -z +h \$@ $DEBUGFLAG -o"
|
||||
if test "$libdir" != "/usr/lib"; then
|
||||
DSOLINK="-Wl,-rpath,$libdir"
|
||||
@ -138,6 +145,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.so.$FL_API_VERSION"
|
||||
FLDSONAME="libfltk_forms.so.$FL_API_VERSION"
|
||||
GLDSONAME="libfltk_gl.so.$FL_API_VERSION"
|
||||
IMGDSONAME="libfltk_images.so.$FL_API_VERSION"
|
||||
DSOCOMMAND="\$(CXX) -Wl,-soname,\$@,-set_version,sgi1.1 \$(LDLIBS) -shared $DEBUGFLAG -o"
|
||||
if test "$libdir" != "/usr/lib" - a "$libdir" != "/usr/lib32"; then
|
||||
DSOLINK="-Wl,-rpath,$libdir"
|
||||
@ -147,6 +155,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.so.$FL_API_VERSION"
|
||||
FLDSONAME="libfltk_forms.so.$FL_API_VERSION"
|
||||
GLDSONAME="libfltk_gl.so.$FL_API_VERSION"
|
||||
IMGDSONAME="libfltk_images.so.$FL_API_VERSION"
|
||||
DSOCOMMAND="\$(CXX) -Wl,-soname,\$@ \$(LDLIBS) -shared $DEBUGFLAG -o"
|
||||
if test "$libdir" != "/usr/lib" - a "$libdir" != "/usr/lib32"; then
|
||||
DSOLINK="-Wl,-rpath,$libdir"
|
||||
@ -156,6 +165,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.so.$FL_API_VERSION"
|
||||
FLDSONAME="libfltk_forms.so.$FL_API_VERSION"
|
||||
GLDSONAME="libfltk_gl.so.$FL_API_VERSION"
|
||||
IMGDSONAME="libfltk_images.so.$FL_API_VERSION"
|
||||
DSOCOMMAND="\$(CXX) -Wl,-soname,\$@ \$(LDLIBS) -shared -fPIC $DEBUGFLAG -o"
|
||||
if test "$libdir" != "/usr/lib"; then
|
||||
DSOLINK="-Wl,-rpath,$libdir"
|
||||
@ -165,6 +175,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk_s.a"
|
||||
FLDSONAME="libfltk_forms_s.a"
|
||||
GLDSONAME="libfltk_gl_s.a"
|
||||
IMGDSONAME="libfltk_images_s.a"
|
||||
DSOCOMMAND="\$(CXX) -Wl,-bexpall,-bM:SRE,-bnoentry -o"
|
||||
;;
|
||||
CYGWIN*)
|
||||
@ -175,6 +186,7 @@ if test x$enable_shared = xyes; then
|
||||
DSONAME="libfltk.so.$FL_API_VERSION"
|
||||
FLDSONAME="libfltk_forms.so.$FL_API_VERSION"
|
||||
GLDSONAME="libfltk_gl.so.$FL_API_VERSION"
|
||||
IMGDSONAME="libfltk_images.so.$FL_API_VERSION"
|
||||
DSOCOMMAND="\$(CXX) -Wl,-soname,\$@ \$(LDLIBS) -shared $DEBUGFLAG -o"
|
||||
;;
|
||||
esac
|
||||
@ -184,6 +196,7 @@ else
|
||||
DSONAME=""
|
||||
FLDSONAME=""
|
||||
GLDSONAME=""
|
||||
IMGDSONAME=""
|
||||
PICFLAG=0
|
||||
fi
|
||||
|
||||
@ -192,6 +205,7 @@ AC_SUBST(DSOLINK)
|
||||
AC_SUBST(DSONAME)
|
||||
AC_SUBST(FLDSONAME)
|
||||
AC_SUBST(GLDSONAME)
|
||||
AC_SUBST(IMGDSONAME)
|
||||
|
||||
AC_ARG_ENABLE(threads, [ --enable-threads enable multi-threading support])
|
||||
|
||||
@ -752,5 +766,5 @@ dnl Make sure the fltk-config script is executable...
|
||||
chmod +x fltk-config
|
||||
|
||||
dnl
|
||||
dnl End of "$Id: configure.in,v 1.33.2.31.2.75 2002/06/26 12:03:27 easysw Exp $".
|
||||
dnl End of "$Id: configure.in,v 1.33.2.31.2.76 2002/06/28 21:04:35 easysw Exp $".
|
||||
dnl
|
||||
|
@ -35,6 +35,7 @@ A</A>.
|
||||
<LI><A HREF="#fl_message_font"><TT>fl_message_font</TT></A></LI>
|
||||
<LI><A HREF="#fl_message_icon"><TT>fl_message_icon</TT></A></LI>
|
||||
<LI><A HREF="#fl_password"><TT>fl_password</TT></A></LI>
|
||||
<LI><A HREF="#fl_register_images"><TT>fl_register_images</TT></A></LI>
|
||||
<LI><A HREF="#fl_rgb_color"><TT>fl_rgb_color</TT></A></LI>
|
||||
<LI><A HREF="#fl_show_colormap"><TT>fl_show_colormap</TT></A></LI>
|
||||
|
||||
@ -87,40 +88,14 @@ A</A>.
|
||||
</UL>
|
||||
</LI>
|
||||
|
||||
<LI>Image Functions
|
||||
<UL>
|
||||
<LI><A HREF="#fl_register_images"><TT>fl_register_images</TT></A></LI>
|
||||
</UL>
|
||||
</LI>
|
||||
</UL>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- NEED 4in -->
|
||||
<H2><A NAME="fl_alert">fl_alert</A></H2>
|
||||
|
||||
@ -930,6 +905,31 @@ href=Fl_Secret_Input.html><tt>Fl_Secret_Input</tt></A> field is
|
||||
used.
|
||||
|
||||
|
||||
<!-- NEED 4in -->
|
||||
<H2><A NAME="fl_register_images">fl_register_images</A></H2>
|
||||
|
||||
<HR>
|
||||
|
||||
<H3>Include File</H3>
|
||||
|
||||
<UL><PRE>
|
||||
#include <FL/Fl_Shared_Image.H>
|
||||
</PRE></UL>
|
||||
|
||||
<H3>Prototype</H3>
|
||||
|
||||
<UL><PRE>
|
||||
void fl_register_images();
|
||||
</PRE></UL>
|
||||
|
||||
<H3>Description</H3>
|
||||
|
||||
<P>Registers the extra image file formats that are not provided
|
||||
as part of the core FLTK library for use with the <A
|
||||
HREF="Fl_Shared_Image.html#Fl_Shared_Image"><CODE>Fl_Shared_Image</CODE></A>
|
||||
class.
|
||||
|
||||
|
||||
<!-- NEED 4in -->
|
||||
<H2><A NAME="fl_rgb_color">fl_rgb_color</A></H2>
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# "$Id: fltk-config.in,v 1.12.2.11 2002/04/26 12:45:16 easysw Exp $"
|
||||
# "$Id: fltk-config.in,v 1.12.2.12 2002/06/28 21:04:35 easysw Exp $"
|
||||
#
|
||||
# FLTK configuration utility.
|
||||
#
|
||||
@ -213,8 +213,8 @@ if test x$use_gl = xyes; then
|
||||
LIBS="$LIBS $libdir/libfltk_gl.a"
|
||||
fi
|
||||
if test x$use_images = xyes; then
|
||||
LDLIBS="$LDLIBS $IMAGELIBS"
|
||||
LDSTATIC="$LDSTATIC $IMAGELIBS"
|
||||
LDLIBS="-lfltk_images $IMAGELIBS $LDLIBS"
|
||||
LDSTATIC="$libdir/libfltk_images.a $IMAGELIBS $LDSTATIC"
|
||||
fi
|
||||
|
||||
LDLIBS="$DSOLINK $LDLIBS -lm"
|
||||
@ -297,5 +297,5 @@ if test "$echo_libs" = "yes"; then
|
||||
fi
|
||||
|
||||
#
|
||||
# End of "$Id: fltk-config.in,v 1.12.2.11 2002/04/26 12:45:16 easysw Exp $".
|
||||
# End of "$Id: fltk-config.in,v 1.12.2.12 2002/06/28 21:04:35 easysw Exp $".
|
||||
#
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# "$Id: Makefile,v 1.10.2.6.2.19 2002/05/01 19:35:53 easysw Exp $"
|
||||
# "$Id: Makefile,v 1.10.2.6.2.20 2002/06/28 21:04:36 easysw Exp $"
|
||||
#
|
||||
# FLUID makefile for the Fast Light Tool Kit (FLTK).
|
||||
#
|
||||
@ -54,7 +54,7 @@ include ../makeinclude
|
||||
$(PROGRAM) : $(OBJECTS) ../lib/$(LIBNAME)
|
||||
echo Linking $@...
|
||||
$(CXX) $(CXXFLAGS) -o $(PROGRAM) $(OBJECTS) $(LINKFLTKFORMS) \
|
||||
$(IMAGELIBS) $(LDLIBS)
|
||||
-lfltk_images $(IMAGELIBS) $(LDLIBS)
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
|
||||
clean :
|
||||
@ -89,5 +89,5 @@ rebuild:
|
||||
./fluid -c widget_panel.fl
|
||||
|
||||
#
|
||||
# End of "$Id: Makefile,v 1.10.2.6.2.19 2002/05/01 19:35:53 easysw Exp $".
|
||||
# End of "$Id: Makefile,v 1.10.2.6.2.20 2002/06/28 21:04:36 easysw Exp $".
|
||||
#
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: fluid.cxx,v 1.15.2.13.2.27 2002/06/07 15:06:32 easysw Exp $"
|
||||
// "$Id: fluid.cxx,v 1.15.2.13.2.28 2002/06/28 21:04:36 easysw Exp $"
|
||||
//
|
||||
// FLUID main entry for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -760,6 +760,7 @@ int main(int argc,char **argv) {
|
||||
return 1;
|
||||
}
|
||||
const char *c = argv[i];
|
||||
fl_register_images();
|
||||
make_main_window();
|
||||
if (c) set_filename(c);
|
||||
if (!compile_only) {
|
||||
@ -795,5 +796,5 @@ int main(int argc,char **argv) {
|
||||
}
|
||||
|
||||
//
|
||||
// End of "$Id: fluid.cxx,v 1.15.2.13.2.27 2002/06/07 15:06:32 easysw Exp $".
|
||||
// End of "$Id: fluid.cxx,v 1.15.2.13.2.28 2002/06/28 21:04:36 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# "$Id: makeinclude.in,v 1.7.2.11.2.18 2002/03/25 21:39:01 easysw Exp $"
|
||||
# "$Id: makeinclude.in,v 1.7.2.11.2.19 2002/06/28 21:04:35 easysw Exp $"
|
||||
#
|
||||
# Make include file for the Fast Light Tool Kit (FLTK).
|
||||
# @configure_input@
|
||||
@ -53,11 +53,13 @@ CXXFLAGS =$(OPTIM) @CXXFLAGS@
|
||||
LIBNAME =@LIBNAME@
|
||||
FLLIBNAME =@FLLIBNAME@
|
||||
GLLIBNAME =@GLLIBNAME@
|
||||
IMGLIBNAME =@IMGLIBNAME@
|
||||
LIBCOMMAND =@LIBCOMMAND@
|
||||
RANLIB =@RANLIB@
|
||||
DSONAME =@DSONAME@
|
||||
FLDSONAME =@FLDSONAME@
|
||||
GLDSONAME =@GLDSONAME@
|
||||
IMGDSONAME =@IMGDSONAME@
|
||||
DSOCOMMAND =@DSOCOMMAND@
|
||||
|
||||
# libraries to link with:
|
||||
@ -66,6 +68,7 @@ GLDLIBS =@LDFLAGS@ @GLLIB@ @LIBS@ $(LDFLAGS_MIPSPRO)
|
||||
LINKFLTK =-L../lib @LINKFLTK@
|
||||
LINKFLTKGL =-L../lib @LINKFLTKGL@
|
||||
LINKFLTKFORMS =-L../lib -lfltk_forms @LINKFLTK@
|
||||
LINKFLTKIMG =-L../lib -lfltk_images @LINKFLTK@ $(IMAGELIBS)
|
||||
IMAGELIBS =@IMAGELIBS@
|
||||
|
||||
# Do we build the OpenGL demos?
|
||||
@ -116,5 +119,5 @@ CAT3EXT =@CAT3EXT@
|
||||
mv t.z $@
|
||||
|
||||
#
|
||||
# End of "$Id: makeinclude.in,v 1.7.2.11.2.18 2002/03/25 21:39:01 easysw Exp $".
|
||||
# End of "$Id: makeinclude.in,v 1.7.2.11.2.19 2002/06/28 21:04:35 easysw Exp $".
|
||||
#
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_File_Icon2.cxx,v 1.1.2.14 2002/05/10 00:18:37 easysw Exp $"
|
||||
// "$Id: Fl_File_Icon2.cxx,v 1.1.2.15 2002/06/28 21:04:36 easysw Exp $"
|
||||
//
|
||||
// Fl_File_Icon system icon routines.
|
||||
//
|
||||
@ -646,6 +646,9 @@ Fl_File_Icon::load_system_icons(void)
|
||||
// Add symbols if they haven't been added already...
|
||||
if (!init)
|
||||
{
|
||||
// This method requires the images library...
|
||||
fl_register_images();
|
||||
|
||||
if (!access("/usr/share/mimelnk", F_OK))
|
||||
{
|
||||
// Load KDE icons...
|
||||
@ -941,5 +944,5 @@ get_kde_val(char *str,
|
||||
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_File_Icon2.cxx,v 1.1.2.14 2002/05/10 00:18:37 easysw Exp $".
|
||||
// End of "$Id: Fl_File_Icon2.cxx,v 1.1.2.15 2002/06/28 21:04:36 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_Shared_Image.cxx,v 1.23.2.13 2002/06/28 15:23:03 easysw Exp $"
|
||||
// "$Id: Fl_Shared_Image.cxx,v 1.23.2.14 2002/06/28 21:04:36 easysw Exp $"
|
||||
//
|
||||
// Shared image code for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -226,11 +226,6 @@ Fl_Shared_Image::reload() {
|
||||
if (memcmp(header, "GIF87a", 6) == 0 ||
|
||||
memcmp(header, "GIF89a", 6) == 0)
|
||||
img = new Fl_GIF_Image(name_);
|
||||
else if (memcmp(header, "\211PNG", 4) == 0)
|
||||
img = new Fl_PNG_Image(name_);
|
||||
else if (memcmp(header, "\377\330\377", 3) == 0 && // Start-of-Image
|
||||
header[3] >= 0xe0 && header[3] <= 0xef) // APPn
|
||||
img = new Fl_JPEG_Image(name_);
|
||||
else if (memcmp(header, "BM", 2) == 0) // BMP file
|
||||
img = new Fl_BMP_Image(name_);
|
||||
else if (header[0] == 'P' && header[1] >= '1' && header[1] <= '6') // Portable anymap
|
||||
@ -461,5 +456,5 @@ Fl_Shared_Image::remove_handler(Fl_Shared_Handler f) {
|
||||
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_Shared_Image.cxx,v 1.23.2.13 2002/06/28 15:23:03 easysw Exp $".
|
||||
// End of "$Id: Fl_Shared_Image.cxx,v 1.23.2.14 2002/06/28 21:04:36 easysw Exp $".
|
||||
//
|
||||
|
88
src/Makefile
88
src/Makefile
@ -1,5 +1,5 @@
|
||||
#
|
||||
# "$Id: Makefile,v 1.18.2.14.2.44 2002/05/30 15:09:03 easysw Exp $"
|
||||
# "$Id: Makefile,v 1.18.2.14.2.45 2002/06/28 21:04:37 easysw Exp $"
|
||||
#
|
||||
# Library makefile for the Fast Light Tool Kit (FLTK).
|
||||
#
|
||||
@ -46,7 +46,6 @@ CPPFILES = \
|
||||
Fl_File_Chooser.cxx \
|
||||
Fl_File_Chooser2.cxx \
|
||||
Fl_File_Icon.cxx \
|
||||
Fl_File_Icon2.cxx \
|
||||
Fl_File_Input.cxx \
|
||||
Fl_GIF_Image.cxx \
|
||||
Fl_Group.cxx \
|
||||
@ -55,7 +54,6 @@ CPPFILES = \
|
||||
Fl_Image.cxx \
|
||||
Fl_Input.cxx \
|
||||
Fl_Input_.cxx \
|
||||
Fl_JPEG_Image.cxx \
|
||||
Fl_Light_Button.cxx \
|
||||
Fl_Menu.cxx \
|
||||
Fl_Menu_.cxx \
|
||||
@ -68,7 +66,6 @@ CPPFILES = \
|
||||
Fl_Overlay_Window.cxx \
|
||||
Fl_Pack.cxx \
|
||||
Fl_Pixmap.cxx \
|
||||
Fl_PNG_Image.cxx \
|
||||
Fl_PNM_Image.cxx \
|
||||
Fl_Positioner.cxx \
|
||||
Fl_Preferences.cxx \
|
||||
@ -171,6 +168,12 @@ GLCPPFILES = \
|
||||
glut_compatability.cxx \
|
||||
glut_font.cxx
|
||||
|
||||
IMGCPPFILES = \
|
||||
fl_images_core.cxx \
|
||||
Fl_File_Icon2.cxx \
|
||||
Fl_JPEG_Image.cxx \
|
||||
Fl_PNG_Image.cxx
|
||||
|
||||
CFILES = fl_call_main.c flstring.c scandir.c numericsort.c vsnprintf.c
|
||||
|
||||
CLEAN = core* cmap
|
||||
@ -182,8 +185,12 @@ include ../makeinclude
|
||||
OBJECTS = $(CPPFILES:.cxx=.o) $(CFILES:.c=.o)
|
||||
GLOBJECTS = $(GLCPPFILES:.cxx=.o)
|
||||
FLOBJECTS = $(FLCPPFILES:.cxx=.o)
|
||||
IMGOBJECTS = $(IMGCPPFILES:.cxx=.o)
|
||||
|
||||
all: $(LIBNAME) $(DSONAME) $(FLLIBNAME) $(FLDSONAME) $(GLLIBNAME) $(GLDSONAME)
|
||||
all: $(LIBNAME) $(DSONAME) \
|
||||
$(FLLIBNAME) $(FLDSONAME) \
|
||||
$(GLLIBNAME) $(GLDSONAME) \
|
||||
$(IMGLIBNAME) $(IMGDSONAME)
|
||||
|
||||
$(LIBNAME): $(OBJECTS)
|
||||
echo $(LIBCOMMAND) $@ ...
|
||||
@ -239,11 +246,30 @@ libfltk_gl_s.a: $(GLOBJECTS)
|
||||
$(LIBCOMMAND) libfltk_gl_s.a libfltk_gl_s.o
|
||||
chmod +x libfltk_gl_s.a
|
||||
|
||||
$(IMGLIBNAME): $(IMGOBJECTS)
|
||||
echo $(LIBCOMMAND) $@ ...
|
||||
-$(RM) $@
|
||||
$(LIBCOMMAND) $@ $(IMGOBJECTS)
|
||||
$(RANLIB) $@
|
||||
|
||||
libfltk_images.so.1.1 libfltk_images.sl.1.1: $(IMGOBJECTS)
|
||||
echo $(DSOCOMMAND) $@ ...
|
||||
$(DSOCOMMAND) $@ $(IMGOBJECTS)
|
||||
|
||||
libfltk_images_s.a: $(IMGOBJECTS)
|
||||
echo $(DSOCOMMAND) libfltk_images_s.o ...
|
||||
$(DSOCOMMAND) libfltk_images_s.o $(IMGOBJECTS)
|
||||
echo $(LIBCOMMAND) libfltk_images_s.a libfltk_images_s.o
|
||||
-$(RM) $@
|
||||
$(LIBCOMMAND) libfltk_images_s.a libfltk_images_s.o
|
||||
chmod +x libfltk_images_s.a
|
||||
|
||||
|
||||
clean :
|
||||
-@ rm -f *.o $(DSONAME) $(FLDSONAME) $(GLDSONAME) \
|
||||
../lib/$(LIBNAME) ../lib/$(FLLIBNAME) ../lib/$(GLLIBNAME) \
|
||||
libfltk.so libfltk_forms.so libfltk_gl.so \
|
||||
libfltk.sl libfltk_forms.sl libfltk_gl.sl \
|
||||
libfltk.so libfltk_forms.so libfltk_gl.so libfltk_images.so \
|
||||
libfltk.sl libfltk_forms.sl libfltk_gl.sl libfltk_images.sl \
|
||||
$(CLEAN)
|
||||
|
||||
depend: $(CPPFILES) $(FLCPPFILES) $(GLCPPFILES) $(CFILES)
|
||||
@ -312,16 +338,20 @@ gl_start.o: ../FL/mac.H ../FL/win32.H
|
||||
|
||||
################################################################
|
||||
|
||||
install: $(LIBNAME) $(DSONAME) $(FLLIBNAME) $(FLDSONAME) $(GLLIBNAME) $(GLDSONAME)
|
||||
install: $(LIBNAME) $(DSONAME) \
|
||||
$(FLLIBNAME) $(FLDSONAME) \
|
||||
$(GLLIBNAME) $(GLDSONAME) \
|
||||
$(IMGLIBNAME) $(IMGDSONAME)
|
||||
echo "Installing libraries in $(libdir)..."
|
||||
-mkdir -p $(libdir)
|
||||
rm -f $(libdir)/$(LIBNAME)
|
||||
-cp $(LIBNAME) $(FLLIBNAME) $(GLLIBNAME) $(libdir)
|
||||
-cp $(LIBNAME) $(FLLIBNAME) $(GLLIBNAME) $(IMGLIBNAME) $(libdir)
|
||||
$(RANLIB) $(libdir)/$(LIBNAME)
|
||||
$(RANLIB) $(libdir)/$(FLLIBNAME)
|
||||
if test x$(GLLIBNAME) != x; then \
|
||||
$(RANLIB) $(libdir)/$(GLLIBNAME); \
|
||||
fi
|
||||
$(RANLIB) $(libdir)/$(IMGLIBNAME)
|
||||
if test x$(DSONAME) = xlibfltk.so.1.1; then\
|
||||
rm -f $(libdir)/libfltk.so*;\
|
||||
cp libfltk.so.1.1 $(libdir); \
|
||||
@ -391,6 +421,29 @@ install: $(LIBNAME) $(DSONAME) $(FLLIBNAME) $(FLDSONAME) $(GLLIBNAME) $(GLDSONAM
|
||||
cp libfltk_gl_s.a $(libdir); \
|
||||
chmod 755 $(libdir)/libfltk_gl.a; \
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images.so.1.1; then\
|
||||
rm -f $(libdir)/libfltk_images.so*;\
|
||||
cp libfltk_images.so.1.1 $(libdir); \
|
||||
chmod 755 $(libdir)/libfltk_images.so.1.1; \
|
||||
ln -s libfltk_images.so.1.1 $(libdir)/libfltk_images.so;\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images.sl.1.1; then\
|
||||
rm -f $(libdir)/libfltk_images.sl*;\
|
||||
cp libfltk_images.sl.1.1 $(libdir); \
|
||||
chmod 755 $(libdir)/libfltk_images.sl.1.1; \
|
||||
ln -s libfltk_images.sl.1.1 $(libdir)/libfltk_images.sl;\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images.1.1.dylib; then\
|
||||
rm -f $(libdir)/libfltk_images.*dylib;\
|
||||
cp libfltk_images.1.1.dylib $(libdir); \
|
||||
chmod 755 $(libdir)/libfltk_images.1.1.dylib; \
|
||||
ln -s libfltk_images.1.1.dylib $(libdir)/libfltk_images.dylib;\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images_s.a; then\
|
||||
rm -f $(libdir)/libfltk_images_s.a;\
|
||||
cp libfltk_images_s.a $(libdir); \
|
||||
chmod 755 $(libdir)/libfltk_images.a; \
|
||||
fi
|
||||
|
||||
uninstall:
|
||||
echo "Uninstalling libraries..."
|
||||
@ -435,8 +488,23 @@ uninstall:
|
||||
if test x$(GLDSONAME) = xlibfltk_gl_s.a; then\
|
||||
rm -f $(libdir)/libfltk_gl_s.a;\
|
||||
fi
|
||||
if test x$(IMGLIBNAME) != x; then\
|
||||
rm -f $(libdir)/$(IMGLIBNAME);\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images.so.1.1; then\
|
||||
rm -f $(libdir)/libfltk_images.so*;\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images.sl.1.1; then\
|
||||
rm -f $(libdir)/libfltk_images.sl*;\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images.1.1.dylib; then\
|
||||
rm -f $(libdir)/libfltk_images.*dylib;\
|
||||
fi
|
||||
if test x$(IMGDSONAME) = xlibfltk_images_s.a; then\
|
||||
rm -f $(libdir)/libfltk_images_s.a;\
|
||||
fi
|
||||
|
||||
|
||||
#
|
||||
# End of "$Id: Makefile,v 1.18.2.14.2.44 2002/05/30 15:09:03 easysw Exp $".
|
||||
# End of "$Id: Makefile,v 1.18.2.14.2.45 2002/06/28 21:04:37 easysw Exp $".
|
||||
#
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# "$Id: Makefile,v 1.19.2.7.2.36 2002/06/03 12:32:57 easysw Exp $"
|
||||
# "$Id: Makefile,v 1.19.2.7.2.37 2002/06/28 21:04:37 easysw Exp $"
|
||||
#
|
||||
# Test/example program makefile for the Fast Light Tool Kit (FLTK).
|
||||
#
|
||||
@ -223,15 +223,15 @@ doublebuffer$(EXEEXT): doublebuffer.o
|
||||
|
||||
editor$(EXEEXT): editor.o
|
||||
echo Linking $@...
|
||||
$(CXX) -I.. $(CXXFLAGS) editor.o -o $@ $(LINKFLTK) $(IMAGELIBS) $(LDLIBS)
|
||||
$(CXX) -I.. $(CXXFLAGS) editor.o -o $@ $(LINKFLTKIMG) $(LDLIBS)
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
|
||||
fast_slow$(EXEEXT): fast_slow.o
|
||||
fast_slow.cxx: fast_slow.fl
|
||||
|
||||
file_chooser$(EXEEXT): file_chooser.o
|
||||
file_chooser$(EXEEXT): file_chooser.o ../lib/$(IMGLIBNAME)
|
||||
echo Linking $@...
|
||||
$(CXX) -I.. $(CXXFLAGS) file_chooser.o -o $@ $(LINKFLTK) $(IMAGELIBS) $(LDLIBS)
|
||||
$(CXX) -I.. $(CXXFLAGS) file_chooser.o -o $@ $(LINKFLTKIMG) $(LDLIBS)
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
|
||||
fonts$(EXEEXT): fonts.o
|
||||
@ -243,9 +243,9 @@ forms$(EXEEXT): forms.o
|
||||
|
||||
hello$(EXEEXT): hello.o
|
||||
|
||||
help$(EXEEXT): help.o
|
||||
help$(EXEEXT): help.o ../lib/$(LIBFLTKIMG)
|
||||
echo Linking $@...
|
||||
$(CXX) -I.. $(CXXFLAGS) help.o -o $@ $(LINKFLTK) $(IMAGELIBS) $(LDLIBS)
|
||||
$(CXX) -I.. $(CXXFLAGS) help.o -o $@ $(LINKFLTKIMG) $(LDLIBS)
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
|
||||
iconize$(EXEEXT): iconize.o
|
||||
@ -288,7 +288,7 @@ minimum$(EXEEXT): minimum.o
|
||||
|
||||
navigation$(EXEEXT): navigation.o
|
||||
|
||||
output$(EXEEXT): output.o
|
||||
output$(EXEEXT): output.o ../lib/$(FLLIBNAME)
|
||||
echo Linking $@...
|
||||
$(CXX) -I.. $(CXXFLAGS) -o $@ $< $(LINKFLTKFORMS) $(LDLIBS)
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
@ -299,9 +299,9 @@ pack$(EXEEXT): pack.o
|
||||
|
||||
pixmap$(EXEEXT): pixmap.o
|
||||
|
||||
pixmap_browser$(EXEEXT): pixmap_browser.o
|
||||
pixmap_browser$(EXEEXT): pixmap_browser.o ../lib/$(IMGLIBNAME)
|
||||
echo Linking $@...
|
||||
$(CXX) -I.. $(CXXFLAGS) pixmap_browser.o -o $@ $(LINKFLTK) $(IMAGELIBS) $(LDLIBS)
|
||||
$(CXX) -I.. $(CXXFLAGS) pixmap_browser.o -o $@ $(LINKFLTKIMG) $(LDLIBS)
|
||||
$(POSTBUILD) $@ ../FL/mac.r
|
||||
|
||||
preferences$(EXEEXT): preferences.o
|
||||
@ -381,5 +381,5 @@ shape$(EXEEXT): shape.o
|
||||
|
||||
|
||||
#
|
||||
# End of "$Id: Makefile,v 1.19.2.7.2.36 2002/06/03 12:32:57 easysw Exp $".
|
||||
# End of "$Id: Makefile,v 1.19.2.7.2.37 2002/06/28 21:04:37 easysw Exp $".
|
||||
#
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: file_chooser.cxx,v 1.4.2.3.2.5 2002/06/07 15:06:32 easysw Exp $"
|
||||
// "$Id: file_chooser.cxx,v 1.4.2.3.2.6 2002/06/28 21:04:37 easysw Exp $"
|
||||
//
|
||||
// File chooser test program.
|
||||
//
|
||||
@ -81,6 +81,8 @@ main(int argc, // I - Number of command-line arguments
|
||||
|
||||
|
||||
// Make the file chooser...
|
||||
fl_register_images();
|
||||
|
||||
Fl::scheme(NULL);
|
||||
Fl_File_Icon::load_system_icons();
|
||||
|
||||
@ -290,5 +292,5 @@ show_callback(void)
|
||||
|
||||
|
||||
//
|
||||
// End of "$Id: file_chooser.cxx,v 1.4.2.3.2.5 2002/06/07 15:06:32 easysw Exp $".
|
||||
// End of "$Id: file_chooser.cxx,v 1.4.2.3.2.6 2002/06/28 21:04:37 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: help.cxx,v 1.1.2.5 2002/06/27 04:29:39 matthiaswm Exp $"
|
||||
// "$Id: help.cxx,v 1.1.2.6 2002/06/28 21:04:37 easysw Exp $"
|
||||
//
|
||||
// Fl_Help_Dialog test program.
|
||||
//
|
||||
@ -45,6 +45,8 @@ main(int argc, // I - Number of command-line arguments
|
||||
Fl_Help_Dialog *help; // Help dialog
|
||||
|
||||
|
||||
fl_register_images();
|
||||
|
||||
help = new Fl_Help_Dialog;
|
||||
|
||||
if (argc < 2)
|
||||
@ -63,5 +65,5 @@ main(int argc, // I - Number of command-line arguments
|
||||
|
||||
|
||||
//
|
||||
// End of "$Id: help.cxx,v 1.1.2.5 2002/06/27 04:29:39 matthiaswm Exp $".
|
||||
// End of "$Id: help.cxx,v 1.1.2.6 2002/06/28 21:04:37 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: pixmap_browser.cxx,v 1.5.2.4.2.6 2002/06/13 18:18:33 easysw Exp $"
|
||||
// "$Id: pixmap_browser.cxx,v 1.5.2.4.2.7 2002/06/28 21:04:37 easysw Exp $"
|
||||
//
|
||||
// A shared image test program for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -83,6 +83,9 @@ int arg(int, char **argv, int &i) {
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
int i = 1;
|
||||
|
||||
fl_register_images();
|
||||
|
||||
Fl::args(argc,argv,i,arg);
|
||||
|
||||
Fl_Window window(400,400); ::w = &window;
|
||||
@ -98,5 +101,5 @@ int main(int argc, char **argv) {
|
||||
}
|
||||
|
||||
//
|
||||
// End of "$Id: pixmap_browser.cxx,v 1.5.2.4.2.6 2002/06/13 18:18:33 easysw Exp $".
|
||||
// End of "$Id: pixmap_browser.cxx,v 1.5.2.4.2.7 2002/06/28 21:04:37 easysw Exp $".
|
||||
//
|
||||
|
@ -279,10 +279,6 @@ SOURCE=..\src\Fl_File_Icon.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_File_Icon2.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_File_Input.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -331,10 +327,6 @@ SOURCE=..\src\Fl_Input_.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_JPEG_Image.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\fl_labeltype.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -415,10 +407,6 @@ SOURCE=..\src\fl_plastic.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_PNG_Image.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_PNM_Image.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
@ -2517,6 +2517,11 @@ DEP_CPP_VSNPR=\
|
||||
"..\src\flstring.h"\
|
||||
".\config.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\fl_images_core.cxx
|
||||
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
||||
|
101
visualc/fltkimages.dsp
Normal file
101
visualc/fltkimages.dsp
Normal file
@ -0,0 +1,101 @@
|
||||
# Microsoft Developer Studio Project File - Name="fltkimages" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Static Library" 0x0104
|
||||
|
||||
CFG=fltkimages - Win32 Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "fltkimages.lib.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "fltkimages.lib.mak" CFG="fltkimages - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "fltkimages - Win32 Release" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE "fltkimages - Win32 Debug" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
CPP=cl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "fltkimages - Win32 Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c
|
||||
# ADD CPP /nologo /MD /GX /Ot /Op /Ob2 /I "." /I ".." /D "FL_STATIC" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "WIN32_LEAN_AND_MEAN" /D "VC_EXTRA_LEAN" /D "WIN32_EXTRA_LEAN" /YX /FD /c
|
||||
# SUBTRACT CPP /Os
|
||||
# ADD BASE RSC /l 0x409
|
||||
# ADD RSC /l 0x409
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo /out:"..\lib\fltkimages.lib"
|
||||
|
||||
!ELSEIF "$(CFG)" == "fltkimages - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /GX /Z7 /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c
|
||||
# ADD CPP /nologo /MDd /GX /Z7 /Od /I "." /I ".." /D "FL_STATIC" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "WIN32_LEAN_AND_MEAN" /D "VC_EXTRA_LEAN" /D "WIN32_EXTRA_LEAN" /FR /YX /FD /c
|
||||
# ADD BASE RSC /l 0x409
|
||||
# ADD RSC /l 0x409
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo /out:"..\lib\fltkimagesd.lib"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "fltkimages - Win32 Release"
|
||||
# Name "fltkimages - Win32 Debug"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\fl_images_core.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_File_Icon2.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_JPEG_Image.cxx
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\src\Fl_PNG_Image.cxx
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
Loading…
Reference in New Issue
Block a user