3

I have installed inkscape on Ubuntu 20.04.

The version of inkscape is

inkscape -V

Gtk-Message: 20:38:33.029: Failed to load module "canberra-gtk-module" Gtk-Message: 20:38:33.030: Failed to load module "canberra-gtk-module" Inkscape 1.3.2 (9e3d6414e7, 2024-01-14, custom)

I want to convert an svg file into png. The problem is when I give a relative path to inkscape, instead of interpreting the path as relative, it is interpreted as relative to the home folder:

inkscape ./mydrawing.svg --export-area-drawing --batch-process --export-type=pdf

gives

Gtk-Message: 20:42:58.054: Failed to load module "canberra-gtk-module"
Gtk-Message: 20:42:58.056: Failed to load module "canberra-gtk-module"

** (org.inkscape.Inkscape:175089): WARNING **: 20:42:58.388: Can't open file: /home/myhome/mydrawing.svg (doesn't exist)

** (org.inkscape.Inkscape:175089): WARNING **: 20:42:58.388: Can't open file: /home/myhome/mydrawing.svg (doesn't exist) ink_file_open: '/home/myhome/mydrawing.svg' cannot be opened! InkscapeApplication::document_open: Failed to open: /home/myhome/mydrawing.svg ConcreteInkscapeApplication::on_open: failed to create document!

hence, it cannot open the file.

Regarding to the error:

Failed to load module "canberra-gtk-module"

I tried these solution

sudo apt-get install libcanberra-gtk-module:i386
sudo apt install -s --reinstall libcanberra-gtk-module
sudo apt install libcanberra-gtk-module libcanberra-gtk3-module

as well as all solutions provided at this question and none of them worked. I am not sure if this warning is causing this problem.


type -a inkscape ; ls -l /etc/apt/sources.list.d
inkscape is /snap/bin/inkscape
total 0

Version 1.3.1 is a stable version:

snap list inkscape  --all
Name      Version                           Rev    Tracking       Publisher  Notes
inkscape  1.3.2-9e3d6414e7-2024-01-14-cust  10563  latest/stable  inkscape✓  disabled
inkscape  1.3.1-9b9bdc1480-2023-11-25-cust  10555  latest/stable  inkscape✓  -

I also tried:

snap refresh --stable inkscape
inkscape 1.3.1-9b9bdc1480-2023-11-25-cust from Inkscape Project (inkscape✓) refreshed

muru
  • 207,228
barej
  • 322
  • 1
  • 3
  • 12

1 Answers1

1

Thanks to Daniel T.

This is an issue on inkscape 1.3.1.

I submitted a bug report for now. I might not have time to follow it up.

For now, I use the Inkscape-091e20e-x86_64.AppImage (version 1.3.2) at inkscape.org and it works fine.

barej
  • 322
  • 1
  • 3
  • 12