pub struct NodeGraph {
pub width: i32,
pub height: i32,
pub nodes: Vec<GraphNode>,
pub connections: Vec<NodeConnection>,
pub zoom: f32,
pub pan_x: f32,
pub pan_y: f32,
pub show_grid: bool,
pub on_change: String,
}Fields§
§width: i32§height: i32§nodes: Vec<GraphNode>§connections: Vec<NodeConnection>§zoom: f32§pan_x: f32§pan_y: f32§show_grid: bool§on_change: StringImplementations§
Source§impl NodeGraph
impl NodeGraph
pub fn new() -> NodeGraph
pub fn size(self, width: i32, height: i32) -> NodeGraph
pub fn node(self, node: GraphNode) -> NodeGraph
pub fn connect( self, from_node: String, from_pin: String, to_node: String, to_pin: String, ) -> NodeGraph
pub fn zoom(self, zoom: f32) -> NodeGraph
pub fn pan(self, x: f32, y: f32) -> NodeGraph
Trait Implementations§
Auto Trait Implementations§
impl Freeze for NodeGraph
impl RefUnwindSafe for NodeGraph
impl Send for NodeGraph
impl Sync for NodeGraph
impl Unpin for NodeGraph
impl UnwindSafe for NodeGraph
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more