]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/xforms/XPainter.C
Yet more dialog tweaking from Rob.
[lyx.git] / src / frontends / xforms / XPainter.C
index 929db4904fb05f64a4f22f109feba1bffbbb9a6f..a40b7f2ad4639125ac56787367031cae04df8bc8 100644 (file)
@@ -1,10 +1,12 @@
 /**
  * \file XPainter.C
- * Copyright 1998-2002 the LyX Team
- * Read the file COPYING
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
  *
  * \author unknown
- * \author John Levon <moz@compsoc.man.ac.uk>
+ * \author John Levon 
+ *
+ * Full author contact details are available in file CREDITS
  */
 
 #include <config.h>
 #include "encoding.h"
 #include "language.h"
 
+#ifdef USE_XFORMS_IMAGE_LOADER
 #include "xformsImage.h"
+#else
+#include "graphics/GraphicsImageXPM.h"
+#endif
 
 #include "support/LAssert.h"
 #include "support/lstrings.h"
@@ -152,7 +158,12 @@ Painter & XPainter::image(int x, int y,
        int w, int h,
        grfx::Image const & i)
 {
+#ifdef USE_XFORMS_IMAGE_LOADER
        grfx::xformsImage const & image = static_cast<grfx::xformsImage const &>(i);
+#else
+       grfx::ImageXPM const & image = static_cast<grfx::ImageXPM const &>(i);
+#endif
+       
        XGCValues val;
        val.function = GXcopy;
        GC gc = XCreateGC(fl_get_display(), owner_.getPixmap(),
@@ -199,7 +210,7 @@ Painter & XPainter::text(int x, int y,
                        xs[i].byte1 = c >> 8;
                        xs[i].byte2 = c & 0xff;
                }
-               text(x , y, xs.get(), ls, font);
+               text(x, y, xs.get(), ls, font);
                return *this;
        }