Hi,
I'd like to export an spreadsheet to JPEG.
Unfortunately only 7 of 17 columns are exported in the JPEG file.
I'd like to know if it's possible to remove the padding? The JPEG should
only contain the table without space at it's borders?
I guess that some PropertyValue's are missing ... but I can't figure out
which one.
The function for exporting the spreadsheet looks like this:
void
export_document_jpeg( Reference< XMultiServiceFactory > const&
xMainComponent, std::string const& documentFile) {
Reference< XStorable > xStore{ xMainComponent, UNO_QUERY };
Sequence< PropertyValue > filterParameters{ 3 };
filterParameters[0].Name = OUString::createFromAscii("PixelWidth");
filterParameters[0].Value <<= (sal_uInt32) (1654);
filterParameters[1].Name = OUString::createFromAscii("PixelHeight");
filterParameters[1].Value <<= (sal_uInt32) (2338);
filterParameters[2].Name = OUString::createFromAscii("Quality");
filterParameters[2].Value <<= (sal_uInt32) (100);
Sequence< PropertyValue > storeProps{ 3 };
storeProps[0].Name = OUString::createFromAscii("Overwrite");
storeProps[0].Value <<= (bool)(true);
storeProps[1].Name = OUString::createFromAscii("FilterName");
storeProps[1].Value <<= OUString::createFromAscii("writer_jpg_Export");
storeProps[2].Name = OUString::createFromAscii("FilterData");
storeProps[2].Value <<= filterParameters;
xStore->storeToURL( OUString::createFromAscii( documentFile.c_str() ),
storeProps);
}
Thank you in advance.
Oliver