@@ -72,6 +72,12 @@ pub enum EditCommand {
7272 select : bool ,
7373 } ,
7474
75+ /// Move to the start of the current line skipping any whitespace
76+ MoveToLineNonBlankStart {
77+ /// Select the text between the current cursor position and destination
78+ select : bool ,
79+ } ,
80+
7581 /// Move to the end of the buffer
7682 MoveToEnd {
7783 /// Select the text between the current cursor position and destination
@@ -197,6 +203,9 @@ pub enum EditCommand {
197203 /// Cut from the start of the current line to the insertion point
198204 CutFromLineStart ,
199205
206+ /// Cut from the first non whitespace character of the current line to the insertion point
207+ CutFromLineNonBlankStart ,
208+
200209 /// Cut from the insertion point to the end of the buffer
201210 CutToEnd ,
202211
@@ -317,6 +326,9 @@ pub enum EditCommand {
317326 /// Copy from the start of the current line to the insertion point
318327 CopyFromLineStart ,
319328
329+ /// Copy from the first non whitespace character of the current line to the insertion point
330+ CopyFromLineNonBlankStart ,
331+
320332 /// Copy from the insertion point to the end of the buffer
321333 CopyToEnd ,
322334
@@ -423,6 +435,9 @@ impl Display for EditCommand {
423435 EditCommand :: MoveToLineStart { .. } => {
424436 write ! ( f, "MoveToLineStart Optional[select: <bool>]" )
425437 }
438+ EditCommand :: MoveToLineNonBlankStart { .. } => {
439+ write ! ( f, "MoveToLineNonBlankStart Optional[select: <bool>]" )
440+ }
426441 EditCommand :: MoveToEnd { .. } => write ! ( f, "MoveToEnd Optional[select: <bool>]" ) ,
427442 EditCommand :: MoveToLineEnd { .. } => {
428443 write ! ( f, "MoveToLineEnd Optional[select: <bool>]" )
@@ -473,6 +488,7 @@ impl Display for EditCommand {
473488 EditCommand :: CutCurrentLine => write ! ( f, "CutCurrentLine" ) ,
474489 EditCommand :: CutFromStart => write ! ( f, "CutFromStart" ) ,
475490 EditCommand :: CutFromLineStart => write ! ( f, "CutFromLineStart" ) ,
491+ EditCommand :: CutFromLineNonBlankStart => write ! ( f, "CutFromLineNonBlankStart" ) ,
476492 EditCommand :: CutToEnd => write ! ( f, "CutToEnd" ) ,
477493 EditCommand :: CutToLineEnd => write ! ( f, "CutToLineEnd" ) ,
478494 EditCommand :: KillLine => write ! ( f, "KillLine" ) ,
@@ -504,6 +520,7 @@ impl Display for EditCommand {
504520 EditCommand :: Paste => write ! ( f, "Paste" ) ,
505521 EditCommand :: CopyFromStart => write ! ( f, "CopyFromStart" ) ,
506522 EditCommand :: CopyFromLineStart => write ! ( f, "CopyFromLineStart" ) ,
523+ EditCommand :: CopyFromLineNonBlankStart => write ! ( f, "CopyFromLineNonBlankStart" ) ,
507524 EditCommand :: CopyToEnd => write ! ( f, "CopyToEnd" ) ,
508525 EditCommand :: CopyToLineEnd => write ! ( f, "CopyToLineEnd" ) ,
509526 EditCommand :: CopyCurrentLine => write ! ( f, "CopyCurrentLine" ) ,
@@ -546,6 +563,7 @@ impl EditCommand {
546563 | EditCommand :: MoveToEnd { select, .. }
547564 | EditCommand :: MoveToLineStart { select, .. }
548565 | EditCommand :: MoveToLineEnd { select, .. }
566+ | EditCommand :: MoveToLineNonBlankStart { select, .. }
549567 | EditCommand :: MoveToPosition { select, .. }
550568 | EditCommand :: MoveLeft { select, .. }
551569 | EditCommand :: MoveRight { select, .. }
@@ -582,6 +600,7 @@ impl EditCommand {
582600 | EditCommand :: CutCurrentLine
583601 | EditCommand :: CutFromStart
584602 | EditCommand :: CutFromLineStart
603+ | EditCommand :: CutFromLineNonBlankStart
585604 | EditCommand :: CutToLineEnd
586605 | EditCommand :: KillLine
587606 | EditCommand :: CutToEnd
@@ -622,6 +641,7 @@ impl EditCommand {
622641 EditCommand :: CopyTextObject { .. } => EditType :: NoOp ,
623642 EditCommand :: CopyFromStart
624643 | EditCommand :: CopyFromLineStart
644+ | EditCommand :: CopyFromLineNonBlankStart
625645 | EditCommand :: CopyToEnd
626646 | EditCommand :: CopyToLineEnd
627647 | EditCommand :: CopyCurrentLine
0 commit comments