mirror of
https://github.com/ONLYOFFICE/core.git
synced 2026-07-19 22:01:45 +08:00
49 lines
1.4 KiB
C++
49 lines
1.4 KiB
C++
#pragma once
|
|
|
|
#include "PropertiesMapping.h"
|
|
#include "PictureDescriptor.h"
|
|
#include "TwipsValue.h"
|
|
#include "ConversionContext.h"
|
|
#include "OfficeDrawing/Shapetypes/PictureFrameType.h"
|
|
#include "OfficeDrawing/Shape.h"
|
|
#include "OfficeDrawing/MetafilePictBlip.h"
|
|
#include "OfficeDrawing/BitmapBlip.h"
|
|
#include "VMLShapeTypeMapping.h"
|
|
#include "IMapping.h"
|
|
|
|
namespace DocFileFormat
|
|
{
|
|
class VMLPictureMapping: public PropertiesMapping, public IMapping
|
|
{
|
|
public:
|
|
VMLPictureMapping( ConversionContext* ctx, XmlUtils::CXmlWriter* writer, bool olePreview, IMapping* caller, bool isBulletPicture = false );
|
|
virtual ~VMLPictureMapping();
|
|
virtual void Apply( IVisitable* visited );
|
|
std::wstring GetShapeId() const;
|
|
|
|
private:
|
|
/// Writes a border element
|
|
void writePictureBorder (const wchar_t* name, const BorderCode* brc);
|
|
|
|
protected:
|
|
/// Copies the picture from the binary stream to the zip archive
|
|
/// and creates the relationships for the image.
|
|
bool CopyPicture (BlipStoreEntry* oBlipEntry);
|
|
|
|
public:
|
|
|
|
static std::wstring GetTargetExt (Global::BlipType nType);
|
|
static std::wstring GetContentType (Global::BlipType nType);
|
|
|
|
private:
|
|
|
|
ConversionContext* m_ctx;
|
|
IMapping* m_caller;
|
|
int m_nImageId;
|
|
std::wstring m_ShapeId;
|
|
bool m_olePreview;
|
|
bool m_isBulletPicture;
|
|
XMLTools::XMLElement<wchar_t>* m_imageData;
|
|
};
|
|
}
|