pub struct Editor { /* private fields */ }
Expand description

This represents the editor you want to use to edit and display petri nets.

Implementations

Copy selected elements to clipboard.

Cut selected elements to clipboard.

Pastes contents from clipboard.

Loads the net from a specified path.

Loads a new net.

Saves the current net.

Saves the current progress of a simulation.

Loads the some progress for the simulation.

Grab something.

  • primary: specifies if the primary button is pressed.
  • clear_old: specifies if old selections should be deselected.
  • create: creates new nodes.

Release something.

Set cursor position.

Fire node.

Input text.

Finish the current action. Basically the user presses the enter key.

Escapes from submenus.

Move the text cursor in line.

Move the text cursor by a line.

Move the text by a page.

Move the text to the start or end of line or file.

Switches simulation mode.

Adds a token to nodes if they are places.

Removes all selected nodes.

Should be called when the window is resized.

Cycle through states.

Adds a new simulation state.

Toggles snapping.

Toggles the editor.

Enables the search bar.

Loads in an empty net.

Changes the view mode. See ViewMode for more information about the view modes.

Zoom in or out by a factor.

Ensure the net be saved.

Creates a new editor, which contains a renderer and knows about the window size.

Trait Implementations

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more

Checks if self is actually part of its subset T (and can be converted to it).

Use with care! Same as self.to_subset but without any property checks. Always succeeds.

The inclusion map: converts self to the equivalent element of its superset.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.