31#include <svtools/strings.hrc>
34#include <com/sun/star/beans/XPropertySet.hpp>
35#include <com/sun/star/awt/Size.hpp>
36#include <com/sun/star/drawing/GraphicExportFilter.hpp>
37#include <com/sun/star/drawing/XDrawView.hpp>
38#include <com/sun/star/frame/XModel.hpp>
39#include <com/sun/star/frame/XController.hpp>
40#include <com/sun/star/graphic/PrimitiveFactory2D.hpp>
41#include <com/sun/star/geometry/AffineMatrix2D.hpp>
42#include <com/sun/star/io/XStream.hpp>
47#include <rtl/ustrbuf.hxx>
51#define FORMAT_UNKNOWN 0
63#define UNIT_DEFAULT -1
69#define UNIT_MAX_ID UNIT_PIXEL
78 else if ( rExt ==
u"PNG" )
80 else if ( rExt ==
u"BMP" )
82 else if ( rExt ==
u"GIF" )
84 else if ( rExt ==
u"TIF" )
86 else if ( rExt ==
u"WMF" )
88 else if ( rExt ==
u"EMF" )
90 else if ( rExt ==
u"EPS" )
92 else if ( rExt ==
u"SVG" )
94 else if ( rExt ==
u"WEBP" )
101 MapUnit aMapUnit( MapUnit::MapPixel );
104 case UNIT_INCH : aMapUnit = MapUnit::MapInch;
break;
105 case UNIT_CM : aMapUnit = MapUnit::MapCM;
break;
106 case UNIT_MM : aMapUnit = MapUnit::MapMM;
break;
107 case UNIT_POINT : aMapUnit = MapUnit::MapPoint;
break;
108 case UNIT_PIXEL : aMapUnit = MapUnit::MapPixel;
break;
115 sal_Int32 nDefaultUnit =
UNIT_CM;
121 default: nDefaultUnit =
UNIT_CM;
break;
123 case FieldUnit::MILE :
124 case FieldUnit::FOOT :
125 case FieldUnit::TWIP :
126 case FieldUnit::PICA : nDefaultUnit =
UNIT_INCH;
break;
130 case FieldUnit::MM_100TH : nDefaultUnit =
UNIT_CM;
break;
132 case FieldUnit::INCH : nDefaultUnit =
UNIT_INCH;
break;
133 case FieldUnit::CM : nDefaultUnit =
UNIT_CM;
break;
134 case FieldUnit::MM : nDefaultUnit =
UNIT_MM;
break;
135 case FieldUnit::POINT : nDefaultUnit =
UNIT_POINT;
break;
141 const uno::Reference< graphic::XPrimitiveFactory2D >& rxPrimitiveFactory2D,
const uno::Sequence< beans::PropertyValue >& rViewInformation )
145 const uno::Sequence< beans::PropertyValue > aParams;
146 const uno::Sequence< uno::Reference< graphic::XPrimitive2D > > aPrimitiveSequence( rxPrimitiveFactory2D->createPrimitivesFromXShape( rxShape, aParams ) );
148 for(
const auto& rPrimitive : aPrimitiveSequence )
150 const geometry::RealRectangle2D aRect( rPrimitive->getRange( rViewInformation ) );
161 sal_Int32 nUnit =
mxLbSizeX->get_active();
175 if ( nResolution < 1 )
179 mpOptionsItem->WriteInt32(
"PixelExportResolution", nResolution);
200 static constexpr OUStringLiteral sLogicalWidth(
u"LogicalWidth");
201 static constexpr OUStringLiteral sLogicalHeight(
u"LogicalHeight");
208 const double f100thmmPerPixelX = 100000.0 /
maResolution.Width;
209 const double f100thmmPerPixelY = 100000.0 /
maResolution.Height;
210 sal_Int32 nLogicalWidth =
static_cast< sal_Int32
>( f100thmmPerPixelX *
maSize.Width );
211 sal_Int32 nLogicalHeight=
static_cast< sal_Int32
>( f100thmmPerPixelY *
maSize.Height );
212 if ( nLogicalWidth && nLogicalHeight )
214 pFilterOptions->
WriteInt32( sLogicalWidth, nLogicalWidth );
215 pFilterOptions->
WriteInt32( sLogicalHeight, nLogicalHeight );
233 pFilterOptions->
WriteInt32(
"ColorMode", nColor);
243 sal_Int32 nInterlace = 0;
246 pFilterOptions->
WriteInt32(
"Interlaced", nInterlace);
277 sal_Int32 nCheck = 0;
282 pFilterOptions->
WriteInt32(
"Preview", nCheck);
287 pFilterOptions->
WriteInt32(
"Version", nCheck);
292 pFilterOptions->
WriteInt32(
"ColorFormat", nCheck);
297 pFilterOptions->
WriteInt32(
"CompressionMode", nCheck);
311 uno::Sequence< beans::PropertyValue > aRet( pFilterOptions->
GetFilterData() );
312 if ( !bUpdateConfig )
313 delete pFilterOptions;
324 uno::Reference< beans::XPropertySet > xPagePropSet(
mxPage, uno::UNO_QUERY );
325 if ( xPagePropSet.is() )
327 sal_Int32 nWidth = 0;
328 sal_Int32 nHeight= 0;
330 aAny = xPagePropSet->getPropertyValue(
"Width");
332 aAny = xPagePropSet->getPropertyValue(
"Height");
339 uno::Reference< graphic::XPrimitiveFactory2D > xPrimitiveFactory = graphic::PrimitiveFactory2D::create(
mxContext );
342 css::geometry::AffineMatrix2D aTransformation;
343 aTransformation.m00 = aViewTransformation.
get(0,0);
344 aTransformation.m01 = aViewTransformation.
get(0,1);
345 aTransformation.m02 = aViewTransformation.
get(0,2);
346 aTransformation.m10 = aViewTransformation.
get(1,0);
347 aTransformation.m11 = aViewTransformation.
get(1,1);
348 aTransformation.m12 = aViewTransformation.
get(1,2);
351 "ViewTransformation", aTransformation) };
360 uno::Reference< drawing::XShape > xShape;
373 return awt::Size(
static_cast<sal_Int32
>(aShapesRange.
getWidth()),
static_cast<sal_Int32
>(aShapesRange.
getHeight()) );
388 uno::Reference< frame::XController >
xController(
xModel->getCurrentController() );
399 uno::Reference< drawing::XDrawView > xDrawView(
xController, uno::UNO_QUERY );
400 if ( xDrawView.is() )
402 uno::Reference< drawing::XDrawPage > xCurrentPage( xDrawView->getCurrentPage() );
403 if ( xCurrentPage.is() )
424 static uno::Sequence< beans::PropertyValue > aOldFilterData;
425 uno::Sequence< beans::PropertyValue > aNewFilterData(
GetFilterData(
false ) );
426 if ( aOldFilterData != aNewFilterData )
428 aOldFilterData = aNewFilterData;
429 bRecreateOutputStream =
true;
433 if ( bRecreateOutputStream )
437 uno::Reference< graphic::XGraphic > xGraphic;
447 aDocumentSizePixel );
450 aDocumentSizePixel, aTargetSizePixel,
COL_WHITE,
false));
458 if ( aGraphic.
GetType() == GraphicType::Bitmap )
483 uno::Reference< lang::XComponent > xSourceDoc;
485 xSourceDoc.set(
mxPage, uno::UNO_QUERY_THROW );
487 xSourceDoc.set(
mxShapes, uno::UNO_QUERY_THROW );
489 xSourceDoc.set(
mxShape, uno::UNO_QUERY_THROW );
490 if ( xSourceDoc.is() )
493 uno::Reference < io::XOutputStream > xOutputStream(
xStream->getOutputStream() );
495 OUString sFormat(
maExt );
496 uno::Sequence< beans::PropertyValue > aDescriptor{
502 uno::Reference< drawing::XGraphicExportFilter > xGraphicExporter =
503 drawing::GraphicExportFilter::create(
mxContext );
505 xGraphicExporter->setSourceDocument( xSourceDoc );
506 xGraphicExporter->filter( aDescriptor );
511 catch( uno::Exception& )
521 sal_uInt64 nRawFileSize = 0;
524 sal_Int32 nBitsPerPixel = 24;
537 nRawFileSize = (
maSize.Width * nBitsPerPixel + 7 ) &~ 7;
539 nRawFileSize *=
maSize.Height;
544 return static_cast< sal_uInt32
>( nRawFileSize );
555 css::uno::Reference< css::uno::XComponentContext > xContext,
556 const css::uno::Reference< css::lang::XComponent >& rxSourceDocument,
557 bool bExportSelection,
bool bIsPixelFormat,
bool bGraphicsSource,
558 const css::uno::Reference< css::graphic::XGraphic >& rxGraphic)
559 : GenericDialogController(rPara.pWindow,
"svt/ui/graphicexport.ui",
"GraphicExportDialog")
560 , mrFltCallPara(rPara)
562 , mxSourceDocument(rxSourceDocument)
564 , msEstimatedSizePix1(
SvtResId(STR_SVT_ESTIMATED_SIZE_PIX_1))
565 , msEstimatedSizePix2(
SvtResId(STR_SVT_ESTIMATED_SIZE_PIX_2))
566 , msEstimatedSizeVec(
SvtResId(STR_SVT_ESTIMATED_SIZE_VEC))
567 , ms1BitThreshold(
SvtResId(STR_SVT_1BIT_THRESHOLD))
568 , ms8BitGrayscale(
SvtResId(STR_SVT_8BIT_GRAYSCALE))
569 , ms8BitColorPalette(
SvtResId(STR_SVT_8BIT_COLOR_PALETTE))
570 , ms24BitColor(
SvtResId(STR_SVT_24BIT_TRUE_COLOR))
571 , maExt(rPara.aFilterExt)
573 , mnMaxFilesizeForRealtimePreview(0)
575 , maOriginalSize(awt::
Size(0, 0))
576 , mbIsPixelFormat(bIsPixelFormat)
577 , mbExportSelection(bExportSelection)
578 , mbGraphicsSource(bGraphicsSource)
579 , mpSbCompression(nullptr)
580 , mpNfCompression(nullptr)
581 , mxMfSizeX(m_xBuilder->weld_spin_button(
"widthmf"))
582 , mxLbSizeX(m_xBuilder->weld_combo_box(
"widthlb"))
583 , mxMfSizeY(m_xBuilder->weld_spin_button(
"heightmf"))
584 , mxFtResolution(m_xBuilder->weld_label(
"resolutionft"))
585 , mxNfResolution(m_xBuilder->weld_spin_button(
"resolutionmf"))
586 , mxLbResolution(m_xBuilder->weld_combo_box(
"resolutionlb"))
587 , mxColorDepth(m_xBuilder->weld_widget(
"colordepth"))
588 , mxLbColorDepth(m_xBuilder->weld_combo_box(
"colordepthlb"))
589 , mxJPGWEBPQuality(m_xBuilder->weld_widget(
"jpgwebpquality"))
590 , mxPNGCompression(m_xBuilder->weld_widget(
"pngcompression"))
591 , mxSbPngCompression(m_xBuilder->weld_scale(
"compressionpngsb"))
592 , mxNfPngCompression(m_xBuilder->weld_spin_button(
"compressionpngnf"))
593 , mxSbJpgWebpCompression(m_xBuilder->weld_scale(
"compressionjpgwebpsb"))
594 , mxNfJpgWebpCompression(m_xBuilder->weld_spin_button(
"compressionjpgwebpnf"))
595 , mxCbLossless(m_xBuilder->weld_check_button(
"losslesscb"))
596 , mxMode(m_xBuilder->weld_widget(
"mode"))
597 , mxCbInterlaced(m_xBuilder->weld_check_button(
"interlacedcb"))
598 , mxBMPCompression(m_xBuilder->weld_widget(
"bmpcompression"))
599 , mxCbRLEEncoding(m_xBuilder->weld_check_button(
"rlecb"))
600 , mxDrawingObjects(m_xBuilder->weld_widget(
"drawingobjects"))
601 , mxCbSaveTransparency(m_xBuilder->weld_check_button(
"savetransparencycb"))
602 , mxEncoding(m_xBuilder->weld_widget(
"encoding"))
603 , mxRbBinary(m_xBuilder->weld_radio_button(
"binarycb"))
604 , mxRbText(m_xBuilder->weld_radio_button(
"textcb"))
605 , mxEPSGrid(m_xBuilder->weld_widget(
"epsgrid"))
606 , mxModifyDimension(m_xBuilder->weld_radio_button(
"modifydimensionscb"))
607 , mxModifyResolution(m_xBuilder->weld_radio_button(
"modifyresolutioncb"))
608 , mxCbEPSPreviewTIFF(m_xBuilder->weld_check_button(
"tiffpreviewcb"))
609 , mxCbEPSPreviewEPSI(m_xBuilder->weld_check_button(
"epsipreviewcb"))
610 , mxRbEPSLevel1(m_xBuilder->weld_radio_button(
"level1rb"))
611 , mxRbEPSLevel2(m_xBuilder->weld_radio_button(
"level2rb"))
612 , mxRbEPSColorFormat1(m_xBuilder->weld_radio_button(
"color1rb"))
613 , mxRbEPSColorFormat2(m_xBuilder->weld_radio_button(
"color2rb"))
614 , mxRbEPSCompressionLZW(m_xBuilder->weld_radio_button(
"compresslzw"))
615 , mxRbEPSCompressionNone(m_xBuilder->weld_radio_button(
"compressnone"))
616 , mxInfo(m_xBuilder->weld_widget(
"information"))
617 , mxFtEstimatedSize(m_xBuilder->weld_label(
"estsizeft"))
618 , mxBtnOK(m_xBuilder->weld_button(
"ok"))
624 OUString aFilterConfigPath(
"Office.Common/Filter/Graphic/Export/" );
626 aFilterConfigPath +=
maExt;
634 mpOptionsItem->ReadInt32(
"MaxFilesizeForRealtimePreview", 0), sal_Int32(0));
650 double f100thmmPerPixel = 100000.0 /
static_cast< double >(
maResolution.Width );
652 static_cast< sal_Int32
>( f100thmmPerPixel *
maSize.Width ),
653 static_cast< sal_Int32
>( f100thmmPerPixel *
maSize.Height ) );
658 if ( bIsPixelFormat )
660 double fPixelsPer100thmm =
static_cast< double >(
maResolution.Width ) / 100000.0;
661 maSize = awt::Size(
static_cast< sal_Int32
>( ( fPixelsPer100thmm *
maOriginalSize.Width ) + 0.5 ),
662 static_cast< sal_Int32
>( ( fPixelsPer100thmm *
maOriginalSize.Height ) + 0.5 ) );
736 mxLbSizeX->set_active(
static_cast< sal_uInt16
>( nUnit ) );
743 sal_Int32 nResolution =
mpOptionsItem->ReadInt32(
"PixelExportResolution", 96);
744 if ( nResolution < 1 )
748 sal_Int32 nResolutionUnit =
mpOptionsItem->ReadInt32(
"PixelExportResolutionUnit", 1);
749 if ( ( nResolutionUnit < 0 ) || ( nResolutionUnit > 2 ) )
751 mxLbResolution->set_active(
static_cast< sal_uInt16
>( nResolutionUnit ) );
773 if ((nQuality < 1 ) || (nQuality > 100))
788 if ( ( nCompression < 1 ) || ( nCompression > 9 ) )
865 if ((nQuality < 1 ) || (nQuality > 100))
892 double fVal(
static_cast<double>( rVal ) );
895 OUStringBuffer aVal( OUString::number( fVal ) );
896 sal_Int32 nX( aVal.indexOf(
'.' ) );
898 aVal.setLength( nX + 2 );
899 return aVal.makeStringAndClear();
907 awt::Size aSize100thmm(
maSize );
917 if ( aMapUnit == MapUnit::MapPixel )
931 case MapUnit::MapInch : fRatio =
static_cast< double >(
maResolution.Width ) * 0.0254;
break;
932 case MapUnit::MapMM : fRatio =
static_cast< double >(
maResolution.Width ) * 0.001;
break;
933 case MapUnit::MapPoint :fRatio = (
static_cast< double >(
maResolution.Width ) * 0.0254 ) / 72.0;
break;
935 case MapUnit::MapCM : fRatio =
static_cast< double >(
maResolution.Width ) * 0.01;
break;
937 mxMfSizeX->set_value(
static_cast< sal_Int32
>( (
static_cast< double >(
maSize.Width * 100 ) / fRatio ) + 0.5 ) );
938 mxMfSizeY->set_value(
static_cast< sal_Int32
>( (
static_cast< double >(
maSize.Height * 100 ) / fRatio ) + 0.5 ) );
941 sal_Int32 nResolution = 0;
947 case 1 : nResolution =
static_cast< sal_Int32
>(
maResolution.Width * 0.0254);
break;
962 sal_Int32 nInd = aEst.indexOf(
"%" );
966 if ( nRealFileSize && nInd != -1 )
968 nInd = aEst.indexOf(
"%", nInd );
970 aEst = aEst.replaceAt( nInd, 2,
ImpValueOfInKB( nRealFileSize ) );
979 sal_Int32 nInd = aEst.indexOf(
"%" );
981 aEst = aEst.replaceAt( nInd, 2,
ImpValueOfInKB( nRealFileSize ) );
1023 mpSbCompression->set_sensitive(!mxCbLossless->get_active());
1024 mpNfCompression->set_sensitive(!mxCbLossless->get_active());
1030 if (mxModifyResolution->get_active())
1032 mxMfSizeY->set_sensitive(
false);
1033 mxMfSizeX->set_sensitive(
false);
1034 mxNfResolution->set_sensitive(
true);
1038 mxMfSizeY->set_sensitive(
true);
1039 mxMfSizeX->set_sensitive(
true);
1040 mxNfResolution->set_sensitive(
false);
1048 double fRatio =
static_cast< double >( maOriginalSize.Height ) / maOriginalSize.Width;
1050 if ( mbIsPixelFormat )
1052 switch(
GetMapUnit( mxLbSizeX->get_active() ) )
1054 case MapUnit::MapInch :
maSize.Width =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Width ) * 0.0254 * mxMfSizeX->get_value() / 100.0 + 0.5 );
break;
1055 case MapUnit::MapCM :
maSize.Width =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Width ) * 0.01 * mxMfSizeX->get_value() / 100.0 + 0.5 );
break;
1056 case MapUnit::MapMM :
maSize.Width =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Width ) * 0.001 * mxMfSizeX->get_value() / 100.0 + 0.5 );
break;
1057 case MapUnit::MapPoint :
maSize.Width =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Width ) * 0.0254 * mxMfSizeX->get_value() / 100.0 * 72 + 0.5 );
break;
1059 case MapUnit::MapPixel :
maSize.Width = mxMfSizeX->get_value();
break;
1061 maSize.Height =
static_cast< sal_Int32
>( fRatio *
maSize.Width + 0.5 );
1066 sal_Int32 nWidth = mxMfSizeX->get_value();
1067 sal_Int32 nHeight=
static_cast< sal_Int32
>( nWidth * fRatio );
1068 const Size aSource( nWidth, nHeight );
1080 double fRatio =
static_cast< double >( maOriginalSize.Width ) / maOriginalSize.Height;
1082 if ( mbIsPixelFormat )
1084 switch(
GetMapUnit( mxLbSizeX->get_active() ) )
1086 case MapUnit::MapInch :
maSize.Height =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Height ) * 0.0254 * mxMfSizeY->get_value() / 100.0 + 0.5 );
break;
1087 case MapUnit::MapCM :
maSize.Height =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Height ) * 0.01 * mxMfSizeY->get_value() / 100.0 + 0.5 );
break;
1088 case MapUnit::MapMM :
maSize.Height =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Height ) * 0.001 * mxMfSizeY->get_value() / 100.0 + 0.5 );
break;
1089 case MapUnit::MapPoint :
maSize.Height =
static_cast< sal_Int32
>(
static_cast< double >( maResolution.Height ) * 0.0254 * mxMfSizeY->get_value() / 100.0 * 72 + 0.5 );
break;
1091 case MapUnit::MapPixel :
maSize.Height = mxMfSizeY->get_value();
break;
1093 maSize.Width =
static_cast< sal_Int32
>( fRatio *
maSize.Height + 0.5 );
1098 sal_Int32 nHeight= mxMfSizeY->get_value();
1099 sal_Int32 nWidth =
static_cast< sal_Int32
>( nHeight * fRatio );
1100 const Size aSource( nWidth, nHeight );
1112 auto nResolution = mxNfResolution->get_value();
1113 if ( mxLbResolution->get_active() == 0 )
1115 else if ( mxLbResolution->get_active() == 1 )
1116 nResolution =
static_cast< sal_Int32
>( ( (
static_cast< double >( nResolution ) + 0.5 ) / 0.0254 ) );
1117 maResolution.Width = nResolution;
1118 maResolution.Height= nResolution;
1125 mpNfCompression->set_value(mpSbCompression->get_value());
1133 mrFltCallPara.aFilterData = GetFilterData(
true );
geometry::RealSize2D maSize
Reference< XExecutableDialog > m_xDialog
static OutputDevice * GetDefaultDevice()
bool Scale(const Size &rNewSize, BmpScaleFlag nScaleFlag=BmpScaleFlag::Default)
Size getDocumentSizeIn100mm(sal_Int32 nCurrentPage, Point *pDocumentPosition=nullptr, Point *pCalcPagePosition=nullptr, Size *pCalcPageSize=nullptr)
Graphic renderToGraphic(sal_Int32 nCurrentPage, Size aDocumentSizePixel, Size aTargetSizePixel, Color aPageColor, bool bExtOutDevData)
sal_Int32 getCurrentPage()
Size getDocumentSizeInPixels(sal_Int32 nCurrentPage)
static bool isShapeSelected(css::uno::Reference< css::drawing::XShapes > &rxShapes, css::uno::Reference< css::drawing::XShape > &rxShape, const css::uno::Reference< css::frame::XController > &rxController)
Determine whether rxController has a css::view::XSelectionSupplier at which either a css::drawing::XS...
std::unique_ptr< weld::RadioButton > mxRbEPSColorFormat1
std::unique_ptr< weld::Widget > mxJPGWEBPQuality
virtual ~ExportDialog() override
std::unique_ptr< weld::SpinButton > mxMfSizeY
std::unique_ptr< weld::CheckButton > mxCbRLEEncoding
weld::SpinButton * mpNfCompression
std::unique_ptr< weld::Scale > mxSbPngCompression
css::awt::Size maResolution
std::unique_ptr< weld::RadioButton > mxRbEPSLevel1
std::unique_ptr< weld::ComboBox > mxLbColorDepth
std::unique_ptr< weld::CheckButton > mxCbEPSPreviewEPSI
std::unique_ptr< weld::RadioButton > mxRbEPSColorFormat2
std::unique_ptr< weld::RadioButton > mxModifyDimension
std::unique_ptr< weld::RadioButton > mxRbBinary
std::unique_ptr< SvMemoryStream > mpTempStream
weld::Scale * mpSbCompression
std::unique_ptr< weld::RadioButton > mxRbEPSLevel2
std::unique_ptr< weld::RadioButton > mxRbText
std::unique_ptr< weld::Widget > mxColorDepth
std::unique_ptr< weld::SpinButton > mxNfJpgWebpCompression
std::unique_ptr< weld::Widget > mxMode
std::unique_ptr< weld::ComboBox > mxLbResolution
css::uno::Sequence< css::beans::PropertyValue > GetFilterData(bool bUpdateConfig)
css::uno::Reference< css::drawing::XShapes > mxShapes
OUString msEstimatedSizePix1
std::unique_ptr< weld::CheckButton > mxCbInterlaced
std::unique_ptr< weld::RadioButton > mxRbEPSCompressionLZW
std::unique_ptr< weld::Widget > mxEPSGrid
std::unique_ptr< weld::CheckButton > mxCbSaveTransparency
OUString msEstimatedSizePix2
std::unique_ptr< weld::Widget > mxDrawingObjects
std::unique_ptr< weld::RadioButton > mxModifyResolution
std::unique_ptr< weld::Widget > mxBMPCompression
std::unique_ptr< weld::Widget > mxPNGCompression
std::unique_ptr< weld::SpinButton > mxNfResolution
OUString msEstimatedSizeVec
sal_uInt32 GetRawFileSize() const
ExportDialog(FltCallDialogParameter &rPara, css::uno::Reference< css::uno::XComponentContext > xContext, const css::uno::Reference< css::lang::XComponent > &rxSourceDocument, bool bExportSelection, bool bIsExportVectorFormat, bool bGraphicsSource, const css::uno::Reference< css::graphic::XGraphic > &rxGraphic)
std::unique_ptr< weld::Label > mxFtEstimatedSize
css::uno::Reference< css::drawing::XDrawPage > mxPage
css::uno::Reference< css::drawing::XShape > mxShape
std::unique_ptr< weld::Label > mxFtResolution
const css::uno::Reference< css::lang::XComponent > & mxSourceDocument
sal_Int32 GetDefaultUnit() const
std::unique_ptr< weld::SpinButton > mxNfPngCompression
std::unique_ptr< weld::Widget > mxInfo
css::awt::Size GetOriginalSize()
std::unique_ptr< weld::RadioButton > mxRbEPSCompressionNone
css::awt::Size maOriginalSize
std::unique_ptr< weld::Scale > mxSbJpgWebpCompression
std::unique_ptr< weld::ComboBox > mxLbSizeX
std::unique_ptr< weld::Button > mxBtnOK
std::unique_ptr< weld::CheckButton > mxCbLossless
OUString ms8BitColorPalette
sal_Int32 mnInitialResolutionUnit
const css::uno::Reference< css::uno::XComponentContext > mxContext
const css::uno::Reference< css::graphic::XGraphic > & mxGraphic
void createFilterOptions()
std::unique_ptr< FilterConfigItem > mpOptionsItem
std::unique_ptr< weld::SpinButton > mxMfSizeX
FltCallDialogParameter & mrFltCallPara
std::unique_ptr< FilterConfigItem > mpFilterOptionsItem
sal_Int32 mnMaxFilesizeForRealtimePreview
std::unique_ptr< weld::CheckButton > mxCbEPSPreviewTIFF
bool IsTempExportAvailable() const
void WriteBool(const OUString &rKey, bool bValue)
void WriteInt32(const OUString &rKey, sal_Int32 nValue)
const css::uno::Sequence< css::beans::PropertyValue > & GetFilterData() const
sal_uInt16 GetExportFormatNumberForShortName(std::u16string_view rShortName)
static GraphicFilter & GetGraphicFilter()
bool IsExportPixelFormat(sal_uInt16 nFormat)
ErrCode ExportGraphic(const Graphic &rGraphic, const INetURLObject &rPath, sal_uInt16 nFormat, const css::uno::Sequence< css::beans::PropertyValue > *pFilterData=nullptr)
css::uno::Reference< css::graphic::XGraphic > GetXGraphic() const
GraphicType GetType() const
BitmapEx GetBitmapEx(const GraphicConversionParameters &rParameters=GraphicConversionParameters()) const
Size GetSizePixel(const OutputDevice *pRefDevice=nullptr) const
SAL_WARN_UNUSED_RESULT Point LogicToLogic(const Point &rPtSource, const MapMode *pMapModeSource, const MapMode *pMapModeDest) const
constexpr tools::Long getHeight() const
constexpr tools::Long Height() const
constexpr tools::Long getWidth() const
constexpr tools::Long Width() const
double get(sal_uInt16 nRow, sal_uInt16 nColumn) const
void expand(const Tuple2D< TYPE > &rTuple)
std::shared_ptr< weld::Dialog > m_xDialog
virtual void set_range(int min, int max)=0
void connect_value_changed(const Link< Scale &, void > &rLink)
virtual int get_value() const=0
virtual void set_value(int value)=0
constexpr ::Color COL_WHITE(0xFF, 0xFF, 0xFF)
static basegfx::B2DRange GetShapeRangeForXShape(const uno::Reference< drawing::XShape > &rxShape, const uno::Reference< graphic::XPrimitiveFactory2D > &rxPrimitiveFactory2D, const uno::Sequence< beans::PropertyValue > &rViewInformation)
static MapUnit GetMapUnit(sal_Int32 nUnit)
static OUString ImpValueOfInKB(sal_Int64 rVal)
static sal_Int16 GetFilterFormat(std::u16string_view rExt)
IMPL_LINK_NOARG(ExportDialog, SelectHdl, weld::SpinButton &, void)
#define LINK(Instance, Class, Member)
if(aStr !=aBuf) UpdateName_Impl(m_xFollowLb.get()
css::beans::PropertyValue makePropertyValue(const OUString &rName, T &&rValue)
constexpr std::enable_if_t< std::is_signed_v< T >, std::make_unsigned_t< T > > make_unsigned(T value)
css::uno::Sequence< css::beans::PropertyValue > aFilterData
Reference< XController > xController
Reference< XModel > xModel
OUString SvtResId(TranslateId aId)