Bug 386883

Summary: Missing file extension when exporting to file
Product: [Applications] LabPlot2 Reporter: uwestoehr <uwestoehr>
Component: frontendAssignee: Alexander Semke <alexander.semke>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version First Reported In: latest   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In: 2.5
Sentry Crash Report:
Attachments: export to file window without preset file extension

Description uwestoehr 2017-11-13 22:46:57 UTC
- create a plot
- use the menu File -> Export

The predefined export format is PDF.

- now click the button behind the File name field to specify a path and filename for the PDF export

result: Instead of the PDF export window a generic one named "Export to file" (see attached) pops up. There you cannot set a file type.

- thus enter "test.pdf"

This works but since the specified file format is PDF, the export window should have the .pdf extension as preset.
Comment 1 uwestoehr 2017-11-13 22:48:01 UTC
Created attachment 108846 [details]
export to file window without preset file extension
Comment 2 Alexander Semke 2017-11-14 22:36:09 UTC
Git commit d62aecf679f2b74c8617a39d3bbb0377ad6aabda by Alexander Semke.
Committed on 14/11/2017 at 22:34.
Pushed by asemke into branch 'master'.

In ExportWorksheetDialog:
1. show the file filter in the OpenFileDialog according to the selected output format
2. don't crash if PNG was selected.
FIXED-IN: 2.5

M  +14   -5    src/kdefrontend/worksheet/ExportWorksheetDialog.cpp

https://commits.kde.org/labplot/d62aecf679f2b74c8617a39d3bbb0377ad6aabda