Crate gxi[−][src]
Expand description
GXI
Cross-Platform Native Widget based Component System in Rust
This project implements a component system of GUI widgets and nodes. Using rust proc-macros compiles the component tree to optimized logical n-binary tree flow which prevents
the use of any virtual dom or diffing algorithms. Making the component system zero cost
. Hence the components are highly optimized
, performant
, and customized
to meet the needs of each project while maintaining the standard features of frameworks like React
. Built-in async support
allows for quick and performant abstractions to rust futures.
Since the framework is a compiler, therefore, it allows mixing of platform dependent and independent components, i.e the framework provides components like div
, h1
(platform dependent) and React Native like platform-independent components like Text
and View
. Therefore making the code portable without losing deep control of the native system.
Read more here
Macros
gxi | proc-macro for writing gxi components |
impl_component_node | impl container trait, should have child field |
impl_container | impl container trait, should have child field |
impl_node_component | impl NodeComponent |
impl_node_getters | impl get_child, get_child_mut, get_parent |
impl_node_trait_as_any | impl as_any and as_any_mut for node |
impl_node_trait_as_node | impl as_any and as_any_mut for node |
impl_node_trait_dirty | impl is_dirty, mark_dirty and mark_clean for node need to have is_dirty:bool as a struct field |
impl_widget_node_deref |
Structs
Init | |
Pure | |
Root |
Enums
GxiNodeType | |
InitType | used with init_member |
ShouldRender |
Traits
ComponentNode | A component is node which doesn’t have a native widget |
Container | a node which can hold children |
ContainerWidgetNode | Node which has a native widget and can hold children |
Node | Struct should also implement Drop to remove node widget from the tree |
WidgetNode | Node which has a native widget |
Functions
get_substitute | |
init_member | if init_type doesn’t already exist then run init() and return clone of the new member |
Type Definitions
AsyncResult | |
GxiNodeRc | |
GxiWidgetRc | |
NativeContainer | |
NativeWidget | |
StrongNodeType | |
WeakGxiNodeRc | |
WeakGxiWidgetRc | |
WeakNodeType |