On 06/22/2017 01:55 PM, Paul A. Rubin wrote:
On 06/22/2017 12:13 PM, Cris Fuhrman wrote:

While debugging some issues with SVG converters, I'm a bit confused now. I had configured an SVG -> PNG conversion rule in my preferences, hoping to control the tool that will visualize my SVG images when editing in LyX. Sadly, it seems that LyX is not applying the rule anymore. Here's the message log info:

    graphics/GraphicsCacheItem.cpp (416): Converting it to format.

    Format.cpp (393): filetools(getFormatFromContents)

    Couldn't find a known format!

    Format.cpp (504): will guess format from file extension: svg -> svg

    graphics/GraphicsCacheItem.cpp (386):
    [CacheItem::Impl::convertToDisplayFormat]

    Attempting to convert image file: C:/REDACTED.svg

    with displayed filename: C:/REDACTED.svg

    Format.cpp (393): filetools(getFormatFromContents)

    Couldn't find a known format!

    Format.cpp (504): will guess format from file extension: svg -> svg

    graphics/GraphicsCacheItem.cpp (393):

    The file contains svg format data.

    graphics/GraphicsCacheItem.cpp (398): No conversion needed (from
    == to)!

    graphics/GraphicsCacheItem.cpp (295): Loading image.

    graphics/GraphicsCacheItem.cpp (301): Image loading succeeded.


I just checked with LyX 2.2.3 on Linux Mint, and the same thing happens to me (minus the part about Inkscape, which I do not have installed). LyX claims to have the ability to display SVG files directly, says it's doing a non-conversion (from == to) and then can't convert the file.

I'd be inclined to suspect a missing library, but I have libqt4-svg and libqt4-svg:i386 installed, along with a half-dozen other SVG libraries. That said, GIMP shows my test file as a blank canvas, and the default image viewer will not load it.
Okay, I partially retract what I said. I don't have a lot of SVG files lying around, and the first ones I tested (all from the same source) generated exactly the same error messages Cris reported.

Just now, though, I tried a few others I tracked down on my drive, including some .svgz files provided by LyX (in /usr/share/lyx/images on Linux systems) and the only .svg file I could find from LyX (/usr/share/lyx/doc/clipart/SVG-Drawing.svg). They all worked fine, as did a non-LyX SVG file I found in one of my folders.

So apparently there's something "off" about the SVG files that caused LyX to spit up the error messages, and maybe there is similarly something different about Cris's images.

Paul

Reply via email to