Commit Graph

1668 Commits

Author SHA1 Message Date
Corey Johnson & Nathan Sobo
24654d5bd6 💄 clarify substitution regex recursion 2012-03-27 15:55:23 -07:00
Corey Johnson & Nathan Sobo
5e89c44477 Match $ in command regexes as end of line. Don't infinitely loop on substituting zero-width matches 2012-03-27 15:39:07 -07:00
Corey Johnson & Nathan Sobo
7d969e145a x command loops over all selected regions 2012-03-27 14:32:20 -07:00
Nathan Sobo
ad3aa0709c Add x command, which selects all matches in the current selection 2012-03-27 12:54:28 -07:00
Nathan Sobo
461fdd5e61 Selection merging with mouse maintains directionality of last selection 2012-03-27 11:52:55 -07:00
Corey Johnson & Nathan Sobo
e62e062f9b Maintain selection directionality when merging selections with keyboard 2012-03-27 11:26:36 -07:00
Corey Johnson & Nathan Sobo
81869ebf59 After shift/arrow-key movement, merge overlapping selections 2012-03-27 11:09:35 -07:00
Corey Johnson & Nathan Sobo
6b96251174 Rename Selection.modifySelections to modifySelectedText 2012-03-27 10:30:00 -07:00
Corey Johnson & Nathan Sobo
4be12ec461 Clear selection and update its appearance on delete
This fixes issues with selections in which the cursor precedes the anchor not getting cleared because the cursor doesn't move when text is deleted.
2012-03-27 10:21:26 -07:00
Corey Johnson & Nathan Sobo
9eca7f60a4 Remove *.selectToBufferPosition 2012-03-27 10:06:45 -07:00
Corey Johnson
8866789b9c add shift+arrows movement for multi-selections 2012-03-27 09:43:30 -07:00
Corey Johnson
222b01215c 💄 2012-03-27 09:16:09 -07:00
Corey Johnson
819f1a86f2 Delete works for multiple selections 2012-03-27 09:12:58 -07:00
Corey Johnson & Nathan Sobo
553194dc9e Backspace works with multiple selections 2012-03-27 09:10:11 -07:00
Nathan Sobo
29a2cc5886 Delete works with multiple cursors. 2012-03-26 19:39:09 -07:00
Nathan Sobo
e6e24158ae Can replace multiple selections on same line with newlines.
Also storing both buffer position and screen position of anchor in selection at the same time, so we can always reference either one. Whenever one is updated, we automatically update the other.
2012-03-26 18:16:55 -07:00
Corey Johnson & Nathan Sobo
37df49f77e Selection anchors move on buffer changes 2012-03-26 17:03:17 -07:00
Corey Johnson & Nathan Sobo
4d1f7b33e7 WIP: multiselection cut/copy/paste 2012-03-26 16:24:33 -07:00
Corey Johnson & Nathan Sobo
36177e4520 Refactor Editor's cursor connivence methods. 2012-03-26 15:36:54 -07:00
Corey Johnson & Nathan Sobo
7e2933b983 Remove Editor.getCurrentBufferLine 2012-03-26 15:31:47 -07:00
Corey Johnson & Nathan Sobo
c9b9e30848 💄 2012-03-26 15:28:37 -07:00
Corey Johnson & Nathan Sobo
65b0107811 Auto-indent works for multiple cursors 2012-03-26 15:22:45 -07:00
Corey Johnson & Nathan Sobo
d304786245 Make all remaining specs pass as if there were only one cursor. 2012-03-26 14:58:52 -07:00
Corey Johnson & Nathan Sobo
8422c7ad12 Overlapping selections are merged 2012-03-26 12:41:36 -07:00
Corey Johnson & Nathan Sobo
22eb9c5860 Merge to one cursor on click. Meta click-drag creates multiple selections. 2012-03-26 11:20:09 -07:00
Corey Johnson & Nathan Sobo
9e32126d3d Cursors are merged after moving 2012-03-26 10:40:38 -07:00
Corey Johnson & Nathan Sobo
205bc47b3e Merge cursors after buffer changes, but not after movement 2012-03-26 10:26:12 -07:00
Corey Johnson & Nathan Sobo
3d88477e9c Add multiple cursor movement 2012-03-23 16:17:04 -06:00
Corey Johnson & Nathan Sobo
a67bb98f02 Multiple newlines can be inserted on the same line
Redesign Cursor.handleBufferChange. The basic intuition is that each cursor should have the same spatial relationship with the end of the new range as it previously had with the end of the old range.
2012-03-23 16:02:34 -06:00
Corey Johnson & Nathan Sobo
923e67af97 Add spec for backspace on multiple lines. 2012-03-23 15:23:02 -06:00
Corey Johnson & Nathan Sobo
7a6bc8fd4b Backspace explicitly clears selection 2012-03-23 15:21:09 -06:00
Nathan Sobo
64061e9aef Merge branch 'master' into multi-cursor 2012-03-23 15:00:57 -06:00
Nathan Sobo
7ee0d1bc7c Un-F 2012-03-23 14:59:52 -06:00
Corey Johnson & Nathan Sobo
c59f6b0651 Use Editor.getSelection instead of directly grabbing .selection property 2012-03-23 14:59:08 -06:00
Corey Johnson & Nathan Sobo
59b629d60e Backspace works with multiple cursors 2012-03-23 11:55:55 -07:00
Corey Johnson & Nathan Sobo
83d5c1dd0b Multiple cursors can insert newlines 2012-03-23 11:22:01 -07:00
Nathan Sobo
0406746bd0 Don't throw exception if hitting meta-g with no previous relative address 2012-03-23 11:46:55 -06:00
Nathan Sobo
91bdc20b81 Merge branch 'master' of github.com:github/atom
Conflicts:
	src/atom/command-panel.coffee
2012-03-23 11:42:18 -06:00
Nathan Sobo
7708cf7f33 Meta-g repeats the last relative address command
Rename repeatLastRelativeAddress to repeatRelativeAddress since it's implied that it's the "last" one.
2012-03-23 11:40:59 -06:00
Nathan Sobo
3bda7c4d3f Add CommandInterpreter.repeatLastRelativeAddress 2012-03-23 11:32:58 -06:00
Corey Johnson & Nathan Sobo
b2cd059759 Set .hidden-input to fixed position so we don't have to move it when the cursor moves 2012-03-23 10:13:41 -07:00
Corey Johnson
ef9eaff054 implement meta-f on root-view 2012-03-23 10:10:53 -07:00
Corey Johnson
ef9bb5a259 :lipstick 2012-03-23 09:50:41 -07:00
Nathan Sobo
49be6986a0 Root view can receive focus if there is no active editor.
This allows basic key bindings to work without an editor.
2012-03-23 10:44:25 -06:00
Corey Johnson & Nathan Sobo
4c74e2187d Set .hidden-input to fixed position so we don't have to move it when the cursor moves 2012-03-22 17:29:48 -07:00
Corey Johnson & Nathan Sobo
f431b24627 WIP: Can place multiple cursors and insert text without newlines. Very broken. 2012-03-22 18:10:24 -06:00
Corey Johnson & Nathan Sobo
9e91790ad3 Fix CurrentSelectionAddress goof 2012-03-22 16:07:50 -06:00
Corey Johnson & Nathan Sobo
23a8a6141b Regex address does not require trailing / 2012-03-22 14:37:19 -07:00
Corey Johnson & Nathan Sobo
12f4a47b87 Add regex address to command language 2012-03-22 14:34:27 -07:00
Corey Johnson & Nathan Sobo
9e5bba9ab1 Add . address to command interpreter 2012-03-22 12:20:44 -07:00