Dont do this.
imagemagick is a dependency of qubes-core-agent - until that dependency
is removed you are stuck with it.
What you want to do is change the default mime-types currently used by
imagemagick.
Many problems that people have in Qubes are actually not Qubes specific.
This is one of those.
You can find many guides online to changing the default application in
Debian, and those should help you. The only Qubes specific part is that
you have to do this in the template: for disposables you could make this
change in the disposable template.
A simple (and quick) way of doing it could be to create a file at
~/.local/share/applications/mimeapps.list (defaults.list also still works)
mkdir -p ~/.local/share/applications/
cp /usr/share/applications/mimeinfo.cache ~/.local/share/applications/defaults.list
sed -i s/display-im6.q16.desktop/ristretto.desktop/ ~/.local/share/applications/defaults.list
(I’ve assumed that the right file is ristretto.desktop)
I never presume to speak for the Qubes team.When I comment in the Forum or in the mailing lists I speak for myself.