Expand description
§Freya Hooks
A collection of hooks to be used in Freya.
Macros§
- cow_
borrowed - Alias for
Cow::Borrowed
, because that’s used a million times so shortening it is nice. Makes the code more readable. - define_
theme - Example usage:
- theme_
with - Create
FooThemeWith
structs without having to deal with the verbose syntax. - use_
applied_ theme - This macro has three arguments separator by commas.
Structs§
- Accordion
Theme - Theming properties for the
Accordion
component. - Accordion
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Activable
Route Context - Anim
Color - Animate a color.
- AnimNum
- Animate a numeric value.
- Asset
Cacher - Asset
Configuration - Configuration for a given Asset.
- Body
Theme - Theming properties for the
Body
component. - Body
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Button
Theme - Theming properties for the
Button
component. - Button
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Canvas
Theme - Theming properties for the
Canvas
component. - Canvas
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Checkbox
Theme - Theming properties for the
Checkbox
component. - Checkbox
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Context
- Dropdown
Item Theme - Theming properties for the
DropdownItem
component. - Dropdown
Item Theme With - You can use this to change a theme for only one component, with the
theme
property. - Dropdown
Theme - Theming properties for the
Dropdown
component. - Dropdown
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Editable
Config - Create a configuration for a
UseEditable
. - Editor
History - Font
Theme - Theming properties for Fonts.
- Font
Theme With - You can use this to change a theme for only one component, with the
theme
property. Theming properties for Fonts. - Graph
Theme - Theming properties for the
Graph
component. - Graph
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Icon
Theme - Theming properties for the
Icon
component. - Icon
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Input
Theme - Theming properties for the
Input
component. - Input
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Line
- A text line from a TextEditor
- Lines
Iterator - Iterator over text lines.
- Link
Theme - Theming properties for the
Link
component. - Link
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Loader
Theme - Theming properties for the
Loader
component. - Loader
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Menu
Container Theme - Theming properties for the
MenuContainer
component. - Menu
Container Theme With - You can use this to change a theme for only one component, with the
theme
property. - Menu
Item Theme - Theming properties for the
MenuItem
component. - Menu
Item Theme With - You can use this to change a theme for only one component, with the
theme
property. - Navigation
Mark - Network
Image Theme - Theming properties for the
NetworkImage
component. - Network
Image Theme With - You can use this to change a theme for only one component, with the
theme
property. - Platform
Information - Information about the platform.
- Popup
Theme - Theming properties for the
Popup
component. - Popup
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Progress
BarTheme - Theming properties for the
ProgressBar
component. - Progress
BarTheme With - You can use this to change a theme for only one component, with the
theme
property. - Radio
Theme - Theming properties for the
Radio
component. - Radio
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Rope
- A utf8 text rope.
- Rope
Editor - TextEditor implementing a Rope
- Scroll
BarTheme - Theming properties for the
ScrollBar
component. - Scroll
BarTheme With - You can use this to change a theme for only one component, with the
theme
property. - Scroll
View Theme - Theming properties for the
ScrollView
component. Also used byVirtualScrollView
. - Scroll
View Theme With - You can use this to change a theme for only one component, with the
theme
property. Also used byVirtualScrollView
. - Sidebar
Item Theme - Theming properties for the
SidebarItem
component. - Sidebar
Item Theme With - You can use this to change a theme for only one component, with the
theme
property. - Sidebar
Theme - Theming properties for the
Sidebar
component. - Sidebar
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Slider
Theme - Theming properties for the
Slider
component. - Slider
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Snack
BarTheme - Theming properties for the
SnackBar
component. - Snack
BarTheme With - You can use this to change a theme for only one component, with the
theme
property. - Switch
Theme - Theming properties for the
Switch
component. - Switch
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Table
Theme - Theming properties for the
Table
component. - Table
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Text
Cursor - Holds the position of a cursor in a text
- Text
Event - Events for TextEditor
- Theme
- Ticker
- Tile
Theme - Theming properties for the
Tile
component. - Tile
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Tooltip
Theme - Theming properties for the
Tooltip
component. - Tooltip
Theme With - You can use this to change a theme for only one component, with the
theme
property. - Uniforms
Builder - Pass uniform values to a Shader.
- UseAnimator
- Animate your elements. Use
use_animation
to use this. - UseCanvas
- Holds a rendering hook callback that allows to render to the Canvas.
- UseCanvas
Runner - UseEditable
- Manage an editable content.
- UseFocus
- Manage the focus operations of given Node
- UsePlatform
Enums§
- Anim
Direction - Controls the direction of the animation.
- Asset
Age - Defines the duration for which an Asset will remain cached after it’s user has stopped using it. The default is 1h (3600s).
- Ease
- Editable
Event - Events emitted to the
UseEditable
. - Editable
Mode - How the editable content must behave.
- Function
- History
Change - OnFinish
- What to do once the animation finishes. By default it is
Stop
- Uniform
Value - Uniform value to be passed to a Shader.
- UsePlatform
Error
Constants§
Traits§
- Animated
Value - Text
Editor - Common trait for editable texts
Functions§
- apply_
value - use_
activable_ route - use_
animation - Animate your elements easily.
- use_
animation_ with_ dependencies - use_
asset_ cacher - Global caching system for assets.
- use_
canvas - Register a rendering hook to gain access to the Canvas.
- use_
editable - Create a virtual text editor with it’s own cursor and rope.
- use_
focus - Create a focus manager for a node.
- use_
get_ theme - Subscribe to
Theme
changes, default theme will be used if there is no providedTheme
. - use_
init_ accessibility - Sync both the Focus shared state and the platform accessibility focus
- use_
init_ default_ theme - Provide the default
Theme
. - use_
init_ theme - Provide a custom
Theme
. - use_
node - Subscribe to a Node layout changes.
- use_
node_ signal - Get a signal to read the latest layout from a Node.
- use_
platform - Get access to information and features of the platform.
- use_
theme - Subscribe to
Theme
changes.