| 1 |
/* font-manager-freetype.h |
| 2 |
* |
| 3 |
* Copyright (C) 2009-2025 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 <glib.h> |
| 24 |
#include <glib-object.h> |
| 25 |
#include <glib/gprintf.h> |
| 26 |
#include <glib/gstdio.h> |
| 27 |
#include <glib/gi18n-lib.h> |
| 28 |
#include <json-glib/json-glib.h> |
| 29 |
|
| 30 |
#include <ft2build.h> |
| 31 |
#include FT_FREETYPE_H |
| 32 |
#include FT_TYPES_H |
| 33 |
#include FT_BDF_H |
| 34 |
#include FT_SFNT_NAMES_H |
| 35 |
#include FT_TRUETYPE_IDS_H |
| 36 |
#include FT_TRUETYPE_TABLES_H |
| 37 |
#include FT_TYPE1_TABLES_H |
| 38 |
#include FT_XFREE86_H |
| 39 |
#include FT_MULTIPLE_MASTERS_H |
| 40 |
|
| 41 |
#include "font-manager-license.h" |
| 42 |
#include "font-manager-utils.h" |
| 43 |
#include "font-manager-vendor.h" |
| 44 |
|
| 45 |
GQuark font_manager_freetype_error_quark (); |
| 46 |
#define FONT_MANAGER_FREETYPE_ERROR font_manager_freetype_error_quark() |
| 47 |
|
| 48 |
/** |
| 49 |
* FontManagerFreetypeError: |
| 50 |
* @FONT_MANAGER_FREETYPE_ERROR_FAILED: Call to Freetype library failed |
| 51 |
*/ |
| 52 |
typedef enum |
| 53 |
{ |
| 54 |
FONT_MANAGER_FREETYPE_ERROR_FAILED |
| 55 |
} |
| 56 |
FontManagerFreetypeError; |
| 57 |
|
| 58 |
glong font_manager_get_face_count (const gchar * filepath, GError **error); |
| 59 |
gfloat font_manager_get_font_revision (const gchar *filepath); |
| 60 |
|
| 61 |
JsonObject * font_manager_get_metadata (const gchar *filepath, |
| 62 |
gint index, |
| 63 |
GError **error); |
| 64 |
|
| 65 |
gchar * font_manager_get_suggested_filename (JsonObject *metadata); |
| 66 |
|
| 67 |
GFile * font_manager_get_installation_target (GFile *font_file, |
| 68 |
GFile *target_dir, |
| 69 |
gboolean create_directories, |
| 70 |
GError **error); |
| 71 |
|