## Family

Family — Font family

## Functions

FontManagerFamily * | font_manager_family_new ()
gint | font_manager_family_get_default_index ()
JsonObject * | font_manager_family_get_default_variant ()

## Properties

gboolean | active | Read / Write
char * | description | Read / Write
char * | family | Read / Write
gint64 | n-variations | Read / Write
char * | preview-text | Read / Write
JsonObject * | source-object | Read / Write
JsonArray * | variations | Read / Write

## Types and Values

#define | FONT_MANAGER_TYPE_FAMILY
| FontManagerFamily

## Object Hierarchy

        GObject
        ╰── FontManagerJsonProxy
            ╰── FontManagerFamily

## Includes

    #include <font-manager-family.h>

## Description

FontManagerFamily holds information about a font family along with an array of JsonObject representing the fonts belonging to this font family.

The JsonObject backing this class should have the following structure:

    1
    2
    3
    4
    5
    6
    7

    {
      "family" : string,
      "description" : string,
      "n-variations" : int,
      "active" : bool,
      "variations" : [ ]
    }

variations is a JsonArray of JsonObjects representing individual fonts. See FontManagerFont for object description.

## Functions

### font_manager_family_new ()

    FontManagerFamily *
    font_manager_family_new (void);

#### Returns

A newly created FontManagerFamily. Free the returned object using ``g_object_unref()``.

[transfer full]

### font_manager_family_get_default_index ()

    gint
    font_manager_family_get_default_index (FontManagerFamily *self);

#### Parameters

self | FontManagerFamily |

#### Returns

index of default variant or 0

### font_manager_family_get_default_variant ()

    JsonObject *
    font_manager_family_get_default_variant
                                   (FontManagerFamily *self);

#### Parameters

self | FontManagerFamily |

#### Returns

JsonObject which should not be freed.

[transfer none]

## Types and Values

### FONT_MANAGER_TYPE_FAMILY

    #define FONT_MANAGER_TYPE_FAMILY (font_manager_family_get_type())

### FontManagerFamily

    typedef struct _FontManagerFamily FontManagerFamily;

## Property Details

### The `“active”` property

      “active”                   gboolean

Whether family is active.

Owner: FontManagerFamily

Flags: Read / Write

Default value: FALSE

### The `“description”` property

      “description”              char *

Pango font description.

Owner: FontManagerFamily

Flags: Read / Write

Default value: NULL

### The `“family”` property

      “family”                   char *

Family name.

Owner: FontManagerFamily

Flags: Read / Write

Default value: NULL

### The `“n-variations”` property

      “n-variations”             gint64

Number of font variations.

Owner: FontManagerFamily

Flags: Read / Write

Allowed values: [-2147483648,2147483647]

Default value: 0

### The `“preview-text”` property

      “preview-text”             char *

Sample text.

Owner: FontManagerFamily

Flags: Read / Write

Default value: NULL

### The `“source-object”` property

      “source-object”            JsonObject *

JsonObject source for this class.

Owner: FontManagerFamily

Flags: Read / Write

### The `“variations”` property

      “variations”               JsonArray *

JsonArray of JsonObjects.

Owner: FontManagerFamily

Flags: Read / Write

## See Also

FontManagerJsonProxy FontManagerFont