17 #include <pango/pango-layout.h>
Helper class to encapsulate the management of a PangoAttrList.
void splice_into(PangoAttrList *target) const
attribute_list & operator=(const attribute_list &)=delete
void modify(PangoAttribute *attr)
void apply_to(PangoLayout *layout) const
void insert(PangoAttribute *attr)
attribute_list(const attribute_list &)=delete
PangoAttrList * attributes_
family_class
Font classes for get_font_families().
void add_attribute_size(attribute_list &list, unsigned offset_start, unsigned offset_end, int size)
Add Pango font size attribute to a specific portion of text.
void add_attribute_bg_color(attribute_list &list, unsigned offset_start, unsigned offset_end, const color_t &color)
Mark a specific portion of text for highlighting.
void add_attribute_weight(attribute_list &list, unsigned offset_start, unsigned offset_end, PangoWeight weight)
Add Pango font weight attribute to a specific portion of text.
void add_attribute_underline(attribute_list &list, unsigned offset_start, unsigned offset_end, PangoUnderline underline)
Add Pango underline attribute to a specific portion of text.
void add_attribute_font_family(attribute_list &list, unsigned offset_start, unsigned offset_end, font::family_class family)
Add Pango font family attribute to a specific portion of text.
void add_attribute_style(attribute_list &list, unsigned offset_start, unsigned offset_end, PangoStyle style)
Add Pango font style attribute to a specific portion of text, used to set italic/oblique text.
void add_attribute_fg_color(attribute_list &list, unsigned offset_start, unsigned offset_end, const color_t &color)
Add Pango fg color attribute to a specific portion of text.
std::size_t size(std::string_view str)
Length in characters of a UTF-8 string.
The basic class for representing 8-bit RGB or RGBA colour values.