Bug 119055

Summary: UNO commands to directly export a graphic as SVG, PNG, JPG
Product: LibreOffice Reporter: andreas_k <kainz.a>
Component: DrawAssignee: Not Assigned <libreoffice-bugs>
Status: NEW ---    
Severity: enhancement CC: heiko.tietze, kainz.a
Priority: medium    
Version: 6.1.0.0.beta1+   
Hardware: All   
OS: All   
Whiteboard:
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 86899    

Description andreas_k 2018-08-02 06:49:31 UTC
In writer you can use 
.uno:ExportToPDF and 
.uno:ExportToEPUB 

it would be nice to have for draw 
.uno:ExportToSVG
.uno:ExportToPNG
.uno:ExportToJPG

I know everything is available via the export command but it's the same in writer and export an image to png is very common.
Comment 1 Heiko Tietze 2018-08-02 08:02:33 UTC
The actual request is ahout a quick way to export in the given format, in particular needed for the Notebookbar ("nice to have" is not a use case). But OTOH it blows up the UNO commands. Maybe we can enhance the function and remember the filename so when the document has been exported once it just overrides the file. (There should be a ticket about this but I didn't find.)

Opinions?
Comment 2 andreas_k 2018-08-02 08:31:21 UTC
It's for the menubar in draw and for Notebookbar and the idea is to be consistent with other apps where you have "quick" export access and export to png should be defenitiv available.
Comment 3 Heiko Tietze 2018-10-28 11:59:08 UTC
No further opinions, let's do it (also since .uno:SaveGraphic is for some reasons not working in macros). The functions could be introduced similar to .uno:ExportDirectToPDF and just show the file dialog.