• Tomaž Vajngerl's avatar
    tdf#51733 support SVG icon theme, disk cache and scaling / darken · 5bb5463e
    Tomaž Vajngerl yazdı
    Also resolves tdf#92248
    
    This extends icon name resolving so that is in addition tries to
    find an icon with the "svg" extension and load that instead of
    stated (mostly "png") extension. If the filename extension is
    "svg" we load the icon with the SVG filter instead.
    
    This also adds icon scaling and conversion for HiDPI or when a
    dark theme is wanted. If the SVG icon is available, we render it
    at a higher resolution instead of scaling
    
    As loading of SVG icons can be computatunally expensive, a icon
    disk cache was added. This saves the rendered SVG as a PNG image
    into the "cache" folder. The same caching is also used for HiDPI
    and dark theme converted icons so we don't always scale or
    convert the icons.
    
    In addition some style changes and DRY fixes were made to the
    ImplImageTree source code.
    
    Change-Id: I9e421395a342ffe8da9facea7ea06e5db2778b26
    Reviewed-on: https://gerrit.libreoffice.org/30339Reviewed-by: 's avatarTomaž Vajngerl <quikee@gmail.com>
    Tested-by: 's avatarTomaž Vajngerl <quikee@gmail.com>
    5bb5463e
implimagetree.hxx 4.5 KB