Debian Codegraph @

lib/json/font-manager-family.h

raw
1 /* font-manager-family.h
2 *
3 * Copyright (C) 2009-2024 Jerry Casiano
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program.
17 *
18 * If not, see <http://www.gnu.org/licenses/gpl-3.0.txt>.
19 */
20
21 #pragma once
22
23 #include "font-manager-json-proxy.h"
24
25 static const FontManagerJsonProxyProperty FamilyProperties [] =
26 {
27 { "RESERVED", G_TYPE_RESERVED_GLIB_FIRST, NULL },
28 { "family", G_TYPE_STRING, "Family name" },
29 { "n-variations", G_TYPE_INT64, "Number of font variations" },
30 { "active", G_TYPE_BOOLEAN, "Whether family is active"},
31 { "description", G_TYPE_STRING, "Pango font description" },
32 { "preview-text", G_TYPE_STRING, "Sample text" },
33 { FONT_MANAGER_JSON_PROXY_SOURCE, G_TYPE_RESERVED_USER_FIRST, "JsonObject source for this class" },
34 { "variations", G_TYPE_BOXED, "JsonArray of JsonObjects" }
35 };
36
37 #define FONT_MANAGER_TYPE_FAMILY (font_manager_family_get_type())
38 G_DECLARE_FINAL_TYPE(FontManagerFamily, font_manager_family, FONT_MANAGER, FAMILY, FontManagerJsonProxy)
39
40 FontManagerFamily * font_manager_family_new (void);
41 gint font_manager_family_get_default_index (FontManagerFamily *self);
42 JsonObject * font_manager_family_get_default_variant (FontManagerFamily *self);
43