probablycorey
712e9c7203
Add spec to test cutToEndOfLine when soft wrap is enabled
2013-08-06 14:02:30 -07:00
probablycorey
128a030880
Moving to the start or end of a line treats screen lines as real lines
2013-08-06 14:02:30 -07:00
probablycorey
c38edbfe0b
Cursor.moveCursorToBeginningOfNextWord() behaves correctly on whitespace
...
Closes #669
2013-08-05 16:47:29 -07:00
Ben Ogle
cef3b7d634
move folding tests from EditSession -> LanguageMode
2013-07-24 12:05:16 -07:00
Ben Ogle
4187615fa7
Fix test
2013-07-24 11:53:33 -07:00
Ben Ogle
d98ea0180c
Proper handling of cursor up and down behavior when selection range
2013-07-24 11:53:33 -07:00
Ben Ogle
226a4bf391
Add tests for moving to end of selection
2013-07-24 11:53:33 -07:00
Ben Ogle
1465736974
Merge branch 'master' into bo-move-word-behavior
...
Conflicts:
src/app/editor.coffee
2013-07-23 15:34:20 -07:00
Ben Ogle
fe4c4e9751
Add selectToFirstCharacterOfLine to editSession
2013-07-22 09:02:05 -07:00
Ben Ogle
4ccbd03daf
I can't spell. Boundary.
2013-07-19 12:17:17 -07:00
Ben Ogle
3df33a7367
Add selection counterparts to move next/prev word boundary
2013-07-19 12:07:30 -07:00
Ben Ogle
13b592d1f3
Add Cursor::moveToNextWordBoundry()
...
Plumb up to editor as well.
2013-07-19 11:37:47 -07:00
Ben Ogle
ab8df8dcde
Add moveToPreviousWordBoundry to cursor.
...
Plumb it up to a command in the editor.
2013-07-19 11:16:14 -07:00
Ben Ogle
2aca31988f
Fix tests in EditSession
2013-07-17 17:56:52 -07:00
Corey Johnson & Matt Colyer
4a67bfcf15
Remove editor.autoIndentOnPaste config option
...
Normalize paste on indent covers most use cases of autoindent when pasting.
Closes #584
2013-07-16 17:08:12 -07:00
Kevin Sawicki
e67676b01c
Use deleteSelectedText() instead of delete()
...
Selection.delete() adds to the selection if it is empty which
we don't want to do when replacing selected text.
Closes #603
2013-06-26 19:03:45 -07:00
Corey Johnson & Nathan Sobo
b9accadb70
When normalizing indent, ignore leading spaces of first line
...
Fixes #594
2013-06-19 12:21:05 -06:00
Kevin Sawicki
f85f95e792
Move universal comment toggle specs to edit-session-spec
2013-06-05 17:58:39 -07:00
Kevin Sawicki
a109a3317e
Add support for surrogate pairs
...
Surrogate pairs, meaning characters outside the Basic
Multilingual Plane, are now broken out as atomic tokens.
Closes #567
2013-06-04 13:43:19 -07:00
Kevin Sawicki
5a691a1b1e
Merge branch 'master' into atom-shell
2013-05-29 13:23:23 -07:00
Kevin Sawicki
ce71cf7703
Use correct indentation
2013-05-29 11:55:06 -07:00
Corey Johnson & Kevin Sawicki
f8f059d3fe
Use correct textmate package names
2013-05-29 11:01:59 -07:00
probablycorey
7716441bbd
Update clipboard calls in edit session spec
2013-05-22 16:01:57 -07:00
Nathan Sobo
6104927cb6
Rename Project.buildEditSession -> Project.open
2013-05-14 20:03:53 -06:00
probablycorey
423b133e75
Comments can't increase the indent level of the next line
2013-05-13 14:28:16 -07:00
probablycorey
eae06b62bc
Spec 💄
2013-05-13 14:28:16 -07:00
probablycorey
49aeef99b6
Add config option editor.normalizeIndentOnPaste
2013-05-13 14:28:16 -07:00
probablycorey
8e37d2ada6
Turn auto-indent on for all 'newline' specs
2013-05-13 14:28:16 -07:00
probablycorey
7513fe9c69
Set editor.autoIndent to true in specs
2013-05-13 14:28:16 -07:00
probablycorey
992f520698
Normalize pasted text when there is an indent basis
2013-05-13 14:28:16 -07:00
probablycorey
b23e1d3d52
In specs, use local copyText function to put text on the pasteboard
2013-05-13 14:28:16 -07:00
probablycorey
dd53539799
Moving auto-indent specs to appropriate places
2013-05-13 14:28:15 -07:00
probablycorey
93b1ce53c0
Rename autoDecreaseIndentForRow to autoDecreaseIndentForBufferRow
2013-05-13 14:28:15 -07:00
probablycorey
c34db290e4
Only indent the line following a '\n' not the line preceding it
2013-05-13 14:28:15 -07:00
probablycorey
9d2b7875b9
💄
2013-05-13 14:28:15 -07:00
probablycorey
38d4e3a097
Move all auto-indent specs to the auto-indent describe block
2013-05-13 14:28:15 -07:00
probablycorey
c03d44da00
Add autoIndentNewline and autoDecreaseIndent options to insertText
...
insertText now takes these options:
* autoIndent will auto indent all inserted text based
* autoIndentNewline will indent a line when a '\n' is inserted
* autoDecreaseIndent will decrease the indent if the line matches a
decreaseIndent pattern (such as a `}` in javavascript)
2013-05-13 14:28:15 -07:00
probablycorey
9713bc8c02
💄
2013-05-13 14:28:15 -07:00
probablycorey
7f0b2c54f3
editor.autoIndentOnPaste will auto indent every pasted line
...
I've removed normalizeLines and its tests. They will be added back in
a later commit.
2013-05-13 14:28:14 -07:00
Corey Johnson & Nathan Sobo
da938d8212
Fix edit session specs concerning delete/backspace + folds
2013-05-03 17:24:08 -06:00
Nathan Sobo
69300e0766
Make Buffer.transact restore marker ranges on undo/redo of transaction
...
We no longer need to restore selection ranges before and after
transactions now because selections are based on markers so they go
along for the ride for free. This allows us to delegate directly to
Buffer.transact from EditSession.
2013-05-01 18:38:40 -06:00
Nathan Sobo
693c4f8270
Preserve folds when restoring selections on undo/redo
2013-04-30 18:39:54 -06:00
Nathan Sobo
9f8a07fc27
Fix some edit session specs. The remaining failures are less trivial.
2013-04-30 04:43:28 -06:00
Nathan Sobo
caf34d6a3a
EditSession.selectMarker checks if the marker is valid
...
Also, it returns the selected range if it's valid, and otherwise
returns a falsy value. This has more utility than just true/false.
2013-04-29 21:01:47 -06:00
Nathan Sobo
f4be899ae9
Switch EditSession over to object-oriented markers API
2013-04-29 21:01:47 -06:00
Nathan Sobo
4fdc9fba63
Eliminate EditSession dependencies in DisplayBuffer spec
2013-04-25 16:18:39 -06:00
Nathan Sobo
60f945aafd
Move structural folding specs to edit-session-spec
...
Structural folding should really be handled at the edit session level
so that the DisplayBuffer doesn't need access to the LanguageMode. It
should only be concerned with the raw ability to create folds.
2013-04-25 14:06:53 -06:00
Mutwin Kraus
c91de1e515
Merge remote-tracking branch 'origin/master' into vim-core-changes
...
Conflicts:
src/app/pane.coffee
2013-04-09 18:52:36 +02:00
Kevin Sawicki
2f67312a80
Don't prompt to save if buffer is opened elsewhere
...
This corrects a regression where closing an edit session that
is opened somewhere else should not prompt to save since it
won't be lost if closed immediately since it is still open in
another pane.
2013-04-08 16:30:35 -07:00
Mutwin Kraus
9041c56ef3
Spec for selectToBeginningOfNextWord
2013-04-08 14:19:28 +02:00