20#ifndef INCLUDED_VCL_INC_IMPLIMAGETREE_HXX
21#define INCLUDED_VCL_INC_IMPLIMAGETREE_HXX
26#include <unordered_map>
30#include <com/sun/star/uno/Reference.hxx>
31#include <rtl/ustring.hxx>
76 OUString
const &
name, OUString
const & style, OUString
const & lang);
79 OUString
const & rStyle, OUString
const & rLang);
82 OUString
const & rName, OUString
const & rStyle, OUString
const & rLang);
85 OUString
const &
name, OUString
const & style,
88 sal_Int32 nScalePercentage = -1);
95 css::uno::Reference< css::container::XNameAccess >
const &
getNameAccess();
101 typedef std::unordered_map<OUString, std::pair<bool,BitmapEx>>
IconCache;
142 void setStyle(OUString
const & rStyle);
154 void parseLinkFile(std::shared_ptr<SvStream>
const & aStream);
std::unordered_map< OUString, OUString > IconLinkHash
std::shared_ptr< SvMemoryStream > getImageStream(OUString const &rName, OUString const &rStyle, OUString const &rLang)
bool iconCacheLookup(ImageRequestParameters &rParameters)
OUString getImageUrl(OUString const &name, OUString const &style, OUString const &lang)
ImplImageTree(const ImplImageTree &)=delete
bool doLoadImage(ImageRequestParameters &rParameters)
OUString maCurrentStyle
Style used for the current operations; switches switch several times during fallback search.
std::unordered_map< sal_Int32, IconCache > ScaledIconCache
void shutdown()
a crude form of life cycle control (called from DeInitVCL; otherwise, if the ImplImageTree singleton ...
OUString const & getRealImageName(OUString const &rName)
Return name of a real .png according to links.txt.
std::vector< OUString > getPaths(OUString const &name, LanguageTag const &rLanguageTag)
std::unordered_map< OUString, IconSet > maIconSets
Remember all the (used) icon styles and individual icons in them.
ImplImageTree & operator=(const ImplImageTree &)=delete
IconSet & getCurrentIconSet()
css::uno::Reference< css::container::XNameAccess > const & getNameAccess()
IconCache & getIconCache(const ImageRequestParameters &rParameters)
Find an icon cache for the right scale factor.
static OUString fallbackStyle(std::u16string_view rStyle)
Return name of the fallback style for the provided one.
css::uno::Reference< css::io::XInputStream > getImageXInputStream(OUString const &rName, OUString const &rStyle, OUString const &rLang)
std::unordered_map< OUString, std::pair< bool, BitmapEx > > IconCache
bool loadImage(OUString const &name, OUString const &style, BitmapEx &bitmap, bool localized, const ImageLoadFlags eFlags, sal_Int32 nScalePercentage=-1)
void setStyle(OUString const &rStyle)
bool findImage(std::vector< OUString > const &rPaths, ImageRequestParameters &rParameters)
void parseLinkFile(std::shared_ptr< SvStream > const &aStream)
sal_Int32 scalePercentage()
bool convertToDarkTheme()
sal_Int32 mnScalePercentage
ImageRequestParameters(OUString aName, OUString aStyle, BitmapEx &rBitmap, bool bLocalized, ImageLoadFlags eFlags, sal_Int32 nScalePercentage)
ScaledIconCache maScaledIconCaches
css::uno::Reference< css::container::XNameAccess > maNameAccess