https://bugs.kde.org/show_bug.cgi?id=491795

--- Comment #16 from Mirco Miranda <[email protected]> ---
I created a script in Gimp 3 to convert the XCF to PNG under Windows. I tested
it with jun16-3-color2alpha-bug-fx.xcf and it worked.
We could modify the plugin so that, if it fails to load, it tries to run the
conversion with gimp-console and then load the PNG file. We already do
something similar with the EPS plugin (it uses Ghostscript). Obviously, you
need to have GIMP installed.

It's not an ideal solution, but it's better than nothing...

=== START BAT ===

@echo off
title Converting XCF → PNG...
set "GIMP_PATH=C:\Users\Programs Files\GIMP 3\bin\gimp-console.exe"

:: Process all XCF files in the folder
for %%f in (*.xcf) do (
    if exist "%%f" (
        echo.
        echo Processing: %%f
        "%GIMP_PATH%" -i --batch-interpreter=plug-in-script-fu-eval -b "(let*
((image (car (gimp-file-load RUN-NONINTERACTIVE \"%%f\" \"%%f\"))) )
(file-png-export RUN-NONINTERACTIVE image \"%%~nf.png\")) (gimp-quit 0)"
        if errorlevel 1 (
            echo ERROR during conversion of %%f
        ) else (
            echo Converted to: %%~nf.png
        )
    )
)

echo.
echo ==============================
echo  CONVERSION COMPLETED!
echo  PNG files were created in the same folder of XCF ones.
echo ==============================

=== END BAT ===

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to