X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fgraphics%2FGraphicsImage.h;h=6722b87bc03f20637a8450dd7732b58ae5d5c69b;hb=28be7d552f62cc02fa86d7f79201d089bfb2d7b5;hp=7a90876e2d70d2c35e86bded90b05e09760dd941;hpb=264f32ec376b04538d9d0a2d1664de7527772f79;p=lyx.git diff --git a/src/graphics/GraphicsImage.h b/src/graphics/GraphicsImage.h index 7a90876e2d..6722b87bc0 100644 --- a/src/graphics/GraphicsImage.h +++ b/src/graphics/GraphicsImage.h @@ -24,13 +24,6 @@ #ifndef GRAPHICSIMAGE_H #define GRAPHICSIMAGE_H -#include "Dimension.h" - -#include -#include - -#include - namespace lyx { namespace support { class FileName; } @@ -41,11 +34,6 @@ class Params; class Image { public: - /** This is to be connected to a function that will return a new - * instance of a viable derived class. - */ - static boost::function newImage; - /// virtual ~Image() {} @@ -61,13 +49,6 @@ public: /// Is the image drawable ? virtual bool isDrawable() const = 0; - /** At the end of the loading process inform the outside world - * by emitting a signal - */ - typedef boost::signal SignalType; - /// - SignalType finishedLoading; - /** Start loading the image file. * The caller should expect this process to be asynchronous and * so should connect to the "finished" signal above. @@ -79,29 +60,11 @@ public: * Returns true if the pixmap is created. */ virtual bool setPixmap(Params const & params) = 0; - - /// Clip the image using params. - virtual void clip(Params const & params) = 0; - - /// Rotate the image using params. - virtual void rotate(Params const & params) = 0; - - /// Scale the image using params. - virtual void scale(Params const & params) = 0; - -protected: - /// Must define default c-tor explicitly as we define a copy c-tor. - Image() {} - /// Don't copy the signal finishedLoading - Image(Image const &) {} - - /** Uses the params to ascertain the dimensions of the scaled image. - * Returned as Dimension(width, height, 0 descend). - * If something goes wrong, returns make_pair(getWidth(), getHeight(), 0) - */ - Dimension scaledDimension(Params const & params) const; }; +/// Only way to create a new Image. +/// Implemented in the frontend. +Image * newImage(); } // namespace graphics } // namespace lyx