mateosss / matter

Customizable GRUB theme inspired by Material Design
Boost Software License 1.0
873 stars 51 forks source link

The convert command returned an error #44

Open aufarijaal opened 4 years ago

aufarijaal commented 4 years ago

Hello. Im running in MX Linux 19.2 patito feo. when i run matter, i got this error:


-hl bd93f8 -fg f8f8f3 -bg 282a36 \                                             
-ff /usr/share/fonts/truetype/Ubuntu/Ubuntu\ Medium\ Nerd\ Font\ Complete.ttf \
-fn Ubuntu Nerd Font -fs 32
[I] Begin Matter install
[I] Build theme from user preferences
[I] Download debian.svg
[I] Download folder.svg
[I] Download memory.svg
[I] Download microsoft-windows.svg
[I] Download cog.svg
[I] Convert icons
convert-im6.q16: no decode delegate for this image format `' @ error/constitute.c/ReadImage/560.
convert-im6.q16: unable to open image `Repos/matter/icons/debian.svg': No such file or directory @ error/blob.c/OpenBlob/2874.
convert-im6.q16: delegate failed `'rsvg-convert' -o '%o' '%i'' @ error/delegate.c/InvokeDelegate/1928.
convert-im6.q16: unable to open file `/tmp/magick-18436rdkJflvHXxwW': No such file or directory @ error/constitute.c/ReadImage/600.
convert-im6.q16: no decode delegate for this image format `' @ error/constitute.c/ReadImage/560.
convert-im6.q16: no images defined `Repos/matter/Matter/icons/debian.png' @ error/convert.c/ConvertImageCommand/3258.
[E] Stop. The convert command returned an error. ```

any help?
mateosss commented 4 years ago

It is most likely something regarding your installation of ImageMacick. How did you install it? In Ubuntu I recommend sudo apt install inkscape as inkscape already brings it with the best svg to png conversor, but I am not familiar with MX Linux.

Also it would be helpful if you run convert debian.svg debian.png and see what it outputs (you can get debian.svg from here).

aufarijaal commented 4 years ago

Thanks for your reply. ImageMagick already installed by default in my MX but not for inkscape. so I installed it from synaptic. should I reinstall imagemagick?

and the convert command that you suggest, there is no error output after converting. the exit code is 0 image sorry for my english

mateosss commented 4 years ago

Okay let's try something else. Below should be a command very similar to the one Matter issues when converting svg to png. Try running it as you did before for debian.svg. It will probably throw the same error you got before. Remove flags one by one until you find which one is the problem.

convert -trim -scale 36x36 -extent 72x72 -gravity center \
-define png:color-type=6 -background none -colorspace sRGB \
-channel RGB -threshold -1 -density 300 -fill \#ffffff +opaque none \
debian.svg debian.png

(Note: If the command does not give you errors, try running it with sudo at the start, as Matter runs it as superuser)

You could as well try reinstalling imagemagick, that may help.

Bricklou commented 4 years ago

I have the same problem but I can't find the right command to be able to generate icons. :slightly_frowning_face: It would be nice to have a fix.

mateosss commented 4 years ago

@Bricklou Are you on MX Linux 19.2 as well?

Bricklou commented 4 years ago

I use archlinux with the latests updates

Bricklou commented 4 years ago

Material Icons are rendered empty and my custom SVG just show white

mateosss commented 4 years ago

Okay, I'm unable right now to address this because of a lack of time, any help debugging the issue is welcomed. Eventually the idea is to bundle the svg conversor directly into Matter to avoid these kind of problems with ImageMagick in the future. Stay tuned.

Bricklou commented 4 years ago

Can we still use PNG files instead of SVG one ?

mateosss commented 4 years ago

Yes you could drop the PNGs inside /boot/grub/themes/Matter/icons, they should have their proper name (i.e. if you specified icon name microsoft-windows then the icon you place should be /boot/grub/themes/Matter/icons/microsoft-windows.png)

Bricklou commented 4 years ago

I found why the script bug, it seem that the fill and background argument are applied on the document and not the path of SVG files. But I don't know how to fix it. :confused:

iyyel commented 4 years ago

Same issue on Void Linux with latest updates. Latest ImageMagick and Inkscape installed.