Commit Graph

258 Commits

Author SHA1 Message Date
Corey Johnson
42299c6a71 When the active edit session is modified, and its file is then modified by the file system, it displays an alert. 2012-07-26 10:59:58 -07:00
Corey Johnson & Nathan Sobo
d36873f702 Rename Project.open to Project.buildEditSessionForPath 2012-07-18 11:20:13 -07:00
Corey Johnson
3e3bc99161 Merge branch 'master' into global-find
Conflicts:
	spec/app/editor-spec.coffee
2012-07-16 09:16:07 -07:00
Corey Johnson
e089b74867 Editor.renderedLines' css width is set to 100% when editor.maxScreenLineLength() is less than Editor.scrollView's width 2012-07-16 09:14:33 -07:00
Corey Johnson & Nathan Sobo
c7b7135388 Temporary fix: When editor is resized, adjust width of rendered lines.
We do this to ensure that the lines aren't longer than the scroll view if they don't have to be. We really should use min-width instead because it's automatic. Also, trigger window resize when we make the editor narrower.
2012-07-13 17:17:18 -06:00
Corey Johnson
b9d4270693 Merge branch 'master' into global-find 2012-07-13 09:36:21 -07:00
Corey Johnson
9dfa7d9439 When splitting an editor only the active edit session is copied to the new editor. 2012-07-13 09:24:14 -07:00
Corey Johnson & Nathan Sobo
d44c648d4b Editor.renderedLines' width is set to the maximum of either Editor.scrollView's width or the maximum rendered line width 2012-07-13 09:05:38 -07:00
Nathan Sobo
a4db677979 Implement setSelectedBufferRange w/ setSelectedBufferRanges
Also add the preserveFolds option, which doesn't destroy folds containing the selected ranges – mainly for specs right now
2012-07-12 18:57:12 -06:00
Nathan Sobo
53d6c4960a Fix specs that broke due to no subscription on Buffer from UndoManager 2012-07-05 20:06:09 -06:00
Nathan Sobo
f253820250 💄 Use more delegated (editor -> buffer) methods 2012-07-04 12:58:00 -06:00
Nathan Sobo
6d7a6f9a92 💄 Replace editor.getBuffer().getPath() w/ editor.getPath() 2012-07-04 12:40:17 -06:00
Nathan Sobo
c90c2e80d6 Replace @buffer reference on Editor with @getBuffer method 2012-07-04 12:34:44 -06:00
Nathan Sobo
fb6aa46531 Editor subscribes to buffer-path-change events on edit sessions, not buffers directly 2012-07-04 12:05:09 -06:00
Nathan Sobo
bdfdf08ea0 Adjust Editor.scrollTop when removing a line reduces the scroll height
This eliminates rendering artifacts and jerky scrolling at the bottom of the screen
2012-07-03 11:12:54 -06:00
Nathan Sobo
3ee7c0dc0f "Scroll" gutter by relatively positioning its line numbers
This matches how we scroll lines, and eliminates opportunities for the gutter to get out of sync with the lines. If that happened, it would probably be a bug, but this at least eliminates one source of confusion when debugging.
2012-07-03 11:09:34 -06:00
Nathan Sobo
bd5c1f8694 Rename RootView.activeEditor -> getActiveEditor 2012-07-02 19:46:33 -06:00
Corey Johnson
801a91ec9b Specs cleanup buffers 2012-06-29 15:38:12 -07:00
Corey Johnson
c3d7d3566f Buffer listens for changes to file and triggers 'contents-change' event 2012-06-29 15:09:31 -07:00
Corey Johnson
e295d19d51 Editor.prototype.removeActiveEditSession calls destroy on the removed edit session 2012-06-29 15:09:01 -07:00
Nathan Sobo
423b312e9c Meta-b opens the fuzzy finder with paths to the current editor's buffers 2012-06-28 12:57:52 -06:00
Nathan Sobo
5b11762989 Fix bug where edit sessions were not properly restored on refresh 2012-06-27 07:53:32 -06:00
Corey Johnson
6d69ec77f1 Remove un-needed window.advanceClock calls from editor 2012-06-26 16:41:13 -07:00
Corey Johnson & Nathan Sobo
d1c1f3cfce Move autoIndent, tabText, softTabs and softWrap to project 2012-06-20 09:28:23 -07:00
Corey Johnson & Nathan Sobo
4e78b29e81 Replace Editor.setBuffer with Editor.edit 2012-06-20 09:28:23 -07:00
Corey Johnson & Nathan Sobo
1280370fd1 Editor constructor requires an editSession (unless it is a mini buffer) 2012-06-20 09:28:23 -07:00
Corey Johnson & Nathan Sobo
4659fd7dc3 Project.open returns an editSession instead of a buffer.
First step in removing the coupling of Editor and Buffer. Editor should get all information about the active buffer from the activeEditSession.
2012-06-20 09:28:22 -07:00
Corey Johnson & Nathan Sobo
db69ee5627 Calculate gutter dimensions when editor's dimensions are calculated 2012-06-15 17:30:10 -07:00
Corey Johnson & Nathan Sobo
c73eb97d72 💄 2012-06-14 15:41:02 -06:00
Nathan Sobo
470f46931f Selection views update properly when selections are merged 2012-06-14 10:28:21 -06:00
Nathan Sobo
5135f3e066 Editor no longer references Renderer directly 2012-06-13 20:37:30 -06:00
Nathan Sobo
f000686f07 Method name 💄 2012-06-13 11:49:01 -06:00
Nathan Sobo
e5b5f7b886 Absorb cursor-spec into editor-spec 2012-06-13 11:04:17 -06:00
Nathan Sobo
b53686ed36 Move selection rendering specs from selection-spec to editor-spec 2012-06-13 10:19:24 -06:00
Nathan Sobo
09bfc1db92 Reorganize editor-spec more logically 2012-06-12 15:59:55 -06:00
Nathan Sobo
6317f9526f 💄 2012-06-12 15:49:49 -06:00
Nathan Sobo
3a93887292 Move structural folding to EditSession 2012-06-12 15:49:42 -06:00
Nathan Sobo
6a017ba666 Move all mouse event specs under one describe block 2012-06-12 15:33:25 -06:00
Nathan Sobo
efcc43c296 Merge branch 'master' of github.com:github/atom 2012-06-12 15:21:06 -06:00
Nathan Sobo
f87476b80b Streamline cursor movement specs in editor-spec 2012-06-12 15:20:15 -06:00
Nathan Sobo
918b8d95da Move some auto indent specs to edit-session-spec 2012-06-12 15:19:40 -06:00
Corey Johnson
e56e775d8d Merge branch 'dirty-buffer' 2012-06-12 14:13:23 -07:00
Nathan Sobo
b895122c24 Simplify Editor spec's mouse event integration specs
Test handling of non-corresponding buffer & screen positions in spec on setCursorScreenPosition in edit-session-spec instead of in editor-spec
2012-06-12 14:44:45 -06:00
Nathan Sobo
87bc5ad02a Make setBuffer spec lean on setActiveEditSessionIndex spec 2012-06-12 14:23:49 -06:00
Nathan Sobo
8a34ea20c4 Move undo/redo specs to edit-session-spec 2012-06-12 13:44:40 -06:00
Nathan Sobo
7b64066bf4 Remove stray console.log 2012-06-12 13:40:02 -06:00
Nathan Sobo
4f50a4735d Add specs for EditSession.proto.selectToScreenPosition. Move coverage of selection merging 2012-06-12 13:37:01 -06:00
Corey Johnson
a2f60c141b Remove logs from spec 2012-06-12 10:52:11 -07:00
Corey Johnson
e56ef733ad Add save alert when closing a modified buffer 2012-06-12 10:52:11 -07:00
Corey Johnson
0fec1fc5ba Don't close edit session when its buffer is modified 2012-06-12 10:52:11 -07:00