Nathan Sobo
20daed176b
Don't show invisibles in mini editors
...
This moves observation of the config keys to Editor, which assigns the
invisibles hash or null on the TokenizedBuffer via the DisplayBuffer to
control whether we render invisibles or not.
2014-08-13 16:32:14 -06:00
Nathan Sobo
94f40f0ed9
Only allow ReactEditorView::beforeRemove to run once
2014-08-12 17:40:53 -06:00
Nathan Sobo
2911b395ee
Handle 'focus' events in ReactEditorView and transfer to the component
...
Fixes #3234
2014-08-12 17:15:19 -06:00
Nathan Sobo
64c25f17df
Shim ReactEditorView::mini property
2014-08-12 17:15:19 -06:00
Ben Ogle
8b20e2e031
Remove duplicate getModel()
2014-08-12 15:32:18 -07:00
Ben Ogle
4cf68ef017
::getModel() returns the editor
2014-08-12 15:29:47 -07:00
Nathan Sobo
0f77a2eef9
Only unmount ReactEditorView's component before removing if its mounted
...
Fixes #3108
Unmounting the component the first time can cause a focusout event,
which leads to a redundant removal and an attempt to unmount again. This
protects against that.
2014-07-29 20:02:01 -06:00
Nathan Sobo
3a9aa80914
Add ReactEditorView::lineElementForScreenRow shim
2014-07-28 11:36:40 -06:00
Nathan Sobo
37165f3293
Invoke pollDOM after attach so character width is calculated
...
Now that we mount the react component in the constructor of the wrapper
view, it's never actually visible at the time of mount. By invoking
pollDOM manually after attaching and before emitting the attach event,
the character width is available for the wrap guide to calculate its
initial position.
2014-07-24 18:12:02 -07:00
Nathan Sobo
c9587a8638
Mount EditorComponent as soon as ReactEditorView is constructed
...
...instead of waiting for it to be attached. This makes it simpler to
get shim references when using ReactEditorView for mini editors.
2014-07-24 12:57:12 -07:00
Ben Ogle
2e4893c786
Be more defensive in ReactEditorView::activate
...
It is conceivable that a package could have a reference to a view
that is not within a pane.
Fixes #2853
2014-07-22 10:37:37 -07:00
Nathan Sobo
0c4da92d6b
Handle hide and show entirely in the wrapper view
...
Enable sync updates and manually invoke the pollDOM function on the
component when we call hide/show on the wrapper view. This ensures that
we perform initial measurements when showing the editor for the first
time.
2014-07-21 14:09:16 -07:00
Nathan Sobo
df7f816c88
Move 'editor-colors' to wrapper view to support padding on mini editors
2014-07-21 13:43:00 -07:00
Nathan Sobo
4a8ac85ffb
Restrict ReactEditorView::getPane implementation
2014-07-21 10:43:32 -07:00
Nathan Sobo
c4177aba3e
Handle 'attributes' param to ReactEditorView
2014-07-21 10:43:31 -07:00
Nathan Sobo
3206fdce9e
Add ReactEditorView::setPlaceholderText shim
2014-07-21 10:43:31 -07:00
Nathan Sobo
4020ed1535
Support ReactEditorView construction with params hash
2014-07-21 10:43:30 -07:00
Ben Ogle
88df674dd6
Move gutter member into a showLineNumbers observe block
2014-07-10 18:04:53 -07:00
Ben Ogle
36280bb3a7
Add noop for resetDisplay
...
fixes #2674
2014-06-23 17:46:35 -07:00
Nathan Sobo
7c356d2592
Revert "Render highlights on their own layer to avoid GPU artifacts"
2014-06-21 01:58:11 -06:00
Nathan Sobo
df8d014e3c
Add a dedicated underlayer to avoid GPU artifacts on wrap guide etc
...
Trying to make the .highlights layer double as the .underlayer was
causing GPU artifacts on the wrap guide when the last highlight was
removed. This puts it in its own layer to avoid that.
2014-06-20 16:33:08 -06:00
Nathan Sobo
17f9cc49f2
Honor the center: true option in scrollTo* methods
...
Fixes #2648
2014-06-18 21:48:14 -06:00
probablycorey
468c6598db
Make sure the overlayer class is only used once.
...
Using it twice causes context menus with the .overlay selector to
appear twice.
Closes #2601
2014-06-18 13:24:15 -07:00
Ben Ogle
084632a985
Rename Selection(s)Component to Highlight(s)Component
2014-06-16 15:36:08 -07:00
Corey Johnson
4186a4943b
Remove react shims deprecations
2014-06-12 14:53:09 -07:00
Corey Johnson
4f77a371f4
Merge pull request #2497 from atom/cj-add-react-editor-shims
...
Add shims to the React View Editor
2014-06-11 09:06:40 -07:00
Ben Ogle
09b91974a7
Fix casing on Grim import
2014-06-11 08:52:36 -07:00
Nathan Sobo
64870c733b
Add API for enabling/disabling input to support vim-mode's insert mode
2014-06-11 06:07:41 -06:00
probablycorey
9e7e77bdf8
Merge remote-tracking branch 'origin/master' into cj-add-react-editor-shims
...
Conflicts:
src/gutter-component.coffee
2014-06-10 15:42:23 -07:00
probablycorey
f9c4af301d
Shim scrollView outlet
2014-06-10 15:19:54 -07:00
Corey Johnson
a227ed7586
Add toggleSoftWrap and toggleSoftTabs
2014-06-09 16:10:29 -07:00
Corey Johnson
0396aac11f
Add several setter shims to ReactEditorView
2014-06-09 16:03:20 -07:00
Corey Johnson
7379627fcb
Add several scroll shims to ReactEditorView
2014-06-09 15:37:02 -07:00
Corey Johnson
a2c4caf7ad
Move scroll methods below afterAttach method
2014-06-09 15:14:48 -07:00
Corey Johnson
e8b6fb919e
Add shim for ReactEditorView::redraw
2014-06-09 15:06:49 -07:00
Corey Johnson
601c877136
Add pageDown/pageUp to ReactEditorView
2014-06-09 14:46:47 -07:00
Ben Ogle
e7bd8026d2
Deprecate old class functions
2014-06-09 14:04:23 -07:00
Corey Johnson
362f696e3e
Add setFontFamily and setFontSize to ReactEditorView
2014-06-09 13:51:00 -07:00
Corey Johnson
677d3abe0e
Add ::getFontFamily
2014-06-09 13:51:00 -07:00
Nathan Sobo
8cf9e1990b
Add ReactEditorView::getModel shim
2014-06-09 13:47:36 -06:00
Nathan Sobo
b2253ab7ce
Add ReactEditorView::insertText shim
2014-06-09 13:32:42 -06:00
Nathan Sobo
6f3ebe8d0c
Add ReactEditorView::hiddenInput shim
2014-06-09 15:16:38 +09:00
Nathan Sobo
2f3d74c047
Merge branch 'master' into cj-add-react-editor-shims
...
Conflicts:
src/react-editor-view.coffee
2014-06-06 23:59:54 +09:00
Nathan Sobo
cae5cdc81c
Put the .editor class on the wrapper, not the component
...
Things depend on the react editor wrapper having the .editor class,
but inside the editor, we can control the style. I changed the
component's div to be .editor-contents for now. We can eliminate this
extra style when we eliminate the wrapper.
2014-06-06 23:52:35 +09:00
Nathan Sobo
fca6a7758b
Don't run afterAttach hooks twice on ReactEditorView
2014-06-06 16:46:14 +09:00
Nathan Sobo
7dae04b8d4
Add ReactEditorView::getText
2014-06-06 16:46:14 +09:00
Corey Johnson
d7ee81418d
Remove editor class form ReactEditorView, it is on EditorComponent
...
I couldn’t recreate the problem with activation events mentioned
fa66689c07
2014-06-05 14:13:41 -07:00
Nathan Sobo
2ee2efeb84
Add ReactEditorView::isFocused shim
2014-06-05 12:07:52 +09:00
Nathan Sobo
367e429162
Add ReactEditorView::setText
2014-06-05 12:03:56 +09:00
Nathan Sobo
8417dfd10e
Add the ReactEditorView::updateDisplay shim
2014-06-05 12:01:09 +09:00