| Copyright | Will Thompson, Iñaki García Etxebarria and Jonas Platte |
|---|---|
| License | LGPL-2.1 |
| Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
| Safe Haskell | None |
| Language | Haskell2010 |
GI.Gtk.Objects.ThemingEngine
Contents
Description
ThemingEngine was the object used for rendering themed content
in GTK+ widgets. It used to allow overriding GTK+'s default
implementation of rendering functions by allowing engines to be
loaded as modules.
ThemingEngine has been deprecated in GTK+ 3.14 and will be
ignored for rendering. The advancements in CSS theming are good
enough to allow themers to achieve their goals without the need
to modify source code.
- newtype ThemingEngine = ThemingEngine (ManagedPtr ThemingEngine)
- class GObject o => IsThemingEngine o
- toThemingEngine :: IsThemingEngine o => o -> IO ThemingEngine
- noThemingEngine :: Maybe ThemingEngine
- data ThemingEngineGetBackgroundColorMethodInfo
- themingEngineGetBackgroundColor :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m RGBA
- data ThemingEngineGetBorderMethodInfo
- themingEngineGetBorder :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m Border
- data ThemingEngineGetBorderColorMethodInfo
- themingEngineGetBorderColor :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m RGBA
- data ThemingEngineGetColorMethodInfo
- themingEngineGetColor :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m RGBA
- data ThemingEngineGetDirectionMethodInfo
- themingEngineGetDirection :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> m TextDirection
- data ThemingEngineGetFontMethodInfo
- themingEngineGetFont :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m FontDescription
- data ThemingEngineGetJunctionSidesMethodInfo
- themingEngineGetJunctionSides :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> m [JunctionSides]
- data ThemingEngineGetMarginMethodInfo
- themingEngineGetMargin :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m Border
- data ThemingEngineGetPaddingMethodInfo
- themingEngineGetPadding :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> [StateFlags] -> m Border
- data ThemingEngineGetPathMethodInfo
- themingEngineGetPath :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> m WidgetPath
- data ThemingEngineGetPropertyMethodInfo
- themingEngineGetProperty :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> Text -> [StateFlags] -> m GValue
- data ThemingEngineGetScreenMethodInfo
- themingEngineGetScreen :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> m (Maybe Screen)
- data ThemingEngineGetStateMethodInfo
- themingEngineGetState :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> m [StateFlags]
- data ThemingEngineGetStylePropertyMethodInfo
- themingEngineGetStyleProperty :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> Text -> m GValue
- data ThemingEngineHasClassMethodInfo
- themingEngineHasClass :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> Text -> m Bool
- data ThemingEngineHasRegionMethodInfo
- themingEngineHasRegion :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> Text -> m (Bool, [RegionFlags])
- themingEngineLoad :: (HasCallStack, MonadIO m) => Text -> m (Maybe ThemingEngine)
- data ThemingEngineLookupColorMethodInfo
- themingEngineLookupColor :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> Text -> m (Bool, RGBA)
- data ThemingEngineStateIsRunningMethodInfo
- themingEngineStateIsRunning :: (HasCallStack, MonadIO m, IsThemingEngine a) => a -> StateType -> m (Bool, Double)
- data ThemingEngineNamePropertyInfo
- constructThemingEngineName :: IsThemingEngine o => Text -> IO (GValueConstruct o)
- getThemingEngineName :: (MonadIO m, IsThemingEngine o) => o -> m (Maybe Text)
- themingEngineName :: AttrLabelProxy "name"
Exported types
newtype ThemingEngine Source #
Constructors
| ThemingEngine (ManagedPtr ThemingEngine) |
Instances
| GObject ThemingEngine Source # | |
| IsObject ThemingEngine Source # | |
| IsThemingEngine ThemingEngine Source # | |
| ((~) * info (ResolveThemingEngineMethod t ThemingEngine), MethodInfo * info ThemingEngine p) => IsLabel t (ThemingEngine -> p) Source # | |
| ((~) * info (ResolveThemingEngineMethod t ThemingEngine), MethodInfo * info ThemingEngine p) => IsLabelProxy t (ThemingEngine -> p) Source # | |
| HasAttributeList * ThemingEngine Source # | |
| type AttributeList ThemingEngine Source # | |
| type SignalList ThemingEngine Source # | |
class GObject o => IsThemingEngine o Source #
Instances
toThemingEngine :: IsThemingEngine o => o -> IO ThemingEngine Source #
Methods
getBackgroundColor
data ThemingEngineGetBackgroundColorMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m RGBA), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetBackgroundColorMethodInfo a signature Source # | |
themingEngineGetBackgroundColor Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m RGBA |
Deprecated: (Since version 3.14)
Gets the background color for a given state.
Since: 3.0
getBorder
data ThemingEngineGetBorderMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m Border), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetBorderMethodInfo a signature Source # | |
themingEngineGetBorder Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m Border |
getBorderColor
data ThemingEngineGetBorderColorMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m RGBA), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetBorderColorMethodInfo a signature Source # | |
themingEngineGetBorderColor Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m RGBA |
Deprecated: (Since version 3.14)
Gets the border color for a given state.
Since: 3.0
getColor
data ThemingEngineGetColorMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m RGBA), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetColorMethodInfo a signature Source # | |
themingEngineGetColor Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m RGBA |
Deprecated: (Since version 3.14)
Gets the foreground color for a given state.
Since: 3.0
getDirection
data ThemingEngineGetDirectionMethodInfo Source #
Instances
| ((~) * signature (m TextDirection), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetDirectionMethodInfo a signature Source # | |
themingEngineGetDirection Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> m TextDirection | Returns: the widget direction |
Deprecated: (Since version 3.8)Use themingEngineGetState and check for GTK_STATE_FLAG_DIR_LTR and GTK_STATE_FLAG_DIR_RTL instead.
Returns the widget direction used for rendering.
Since: 3.0
getFont
data ThemingEngineGetFontMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m FontDescription), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetFontMethodInfo a signature Source # | |
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m FontDescription | Returns: the |
Deprecated: (Since version 3.8)Use gtk_theming_engine_get()
Returns the font description for a given state.
Since: 3.0
getJunctionSides
data ThemingEngineGetJunctionSidesMethodInfo Source #
Instances
| ((~) * signature (m [JunctionSides]), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetJunctionSidesMethodInfo a signature Source # | |
themingEngineGetJunctionSides Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> m [JunctionSides] | Returns: the widget direction |
Deprecated: (Since version 3.14)
Returns the widget direction used for rendering.
Since: 3.0
getMargin
data ThemingEngineGetMarginMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m Border), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetMarginMethodInfo a signature Source # | |
themingEngineGetMargin Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m Border |
getPadding
data ThemingEngineGetPaddingMethodInfo Source #
Instances
| ((~) * signature ([StateFlags] -> m Border), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetPaddingMethodInfo a signature Source # | |
themingEngineGetPadding Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> [StateFlags] |
|
| -> m Border |
getPath
data ThemingEngineGetPathMethodInfo Source #
Instances
| ((~) * signature (m WidgetPath), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetPathMethodInfo a signature Source # | |
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> m WidgetPath | Returns: A |
Deprecated: (Since version 3.14)
Returns the widget path used for style matching.
Since: 3.0
getProperty
data ThemingEngineGetPropertyMethodInfo Source #
Instances
| ((~) * signature (Text -> [StateFlags] -> m GValue), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetPropertyMethodInfo a signature Source # | |
themingEngineGetProperty Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> Text |
|
| -> [StateFlags] |
|
| -> m GValue |
Deprecated: (Since version 3.14)
Gets a property value as retrieved from the style settings that apply to the currently rendered element.
Since: 3.0
getScreen
data ThemingEngineGetScreenMethodInfo Source #
Instances
| ((~) * signature (m (Maybe Screen)), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetScreenMethodInfo a signature Source # | |
themingEngineGetScreen Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> m (Maybe Screen) |
Deprecated: (Since version 3.14)
Returns the Screen to which engine currently rendering to.
getState
data ThemingEngineGetStateMethodInfo Source #
Instances
| ((~) * signature (m [StateFlags]), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetStateMethodInfo a signature Source # | |
themingEngineGetState Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> m [StateFlags] | Returns: the state flags |
Deprecated: (Since version 3.14)
returns the state used when rendering.
Since: 3.0
getStyleProperty
data ThemingEngineGetStylePropertyMethodInfo Source #
Instances
| ((~) * signature (Text -> m GValue), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineGetStylePropertyMethodInfo a signature Source # | |
themingEngineGetStyleProperty Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> Text |
|
| -> m GValue |
Deprecated: (Since version 3.14)
Gets the value for a widget style property.
Since: 3.0
hasClass
data ThemingEngineHasClassMethodInfo Source #
Instances
| ((~) * signature (Text -> m Bool), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineHasClassMethodInfo a signature Source # | |
themingEngineHasClass Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> Text |
|
| -> m Bool | Returns: |
Deprecated: (Since version 3.14)
Returns True if the currently rendered contents have
defined the given class name.
Since: 3.0
hasRegion
data ThemingEngineHasRegionMethodInfo Source #
Instances
| ((~) * signature (Text -> m (Bool, [RegionFlags])), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineHasRegionMethodInfo a signature Source # | |
themingEngineHasRegion Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> Text |
|
| -> m (Bool, [RegionFlags]) | Returns: |
load
Arguments
| :: (HasCallStack, MonadIO m) | |
| => Text |
|
| -> m (Maybe ThemingEngine) | Returns: A theming engine, or |
Deprecated: (Since version 3.14)
Loads and initializes a theming engine module from the standard directories.
lookupColor
data ThemingEngineLookupColorMethodInfo Source #
Instances
| ((~) * signature (Text -> m (Bool, RGBA)), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineLookupColorMethodInfo a signature Source # | |
themingEngineLookupColor Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> Text |
|
| -> m (Bool, RGBA) | Returns: |
Deprecated: (Since version 3.14)
Looks up and resolves a color name in the current style’s color map.
Since: 3.0
stateIsRunning
data ThemingEngineStateIsRunningMethodInfo Source #
Instances
| ((~) * signature (StateType -> m (Bool, Double)), MonadIO m, IsThemingEngine a) => MethodInfo * ThemingEngineStateIsRunningMethodInfo a signature Source # | |
themingEngineStateIsRunning Source #
Arguments
| :: (HasCallStack, MonadIO m, IsThemingEngine a) | |
| => a |
|
| -> StateType |
|
| -> m (Bool, Double) | Returns: |
Deprecated: (Since version 3.6)Always returns False
Returns True if there is a transition animation running for the
current region (see styleContextPushAnimatableRegion).
If progress is not Nothing, the animation progress will be returned
there, 0.0 means the state is closest to being False, while 1.0 means
it’s closest to being True. This means transition animations will
run from 0 to 1 when state is being set to True and from 1 to 0 when
it’s being set to False.
Since: 3.0
Properties
name
data ThemingEngineNamePropertyInfo Source #
Instances
constructThemingEngineName :: IsThemingEngine o => Text -> IO (GValueConstruct o) Source #
getThemingEngineName :: (MonadIO m, IsThemingEngine o) => o -> m (Maybe Text) Source #
themingEngineName :: AttrLabelProxy "name" Source #