X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fgraphics%2FPreviewImage.h;h=6b5ac7e66cd1d1e0495a0b84a5aa37570fa7adfd;hb=4ddc9e2501400f8bdc35d4d1fe56f39c49e82115;hp=c4de71bfc896de0ac1c7e4ffca8424cfe43a4010;hpb=686f1e276f013e2dc56e3025798c7131bef173f5;p=lyx.git diff --git a/src/graphics/PreviewImage.h b/src/graphics/PreviewImage.h index c4de71bfc8..6b5ac7e66c 100644 --- a/src/graphics/PreviewImage.h +++ b/src/graphics/PreviewImage.h @@ -12,12 +12,17 @@ #ifndef PREVIEWIMAGE_H #define PREVIEWIMAGE_H -#include -#include +#include "support/strfwd.h" namespace lyx { + +namespace support { class FileName; } + +class Dimension; + namespace graphics { +class Cache; class PreviewLoader; class Image; @@ -28,7 +33,7 @@ public: */ PreviewImage(PreviewLoader & parent, std::string const & latex_snippet, - std::string const & bitmap_file, + support::FileName const & bitmap_file, double ascent_frac); /// ~PreviewImage(); @@ -36,22 +41,22 @@ public: /// std::string const & snippet() const; /// - int ascent() const; - /// - int descent() const; - /// - int width() const; + Dimension dim() const; /** If the image is not yet loaded (WaitingToLoad), then this method * triggers that. */ Image const * image() const; + /// + support::FileName const & filename() const; + + PreviewLoader & previewLoader() const; private: /// Use the Pimpl idiom to hide the internals. class Impl; /// The pointer never changes although *pimpl_'s contents may. - boost::scoped_ptr const pimpl_; + Impl * const pimpl_; }; } // namespace graphics