Top | ![]() |
![]() |
![]() |
![]() |
enum | FontManagerFontconfigError |
#define | FONT_MANAGER_FONTCONFIG_ERROR |
enum | FontManagerWeight |
#define | FONT_MANAGER_TYPE_WEIGHT |
enum | FontManagerSlant |
#define | FONT_MANAGER_TYPE_SLANT |
enum | FontManagerWidth |
#define | FONT_MANAGER_TYPE_WIDTH |
enum | FontManagerSpacing |
#define | FONT_MANAGER_TYPE_SPACING |
enum | FontManagerSubpixelOrder |
#define | FONT_MANAGER_TYPE_SUBPIXEL_ORDER |
enum | FontManagerHintStyle |
#define | FONT_MANAGER_TYPE_HINT_STYLE |
enum | FontManagerLCDFilter |
#define | FONT_MANAGER_TYPE_LCD_FILTER |
GEnum ├── FontManagerHintStyle ├── FontManagerLCDFilter ├── FontManagerSlant ├── FontManagerSpacing ├── FontManagerSubpixelOrder ├── FontManagerWeight ╰── FontManagerWidth
void
font_manager_clear_application_fonts (void
);
Equivalent to FcConfigAppFontClear
gboolean
font_manager_add_application_font (const gchar *filepath
);
Equivalent to FcConfigAppFontAddFile
gboolean
font_manager_add_application_font_directory
(const gchar *dir
);
Equivalent to FcConfigAppFontAddDir
FontManagerStringSet *
font_manager_list_available_font_families
(void
);
a newly created FontManagerStringSet containing filepaths or NULL
.
Free the returned object using g_object_unref.
[transfer full][nullable]
GList *
font_manager_get_langs_from_fontconfig_pattern
(FcPattern *pattern
);
Supplied FcPattern must contain an FcLangSet.
[skip]
JsonObject * font_manager_get_attributes_from_filepath (const gchar *filepath
,GError **error
);
See FontManagerFamily for a description of the JsonObject returned by this function.
JsonObject *
font_manager_get_attributes_from_fontconfig_pattern
(FcPattern *pattern
);
The supplied FcPattern must supply file and family information, otherwise this function will fail. It is also expected to contain index, style, slant, weight, width, language, character set and spacing information, however default values will be used if those fields are missing. All other fields are ignored.
See FontManagerFont for a description of the JsonObject returned by this function.
[skip]
JsonObject *
font_manager_get_available_fonts (const gchar *family_name
);
If family_name
is not NULL
, only information for fonts belonging to
specified family will be returned.
The returned JsonObject will have the following structure:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
{ "family" : { "variation" : { "filepath" : string, "findex" : int, "family" : string, "style" : string, "spacing" : int, "slant" : int, "weight" : int, "width" : int, "description" : string, }, ... }, ... } |
JsonObject *
font_manager_get_available_fonts_for_chars
(const gchar *chars
);
See font_manager_get_available_fonts for a description of the JsonObject returned by this function.
The returned object will only contain those fonts which contain all
the characters in chars
.
JsonArray *
font_manager_sort_json_font_listing (JsonObject *json_obj
);
The returned JsonArray has the following structure:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
[ { "family" : string, "n_variations" : int, "variations" : [ { "filepath" : string, "findex" : int, "family" : string, "style" : string, "spacing" : int, "slant" : int, "weight" : int, "width" : int, "description" : string, }, ... ], "active" : bool, "description" : string, }, ... ] |
const gchar *
font_manager_weight_to_string (FontManagerWeight weight
);
const gchar *
font_manager_slant_to_string (FontManagerSlant slant
);
const gchar *
font_manager_width_to_string (FontManagerWidth width
);
const gchar *
font_manager_spacing_to_string (FontManagerSpacing spacing
);
const gchar *
font_manager_subpixel_order_to_string (FontManagerSubpixelOrder rgba
);
const gchar *
font_manager_hint_style_to_string (FontManagerHintStyle hinting
);
const gchar *
font_manager_lcd_filter_to_string (FontManagerLCDFilter filter
);
#define FONT_MANAGER_FONTCONFIG_ERROR font_manager_fontconfig_error_quark()
These weight values map directly to those defined by Fontconfig.
These widths map directly to those defined by Fontconfig.
#define FONT_MANAGER_TYPE_SUBPIXEL_ORDER (font_manager_subpixel_order_get_type ())
#define FONT_MANAGER_TYPE_HINT_STYLE (font_manager_hint_style_get_type ())
FontManagerFont FontManagerFamily https://www.freedesktop.org/software/fontconfig/fontconfig-devel/