37 const std::optional<ImageContent>& content = std::nullopt);
43 const std::optional<ImageContent>& content = std::nullopt)
44 :
Image(std::move(
id), std::move(
image), pixelRatio,
false, std::move(stretchX), std::move(stretchY), content) {
bool operator==(const ImageContent &rhs) const
const std::optional< ImageContent > & getContent() const
The space where text can be fit into this image.
const PremultipliedImage & getImage() const
const ImageStretches & getStretchX() const
Stretch area of this image.
std::string getID() const
bool isSdf() const
Whether this image should be interpreted as a signed distance field icon.
Image(Immutable< Impl > baseImpl_)
Image(std::string id, PremultipliedImage &&, float pixelRatio, bool sdf, ImageStretches stretchX={}, ImageStretches stretchY={}, const std::optional< ImageContent > &content=std::nullopt)
Image(std::string id, PremultipliedImage &&image, float pixelRatio, ImageStretches stretchX={}, ImageStretches stretchY={}, const std::optional< ImageContent > &content=std::nullopt)
float getPixelRatio() const
Pixel ratio of the sprite image.
const ImageStretches & getStretchY() const
Stretch area of this image.
Immutable< Impl > baseImpl
std::unique_ptr< Expression > image(const char *value)
std::unique_ptr< Expression > string(std::unique_ptr< Expression >, std::unique_ptr< Expression > def=nullptr)
std::vector< ImageStretch > ImageStretches
std::pair< float, float > ImageStretch