Properly add new file extensions

Accept `.svg` and `.bmp` files when browsing via the Dangerzone GUI.
Support for these extensions has already been added in the converter
code that runs in the sandbox (cd99122385)
but they were erroneously left out from the filter in the Dangerzone
main window.
This commit is contained in:
Alex Pyrgiotis 2024-02-20 13:14:22 +02:00
parent e73f10f99b
commit 5b6911af84
No known key found for this signature in database
GPG key ID: B6C15EBA0357C9AA
2 changed files with 4 additions and 2 deletions

View file

@ -59,7 +59,7 @@ Dangerzone can convert these types of document into safe PDFs:
- GIF (`.gif`) - GIF (`.gif`)
- PNG (`.png`) - PNG (`.png`)
- SVG (`.svg`) - SVG (`.svg`)
- other image formats (`.bmp`, `.pnm`, `pbm`, `ppm`) - other image formats (`.bmp`, `.pnm`, `.pbm`, `.ppm`)
Dangerzone was inspired by [Qubes trusted PDF](https://blog.invisiblethings.org/2013/02/21/converting-untrusted-pdfs-into-trusted.html), but it works in non-Qubes operating systems. It uses containers as sandboxes instead of virtual machines (using Docker for macOS and Windows, and [podman](https://podman.io/) on Linux). Dangerzone was inspired by [Qubes trusted PDF](https://blog.invisiblethings.org/2013/02/21/converting-untrusted-pdfs-into-trusted.html), but it works in non-Qubes operating systems. It uses containers as sandboxes instead of virtual machines (using Docker for macOS and Windows, and [podman](https://podman.io/) on Linux).

View file

@ -562,7 +562,9 @@ class DocSelectionWidget(QtWidgets.QWidget):
hwp_filters = "" hwp_filters = ""
self.file_dialog.setNameFilters( self.file_dialog.setNameFilters(
[ [
f"Documents (*.pdf *.docx *.doc *.docm *.xlsx *.xls *.pptx *.ppt *.odt *.odg *.odp *.ods {hwp_filters} *.epub *.jpg *.jpeg *.gif *.png *.tif *.tiff *.bpm *.pnm *.pbm *.ppm)" "Documents (*.pdf *.docx *.doc *.docm *.xlsx *.xls *.pptx *.ppt *.odt"
f" *.odg *.odp *.ods {hwp_filters} *.epub *.jpg *.jpeg *.gif *.png"
" *.tif *.tiff *.bmp *.pnm *.pbm *.ppm *.svg)"
] ]
) )