Skip to content

Commit

Permalink
Properly add new file extensions
Browse files Browse the repository at this point in the history
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 (cd99122)
but they were erroneously left out from the filter in the Dangerzone
main window.
  • Loading branch information
apyrgio committed Feb 20, 2024
1 parent e73f10f commit 5b6911a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Dangerzone can convert these types of document into safe PDFs:
- GIF (`.gif`)
- PNG (`.png`)
- 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).

Expand Down
4 changes: 3 additions & 1 deletion dangerzone/gui/main_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,9 @@ def __init__(self, dangerzone: DangerzoneGui) -> None:
hwp_filters = ""
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)"
]
)

Expand Down

0 comments on commit 5b6911a

Please sign in to comment.