@@ -32,6 +32,12 @@ pub enum EditCommand {
3232 select : bool ,
3333 } ,
3434
35+ /// Move to the start of the current line skipping any whitespace
36+ MoveToLineNonBlankStart {
37+ /// Select the text between the current cursor position and destination
38+ select : bool ,
39+ } ,
40+
3541 /// Move to the end of the buffer
3642 MoveToEnd {
3743 /// Select the text between the current cursor position and destination
@@ -157,6 +163,9 @@ pub enum EditCommand {
157163 /// Cut from the start of the current line to the insertion point
158164 CutFromLineStart ,
159165
166+ /// Cut from the first non whitespace character of the current line to the insertion point
167+ CutFromLineNonBlankStart ,
168+
160169 /// Cut from the insertion point to the end of the buffer
161170 CutToEnd ,
162171
@@ -277,6 +286,9 @@ pub enum EditCommand {
277286 /// Copy from the start of the current line to the insertion point
278287 CopyFromLineStart ,
279288
289+ /// Copy from the first non whitespace character of the current line to the insertion point
290+ CopyFromLineNonBlankStart ,
291+
280292 /// Copy from the insertion point to the end of the buffer
281293 CopyToEnd ,
282294
@@ -359,6 +371,9 @@ impl Display for EditCommand {
359371 EditCommand :: MoveToLineStart { .. } => {
360372 write ! ( f, "MoveToLineStart Optional[select: <bool>]" )
361373 }
374+ EditCommand :: MoveToLineNonBlankStart { .. } => {
375+ write ! ( f, "MoveToLineNonBlankStart Optional[select: <bool>]" )
376+ }
362377 EditCommand :: MoveToEnd { .. } => write ! ( f, "MoveToEnd Optional[select: <bool>]" ) ,
363378 EditCommand :: MoveToLineEnd { .. } => {
364379 write ! ( f, "MoveToLineEnd Optional[select: <bool>]" )
@@ -409,6 +424,7 @@ impl Display for EditCommand {
409424 EditCommand :: CutCurrentLine => write ! ( f, "CutCurrentLine" ) ,
410425 EditCommand :: CutFromStart => write ! ( f, "CutFromStart" ) ,
411426 EditCommand :: CutFromLineStart => write ! ( f, "CutFromLineStart" ) ,
427+ EditCommand :: CutFromLineNonBlankStart => write ! ( f, "CutFromLineNonBlankStart" ) ,
412428 EditCommand :: CutToEnd => write ! ( f, "CutToEnd" ) ,
413429 EditCommand :: CutToLineEnd => write ! ( f, "CutToLineEnd" ) ,
414430 EditCommand :: KillLine => write ! ( f, "KillLine" ) ,
@@ -440,6 +456,7 @@ impl Display for EditCommand {
440456 EditCommand :: Paste => write ! ( f, "Paste" ) ,
441457 EditCommand :: CopyFromStart => write ! ( f, "CopyFromStart" ) ,
442458 EditCommand :: CopyFromLineStart => write ! ( f, "CopyFromLineStart" ) ,
459+ EditCommand :: CopyFromLineNonBlankStart => write ! ( f, "CopyFromLineNonBlankStart" ) ,
443460 EditCommand :: CopyToEnd => write ! ( f, "CopyToEnd" ) ,
444461 EditCommand :: CopyToLineEnd => write ! ( f, "CopyToLineEnd" ) ,
445462 EditCommand :: CopyCurrentLine => write ! ( f, "CopyCurrentLine" ) ,
@@ -478,6 +495,7 @@ impl EditCommand {
478495 | EditCommand :: MoveToEnd { select, .. }
479496 | EditCommand :: MoveToLineStart { select, .. }
480497 | EditCommand :: MoveToLineEnd { select, .. }
498+ | EditCommand :: MoveToLineNonBlankStart { select, .. }
481499 | EditCommand :: MoveToPosition { select, .. }
482500 | EditCommand :: MoveLeft { select, .. }
483501 | EditCommand :: MoveRight { select, .. }
@@ -514,6 +532,7 @@ impl EditCommand {
514532 | EditCommand :: CutCurrentLine
515533 | EditCommand :: CutFromStart
516534 | EditCommand :: CutFromLineStart
535+ | EditCommand :: CutFromLineNonBlankStart
517536 | EditCommand :: CutToLineEnd
518537 | EditCommand :: KillLine
519538 | EditCommand :: CutToEnd
@@ -550,6 +569,7 @@ impl EditCommand {
550569 EditCommand :: YankInside { .. } => EditType :: EditText ,
551570 EditCommand :: CopyFromStart
552571 | EditCommand :: CopyFromLineStart
572+ | EditCommand :: CopyFromLineNonBlankStart
553573 | EditCommand :: CopyToEnd
554574 | EditCommand :: CopyToLineEnd
555575 | EditCommand :: CopyCurrentLine
0 commit comments