gi-gtk-4.0.8: Gtk bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.Gtk.Objects.FontDialogButton

Description

The GtkFontDialogButton is wrapped around a FontDialog and allows to open a font chooser dialog to change the font.

It is suitable widget for selecting a font in a preference dialog.

CSS nodes

fontbutton
╰── button.font
    ╰── [content]

GtkFontDialogButton has a single CSS node with name fontbutton which contains a button node with the .font style class.

Since: 4.10

Synopsis

Exported types

newtype FontDialogButton Source #

Memory-managed wrapper type.

Constructors

FontDialogButton (ManagedPtr FontDialogButton) 

Instances

Instances details
Eq FontDialogButton Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

GObject FontDialogButton Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

ManagedPtrNewtype FontDialogButton Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

TypedObject FontDialogButton Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

Methods

glibType :: IO GType

HasParentTypes FontDialogButton Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

IsGValue (Maybe FontDialogButton) Source #

Convert FontDialogButton to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.Gtk.Objects.FontDialogButton

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe FontDialogButton -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe FontDialogButton)

type ParentTypes FontDialogButton Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

class (GObject o, IsDescendantOf FontDialogButton o) => IsFontDialogButton o Source #

Type class for types which can be safely cast to FontDialogButton, for instance with toFontDialogButton.

Instances

Instances details
(GObject o, IsDescendantOf FontDialogButton o) => IsFontDialogButton o Source # 
Instance details

Defined in GI.Gtk.Objects.FontDialogButton

toFontDialogButton :: (MonadIO m, IsFontDialogButton o) => o -> m FontDialogButton Source #

Cast to FontDialogButton, for types for which this is known to be safe. For general casts, use castTo.

Methods

Click to display all available methods, including inherited ones

Expand

Methods

actionSetEnabled, activate, activateAction, activateDefault, addController, addCssClass, addMnemonicLabel, addTickCallback, allocate, bindProperty, bindPropertyFull, childFocus, computeBounds, computeExpand, computePoint, computeTransform, contains, createPangoContext, createPangoLayout, disposeTemplate, dragCheckThreshold, errorBell, forceFloating, freezeNotify, getv, grabFocus, hasCssClass, hasDefault, hasFocus, hasVisibleFocus, hide, inDestruction, initTemplate, insertActionGroup, insertAfter, insertBefore, isAncestor, isDrawable, isFloating, isFocus, isSensitive, isVisible, keynavFailed, listMnemonicLabels, map, measure, mnemonicActivate, notify, notifyByPspec, observeChildren, observeControllers, pick, queueAllocate, queueDraw, queueResize, realize, ref, refSink, removeController, removeCssClass, removeMnemonicLabel, removeTickCallback, resetProperty, resetRelation, resetState, runDispose, shouldLayout, show, sizeAllocate, snapshotChild, stealData, stealQdata, thawNotify, translateCoordinates, triggerTooltipQuery, unmap, unparent, unrealize, unref, unsetStateFlags, updateNextAccessibleSibling, updateProperty, updateRelation, updateState, watchClosure.

Getters

getAccessibleParent, getAccessibleRole, getAllocatedBaseline, getAllocatedHeight, getAllocatedWidth, getAllocation, getAncestor, getAtContext, getBounds, getBuildableId, getCanFocus, getCanTarget, getChildVisible, getClipboard, getColor, getCssClasses, getCssName, getCursor, getData, getDialog, getDirection, getDisplay, getFirstAccessibleChild, getFirstChild, getFocusChild, getFocusOnClick, getFocusable, getFontDesc, getFontFeatures, getFontMap, getFontOptions, getFrameClock, getHalign, getHasTooltip, getHeight, getHexpand, getHexpandSet, getLanguage, getLastChild, getLayoutManager, getLevel, getMapped, getMarginBottom, getMarginEnd, getMarginStart, getMarginTop, getName, getNative, getNextAccessibleSibling, getNextSibling, getOpacity, getOverflow, getPangoContext, getParent, getPlatformState, getPreferredSize, getPrevSibling, getPrimaryClipboard, getProperty, getQdata, getRealized, getReceivesDefault, getRequestMode, getRoot, getScaleFactor, getSensitive, getSettings, getSize, getSizeRequest, getStateFlags, getStyleContext, getTemplateChild, getTooltipMarkup, getTooltipText, getUseFont, getUseSize, getValign, getVexpand, getVexpandSet, getVisible, getWidth.

Setters

setAccessibleParent, setCanFocus, setCanTarget, setChildVisible, setCssClasses, setCursor, setCursorFromName, setData, setDataFull, setDialog, setDirection, setFocusChild, setFocusOnClick, setFocusable, setFontDesc, setFontFeatures, setFontMap, setFontOptions, setHalign, setHasTooltip, setHexpand, setHexpandSet, setLanguage, setLayoutManager, setLevel, setMarginBottom, setMarginEnd, setMarginStart, setMarginTop, setName, setOpacity, setOverflow, setParent, setProperty, setReceivesDefault, setSensitive, setSizeRequest, setStateFlags, setTooltipMarkup, setTooltipText, setUseFont, setUseSize, setValign, setVexpand, setVexpandSet, setVisible.

getDialog

fontDialogButtonGetDialog Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> m (Maybe FontDialog)

Returns: the GtkFontDialog

Returns the GtkFontDialog of self.

Since: 4.10

getFontDesc

fontDialogButtonGetFontDesc Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> m (Maybe FontDescription)

Returns: the font

Returns the font of the button.

This function is what should be used to obtain the font that was chosen by the user. To get informed about changes, listen to "notifyfontDesc".

Since: 4.10

getFontFeatures

fontDialogButtonGetFontFeatures Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> m (Maybe Text)

Returns: the font features

Returns the font features of the button.

This function is what should be used to obtain the font features that were chosen by the user. To get informed about changes, listen to "notifyfontFeatures".

Note that the button will only let users choose font features if FontDialogButton:level is set to GTK_FONT_LEVEL_FEATURES.

Since: 4.10

getLanguage

fontDialogButtonGetLanguage Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> m (Maybe Language)

Returns: the language

Returns the language that is used for font features.

Since: 4.10

getLevel

fontDialogButtonGetLevel Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a `GtkFontDialogButton

-> m FontLevel

Returns: the level of detail

Returns the level of detail at which this dialog lets the user select fonts.

Since: 4.10

getUseFont

fontDialogButtonGetUseFont Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> m Bool

Returns: whether the selected font is used in the label

Returns whether the selected font is used in the label.

Since: 4.10

getUseSize

fontDialogButtonGetUseSize Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> m Bool

Returns: whether the selected font size is used in the label

Returns whether the selected font size is used in the label.

Since: 4.10

new

fontDialogButtonNew Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialog a) 
=> Maybe a

dialog: the GtkFontDialog to use

-> m FontDialogButton

Returns: the new GtkFontDialogButton

Creates a new GtkFontDialogButton with the given GtkFontDialog.

You can pass NULL to this function and set a GtkFontDialog later. The button will be insensitive until that happens.

Since: 4.10

setDialog

fontDialogButtonSetDialog Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a, IsFontDialog b) 
=> a

self: a GtkFontDialogButton

-> b

dialog: the new GtkFontDialog

-> m () 

Sets a GtkFontDialog object to use for creating the font chooser dialog that is presented when the user clicks the button.

Since: 4.10

setFontDesc

fontDialogButtonSetFontDesc Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> FontDescription

fontDesc: the new font

-> m () 

Sets the font of the button.

Since: 4.10

setFontFeatures

fontDialogButtonSetFontFeatures Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> Maybe Text

fontFeatures: the font features

-> m () 

Sets the font features of the button.

Since: 4.10

setLanguage

fontDialogButtonSetLanguage Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> Maybe Language

language: the new language

-> m () 

Sets the language to use for font features.

Since: 4.10

setLevel

fontDialogButtonSetLevel Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> FontLevel

level: the level of detail

-> m () 

Sets the level of detail at which this dialog lets the user select fonts.

Since: 4.10

setUseFont

fontDialogButtonSetUseFont Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> Bool

useFont: If TRUE, font name will be written using the chosen font

-> m () 

If useFont is TRUE, the font name will be written using the selected font.

Since: 4.10

setUseSize

fontDialogButtonSetUseSize Source #

Arguments

:: (HasCallStack, MonadIO m, IsFontDialogButton a) 
=> a

self: a GtkFontDialogButton

-> Bool

useSize: If TRUE, font name will be written using the chosen font size

-> m () 

If useSize is TRUE, the font name will be written using the selected font size.

Since: 4.10

Properties

dialog

The GtkFontDialog that contains parameters for the font chooser dialog.

Since: 4.10

constructFontDialogButtonDialog :: (IsFontDialogButton o, MonadIO m, IsFontDialog a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “dialog” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonDialog :: (MonadIO m, IsFontDialogButton o) => o -> m (Maybe FontDialog) Source #

Get the value of the “dialog” property. When overloading is enabled, this is equivalent to

get fontDialogButton #dialog

setFontDialogButtonDialog :: (MonadIO m, IsFontDialogButton o, IsFontDialog a) => o -> a -> m () Source #

Set the value of the “dialog” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #dialog := value ]

fontDesc

The selected font.

This property can be set to give the button its initial font, and it will be updated to reflect the users choice in the font chooser dialog.

Listen to notify::font-desc to get informed about changes to the buttons font.

Since: 4.10

constructFontDialogButtonFontDesc :: (IsFontDialogButton o, MonadIO m) => FontDescription -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “font-desc” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonFontDesc :: (MonadIO m, IsFontDialogButton o) => o -> m (Maybe FontDescription) Source #

Get the value of the “font-desc” property. When overloading is enabled, this is equivalent to

get fontDialogButton #fontDesc

setFontDialogButtonFontDesc :: (MonadIO m, IsFontDialogButton o) => o -> FontDescription -> m () Source #

Set the value of the “font-desc” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #fontDesc := value ]

fontFeatures

The selected font features.

This property will be updated to reflect the users choice in the font chooser dialog.

Listen to notify::font-features to get informed about changes to the buttons font features.

Since: 4.10

clearFontDialogButtonFontFeatures :: (MonadIO m, IsFontDialogButton o) => o -> m () Source #

Set the value of the “font-features” property to Nothing. When overloading is enabled, this is equivalent to

clear #fontFeatures

constructFontDialogButtonFontFeatures :: (IsFontDialogButton o, MonadIO m) => Text -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “font-features” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonFontFeatures :: (MonadIO m, IsFontDialogButton o) => o -> m (Maybe Text) Source #

Get the value of the “font-features” property. When overloading is enabled, this is equivalent to

get fontDialogButton #fontFeatures

setFontDialogButtonFontFeatures :: (MonadIO m, IsFontDialogButton o) => o -> Text -> m () Source #

Set the value of the “font-features” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #fontFeatures := value ]

language

The selected language for font features.

This property will be updated to reflect the users choice in the font chooser dialog.

Listen to notify::language to get informed about changes to the buttons language.

Since: 4.10

clearFontDialogButtonLanguage :: (MonadIO m, IsFontDialogButton o) => o -> m () Source #

Set the value of the “language” property to Nothing. When overloading is enabled, this is equivalent to

clear #language

constructFontDialogButtonLanguage :: (IsFontDialogButton o, MonadIO m) => Language -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “language” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonLanguage :: (MonadIO m, IsFontDialogButton o) => o -> m (Maybe Language) Source #

Get the value of the “language” property. When overloading is enabled, this is equivalent to

get fontDialogButton #language

setFontDialogButtonLanguage :: (MonadIO m, IsFontDialogButton o) => o -> Language -> m () Source #

Set the value of the “language” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #language := value ]

level

The level of detail for the font chooser dialog.

constructFontDialogButtonLevel :: (IsFontDialogButton o, MonadIO m) => FontLevel -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “level” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonLevel :: (MonadIO m, IsFontDialogButton o) => o -> m FontLevel Source #

Get the value of the “level” property. When overloading is enabled, this is equivalent to

get fontDialogButton #level

setFontDialogButtonLevel :: (MonadIO m, IsFontDialogButton o) => o -> FontLevel -> m () Source #

Set the value of the “level” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #level := value ]

useFont

Whether the buttons label will be drawn in the selected font.

constructFontDialogButtonUseFont :: (IsFontDialogButton o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “use-font” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonUseFont :: (MonadIO m, IsFontDialogButton o) => o -> m Bool Source #

Get the value of the “use-font” property. When overloading is enabled, this is equivalent to

get fontDialogButton #useFont

setFontDialogButtonUseFont :: (MonadIO m, IsFontDialogButton o) => o -> Bool -> m () Source #

Set the value of the “use-font” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #useFont := value ]

useSize

Whether the buttons label will use the selected font size.

constructFontDialogButtonUseSize :: (IsFontDialogButton o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “use-size” property. This is rarely needed directly, but it is used by new.

getFontDialogButtonUseSize :: (MonadIO m, IsFontDialogButton o) => o -> m Bool Source #

Get the value of the “use-size” property. When overloading is enabled, this is equivalent to

get fontDialogButton #useSize

setFontDialogButtonUseSize :: (MonadIO m, IsFontDialogButton o) => o -> Bool -> m () Source #

Set the value of the “use-size” property. When overloading is enabled, this is equivalent to

set fontDialogButton [ #useSize := value ]