## Preview Pane

Preview Pane — Preview pane widget

## Functions

const gchar * | font_manager_preview_pane_page_to_string ()
GtkWidget * | font_manager_preview_pane_new ()
gboolean | font_manager_preview_pane_show_uri ()
void | font_manager_preview_pane_set_font ()
void | font_manager_preview_pane_set_orthography ()
void | font_manager_preview_pane_set_waterfall_size ()
void | font_manager_preview_pane_restore_state ()
void | font_manager_preview_pane_add_action_widget ()

## Properties

double | character-map-preview-size | Read / Write
FontManagerFont * | font | Read / Write
int | line-spacing | Read / Write
FontManagerOrthography * | orthography | Write
int | page | Read / Write
FontManagerPreviewPageMode | preview-mode | Read / Write
double | preview-size | Read / Write
char * | preview-text | Read / Write
gboolean | show-line-size | Read / Write

## Signals

void | changed | Run First

## Types and Values

#define | FONT_MANAGER_TYPE_PREVIEW_PANE_PAGE
#define | FONT_MANAGER_TYPE_PREVIEW_PANE
| FontManagerPreviewPane

## Object Hierarchy

        GEnum
        ╰── FontManagerPreviewPanePage
        GObject
        ╰── GInitiallyUnowned
            ╰── GtkWidget
                ╰── FontManagerPreviewPane

## Implemented Interfaces

FontManagerPreviewPane implements GtkAccessible, GtkBuildable and GtkConstraintTarget.

## Includes

    #include <font-manager-preview-pane.h>

## Description

Full featured font preview widget.

This widget combines several other widgets to provide as much information about a particular font file as possible, previews, provided characters, basic file properties and license information (if available).

## Functions

### font_manager_preview_pane_page_to_string ()

    const gchar *
    font_manager_preview_pane_page_to_string
                                   (FontManagerPreviewPanePage page);

#### Parameters

page | FontManagerPreviewPanePage |

#### Returns

`page` as a string.

[transfer none][nullable]

### font_manager_preview_pane_new ()

    GtkWidget *
    font_manager_preview_pane_new (void);

#### Returns

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

[transfer full]

### font_manager_preview_pane_show_uri ()

    gboolean
    font_manager_preview_pane_show_uri (FontManagerPreviewPane *self,
                                        const gchar *uri);

### font_manager_preview_pane_set_font ()

    void
    font_manager_preview_pane_set_font (FontManagerPreviewPane *self,
                                        FontManagerFont *font);

#### Parameters

self | FontManagerPreviewPane |
font | FontManagerFont |

### font_manager_preview_pane_set_orthography ()

    void
    font_manager_preview_pane_set_orthography
                                   (FontManagerPreviewPane *self,
                                    FontManagerOrthography *orthography);

Filter character map using provided `orthography`

#### Parameters

self | FontManagerPreviewPane |
orthography | FontManagerOrthography. | [transfer none][nullable]

### font_manager_preview_pane_set_waterfall_size ()

    void
    font_manager_preview_pane_set_waterfall_size
                                   (FontManagerPreviewPane *self,
                                    gdouble min_size,
                                    gdouble max_size,
                                    gdouble ratio);

#### Parameters

self | FontManagerFontPreview |
min_size | Minimum point size to use for waterfall previews. (-1.0 to keep current) |
max_size | Maximum size to use for waterfall previews. (-1.0 to keep current) |
ratio | Waterfall point size common ratio. (-1.0 to keep current) |

### font_manager_preview_pane_restore_state ()

    void
    font_manager_preview_pane_restore_state
                                   (FontManagerPreviewPane *self,
                                    GSettings *settings);

Applies the values in `settings` to `self` and also binds those settings to their respective properties so that they are updated when any changes take place.

The following keys MUST be present in `settings` :

- preview-text

- preview-mode

- preview-page

- preview-font-size

- charmap-font-size

- preview-font-size

- preview-mode

- preview-text

- show-line-size

- min-waterfall-size

- max-waterfall-size

- waterfall-size-ratio

- charmap-font-size

- waterfall-line-spacing

#### Parameters

self | FontManagerPreviewPage |
settings | GSettings |

### font_manager_preview_pane_add_action_widget ()

    void
    font_manager_preview_pane_add_action_widget
                                   (FontManagerPreviewPane *self,
                                    GtkWidget *widget,
                                    GtkPackType pack_type);

#### Parameters

self | FontManagerFontPreview |
widget | GtkWidget to add as an action widget |
pack_type | GtkPackType |

## Types and Values

### FONT_MANAGER_TYPE_PREVIEW_PANE_PAGE

    #define FONT_MANAGER_TYPE_PREVIEW_PANE_PAGE (font_manager_preview_pane_page_get_type ())

### FONT_MANAGER_TYPE_PREVIEW_PANE

    #define FONT_MANAGER_TYPE_PREVIEW_PANE (font_manager_preview_pane_get_type ())

### FontManagerPreviewPane

    typedef struct _FontManagerPreviewPane FontManagerPreviewPane;

## Property Details

### The `“character-map-preview-size”` property

      “character-map-preview-size” double

Size to use for font in character map.

Owner: FontManagerPreviewPane

Flags: Read / Write

Allowed values: [6,96]

Default value: 16

### The `“font”` property

      “font”                     FontManagerFont *

FontManagerFont to display.

Owner: FontManagerPreviewPane

Flags: Read / Write

### The `“line-spacing”` property

      “line-spacing”             int

Pixels between lines in Waterfall preview.

Owner: FontManagerPreviewPane

Flags: Read / Write

Allowed values: >= 0

Default value: 0

### The `“orthography”` property

      “orthography”              FontManagerOrthography *

FontManagerOrthography to display in character map.

Owner: FontManagerPreviewPane

Flags: Write

### The `“page”` property

      “page”                     int

Current page number.

Owner: FontManagerPreviewPane

Flags: Read / Write

Allowed values: [0,3]

Default value: 0

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

      “preview-mode”             FontManagerPreviewPageMode

Preview mode.

Owner: FontManagerPreviewPane

Flags: Read / Write

Default value: FONT_MANAGER_PREVIEW_PAGE_MODE_WATERFALL

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

      “preview-size”             double

Size to use for font in preview mode.

Owner: FontManagerPreviewPane

Flags: Read / Write

Allowed values: [6,96]

Default value: 10

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

      “preview-text”             char *

Text to display in interactive preview mode.

Owner: FontManagerPreviewPane

Flags: Read / Write

Default value: NULL

### The `“show-line-size”` property

      “show-line-size”           gboolean

Whether to display Waterfall preview line size.

Owner: FontManagerPreviewPane

Flags: Read / Write

Default value: TRUE

## Signal Details

### The `“changed”` signal

    void
    user_function (FontManagerPreviewPane *fontmanagerpreviewpane,
                   gpointer                user_data)

Emitted whenever the the preview is updated.

#### Parameters

user_data | user data set when the signal handler was connected. |

Flags: Run First