Bug 481478 - File save dialog shouldn't append ".jpeg" to the filename when the user specifies ".jpg"
Summary: File save dialog shouldn't append ".jpeg" to the filename when the user speci...
Status: REPORTED
Alias: None
Product: plasma-integration
Classification: Plasma
Component: general (other bugs)
Version First Reported In: 5.93.0
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: qt6
Depends on:
Blocks:
 
Reported: 2024-02-17 18:56 UTC by Ilya Bizyaev
Modified: 2024-02-18 16:39 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ilya Bizyaev 2024-02-17 18:56:31 UTC
STEPS TO REPRODUCE
1. Edit a test.jpeg image in Gwenview
2. Click “Save as”
3. With the “Automatically select file extension (.jpeg)” checkbox checked, specify "cropped.jpg" as the output name

OBSERVED RESULT
The new image is saved as "cropped.jpg.jpeg".

EXPECTED RESULT
The new image should be saved as "cropped.jpg".

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20240208
KDE Plasma Version: 6.0.80
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.1
Kernel Version: 6.7.4-1-default (64-bit)
Graphics Platform: Wayland

ADDITIONAL INFORMATION
Comment 1 Shubham Arora 2024-02-18 04:57:01 UTC
I think this not a valid issue. The option for Automatically select file extension is here so the text entered in the filename is treated as a title and the the extension appended to it.  When it is unchecked the filename is treated as complete name with extension and is working as expected. 

UX can do with some improvements but functionality is intentional.
Comment 2 Ilya Bizyaev 2024-02-18 11:17:06 UTC
Well, I disagree: saving a file as “test.png” doesn't make it a “test.png.png”. The automatic extension should just be slightly smarter to recognize that “.jpg” and “.jpeg” are the same extension.
Comment 3 fanzhuyifan 2024-02-18 16:39:46 UTC
Yeah I think there might be some way it could figure that out from the MIME database, but I am not an expert on that