Commit Graph

8431 Commits

Author SHA1 Message Date
Nathan Sobo
9278920093 Merge branch 'master' into cj-add-invisibles-to-react-editor
Conflicts:
	src/editor-component.coffee
2014-05-20 17:03:14 -06:00
probablycorey
ece868c9de Concat strings instead of joining an Array 2014-05-20 15:16:07 -07:00
Nathan Sobo
ac993680db Remove stray logging 2014-05-20 15:27:28 -06:00
probablycorey
25e3ae0325 Re-render the lines when the showInvisible config option is triggered 2014-05-20 13:58:22 -07:00
Nathan Sobo
2ae7cba452 Don't blink cursors with CSS animation
It seems to create intermittent lags when moving the cursor and typing.
2014-05-20 14:04:59 -06:00
probablycorey
2f038cbe66 Update lines component when invisibles changes 2014-05-20 12:34:18 -07:00
probablycorey
6880368a79 Add soft wrap support to invisibles 2014-05-20 11:49:31 -07:00
probablycorey
1e6e804ebb Use screen line count to determine renderedEndRow 2014-05-20 11:37:32 -07:00
Nathan Sobo
6fef8de63e Merge pull request #2284 from pritambaral/react-paste
Ignore paste in react editor, Fixes #2186
2014-05-20 11:50:26 -06:00
probablycorey
c999a6e0e4 Show carriage return invisibles 2014-05-20 10:38:01 -07:00
Cheng Zhao
6fa6863244 Don't popup context menu with no items, fixes #2032.
On OS X popuping an empty context menu would have no effect but on Linux
an empty menu container would still be showed.
2014-05-20 22:36:51 +08:00
Nathan Sobo
0ad26c337a Don't use _.pluck when building TokenizedLines 2014-05-19 22:20:57 -06:00
Nathan Sobo
353eb27d2e Update dataset screenRow of gutter nodes when updating them 2014-05-19 21:34:06 -06:00
Nathan Sobo
6edb0b7a3d Delete dead method 2014-05-19 21:32:26 -06:00
Nathan Sobo
cd5f0c0047 Update the screenRow on the line element's dataset in ::updateLineNode 2014-05-19 21:32:26 -06:00
probablycorey
9b5593d020 Put EOL invisibles into their own scope 2014-05-19 17:27:59 -07:00
probablycorey
4d642b91ef Only pass invisibles through to the line component if needed 2014-05-19 17:10:36 -07:00
probablycorey
73ce81d597 Pass invisibles down to lines component 2014-05-19 16:56:53 -07:00
probablycorey
09e4c585aa Add setInvisibles method 2014-05-19 16:56:17 -07:00
probablycorey
cbe07b49aa Add basic invisible specs 2014-05-19 16:20:51 -07:00
Nathan Sobo
d2bc7ab192 Merge pull request #2258 from atom/ns-react-scroll-perf
Improve scroll performance of the React editor
2014-05-19 14:42:18 -06:00
Nathan Sobo
795399e184 Preserve the target when scrolling w/ mousewheel on editor lines 2014-05-19 14:17:09 -06:00
Nathan Sobo
37bdfb716b Preserve the target when scrolling w/ mousewheel in gutter
Removing the target of a mouseweel event messes up velocity scrolling
with the track pad, so it needs to be preserved until scrolling ceases.
2014-05-19 14:03:34 -06:00
Kevin Sawicki
314833bbac Add missing parens on indent guide check
Previously the indent guide was always showing on the whitespace only lines

Closes #2274
2014-05-19 08:52:06 -07:00
Pritam Baral
c7461f476e Ignore paste in react editor, Fixes #2186 2014-05-18 04:17:21 +05:30
Nathan Sobo
8e65d30a84 Compute rendered row range once in EditorComponent and pass it down 2014-05-16 20:58:40 -06:00
Corey Johnson
9ca506de4b Merge pull request #2173 from Locke23rus/issue-1791
💄 Deprecate backspaceToBeginningOf{Word,Line}
2014-05-16 15:13:44 -07:00
probablycorey
532f119b9d Add application:install-update to workspaceView 2014-05-16 15:05:19 -07:00
Nathan Sobo
c058483422 Update the gutter width when the number of digits changes 2014-05-16 15:56:18 -06:00
Nathan Sobo
57e6419d1d Restore conditional loading of react editor renderer 2014-05-16 15:31:16 -06:00
Nathan Sobo
9b7547cbe0 Get indent guide specs passing again 2014-05-16 15:31:16 -06:00
Nathan Sobo
e74dfe3438 Fix gutter specs and update lines when digit counts change 2014-05-16 15:31:16 -06:00
Nathan Sobo
fe82e3e30f Only clear screen row caches on lines component if lineHeight changes 2014-05-16 15:31:16 -06:00
Nathan Sobo
6017b73acf Add ability to look up line nodes by screen row 2014-05-16 15:31:15 -06:00
Nathan Sobo
0334177696 Make lineOverdrawMargin a property 2014-05-16 15:31:15 -06:00
Nathan Sobo
54cec0a5ff Hold the gutter's width with a dummy line number 2014-05-16 15:31:15 -06:00
Nathan Sobo
c5fa2bf12d Attach views to .lines instead of defunct .scroll-view-content 2014-05-16 15:31:15 -06:00
Nathan Sobo
bc8a1756f3 Use the .selections layer as the underlayer 2014-05-16 15:31:15 -06:00
Corey Johnson & Nathan Sobo
3f01e2f748 Implement shouldComponentUpdate for SelectionsComponent 2014-05-16 15:31:15 -06:00
Nathan Sobo
7dfe829fc8 Style lines with inline styles for performance 2014-05-16 15:31:15 -06:00
Nathan Sobo
c87bc57f9e Don't update top positions of lines/lineNodes unless they have changed 2014-05-16 15:31:15 -06:00
Nathan Sobo
89bd241a78 Always run react in dev mode for now 2014-05-16 15:31:14 -06:00
Nathan Sobo
d15fd34f7a Render selections on lines layer; don't put each line number on GPU 2014-05-16 15:31:14 -06:00
Nathan Sobo
a118cdd32b Put selections and lines on the GPU together in sibling divs 2014-05-16 15:31:14 -06:00
Nathan Sobo
3a2de9c698 Don't render every line on the GPU
Opaque lines are turning out to be a total pain, plus they ruin absolute
positioning on the lines div. The slight speed boost isn't seeming worth
it anymore.
2014-05-16 15:31:14 -06:00
Nathan Sobo
c60e5d90fd 💄 2014-05-16 15:31:14 -06:00
Nathan Sobo
e9bff37e06 Render line numbers manually 2014-05-16 15:31:14 -06:00
Nathan Sobo
695f8da3c3 💄 extract buildLineInnerHTML method 2014-05-16 15:31:14 -06:00
Nathan Sobo
ea5c5c9e84 Move line HTML generation into lines component 2014-05-16 15:31:14 -06:00
Nathan Sobo
4f9108980f WIP: Manually update line nodes when scrolling 2014-05-16 15:31:14 -06:00