pub struct CreateStyleCommand {
pub style_name: String,
pub style_builder: StyleBuilder,
pub description: Option<String>,
}Expand description
Command to create a new style
Fields§
§style_name: String§style_builder: StyleBuilder§description: Option<String>Implementations§
Source§impl CreateStyleCommand
impl CreateStyleCommand
Sourcepub fn new(style_name: String, style_builder: StyleBuilder) -> Self
pub fn new(style_name: String, style_builder: StyleBuilder) -> Self
Create a new style creation command
Sourcepub fn with_description(self, description: String) -> Self
pub fn with_description(self, description: String) -> Self
Set a custom description for this command
Trait Implementations§
Source§impl Clone for CreateStyleCommand
impl Clone for CreateStyleCommand
Source§fn clone(&self) -> CreateStyleCommand
fn clone(&self) -> CreateStyleCommand
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CreateStyleCommand
impl Debug for CreateStyleCommand
Source§impl EditorCommand for CreateStyleCommand
impl EditorCommand for CreateStyleCommand
Source§fn execute(&self, document: &mut EditorDocument) -> Result<CommandResult>
fn execute(&self, document: &mut EditorDocument) -> Result<CommandResult>
Execute the command on the given document Read more
Source§fn description(&self) -> &str
fn description(&self) -> &str
Get a human-readable description of the command
Source§fn memory_usage(&self) -> usize
fn memory_usage(&self) -> usize
Get the estimated memory usage of this command Read more
Source§fn modifies_content(&self) -> bool
fn modifies_content(&self) -> bool
Check if this command modifies document content Read more
Auto Trait Implementations§
impl Freeze for CreateStyleCommand
impl RefUnwindSafe for CreateStyleCommand
impl Send for CreateStyleCommand
impl Sync for CreateStyleCommand
impl Unpin for CreateStyleCommand
impl UnwindSafe for CreateStyleCommand
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