Rafael Oleza
a93808d1a8
Always use global it, beforeEach and afterEach methods
2019-02-28 20:39:21 +01:00
Rafael Oleza
2dd2c299b3
Keep unneeded block in TextEditor spec as it's a common pattern
2019-02-28 19:30:03 +01:00
Rafael Oleza
6c46cf9243
Fix remaining linter issues
2019-02-28 19:30:03 +01:00
Rafael Oleza
d7d6d0838f
Remove unused vars from specs
2019-02-28 19:30:03 +01:00
Rafael Oleza
c35ec012b4
Run prettier on spec/ folder
2019-02-28 19:30:03 +01:00
Ash Wilson
0a541eb552
Unit test for block decoration ordering
2019-02-01 13:13:49 -05:00
Ash Wilson
51cfc262c6
Pass an order
property to test fixture block decorations
2019-02-01 13:12:47 -05:00
Ash Wilson
d7d6a33e08
Compute expected soft wrap column
2018-09-21 14:47:44 -04:00
Ash Wilson
39bc295f1c
Test soft wrap column measurement with a custom gutter
2018-09-21 13:14:47 -04:00
Max Brunsfeld
467415af19
Merge branch 'master' into wl-rm-safe-clipboard
2018-08-24 11:57:36 -07:00
Ash Wilson
e04da46e8a
Quick spec for line number rendering
2018-08-21 16:59:48 -04:00
Ryan Holinshead
a280019847
Add spec to test that updateClassList does not blow away the managed class names (editor, is-focused, mini) when the element class names are changed.
...
Released under CC0
2018-07-16 14:58:39 -07:00
Max Brunsfeld
0148ee7d9b
Always leave room for scrollbars
2018-06-07 14:42:06 -07:00
Max Brunsfeld
70cf900ac0
Make TextEditorComponent tests reliably pass on retina screens
2018-06-07 14:09:31 -07:00
Antonio Scandurra
26837d65b4
Clip cursor width when soft-wrap is on and cursor is at the end of line
...
This prevents the parent tile from disabling sub-pixel anti-aliasing.
For some reason, adding `overflow: hidden` to the cursor container
element doesn't solve the issue, so we're adding this workaround
instead.
2018-03-13 12:04:35 +01:00
Linus Eriksson
a790f1e3ec
Randomize fontSize and lineHeight in the random test
...
This causes the failure fixed by https://github.com/atom/atom/pull/15831
to be caught by the randomized test more easily
2018-03-05 17:24:19 +01:00
Nathan Sobo
e334f0419f
Merge pull request #16753 from billyjanitsch/revert-15487
...
Stop scaling up small scroll wheel events
2018-02-16 11:58:33 -08:00
Linus Eriksson
63326e969a
Unfocus test and always return false to see if this fails on circle
2018-02-15 22:53:29 +01:00
Linus Eriksson
ad6b2131d6
Style the scrollbar in the test
2018-02-15 22:47:33 +01:00
Linus Eriksson
3059d14bd7
Merge remote-tracking branch 'origin/master' into b3-failing-seed
2018-02-15 19:49:58 +01:00
Billy Janitsch
a433e974eb
Stop scaling up small scroll wheel events
2018-02-15 10:42:57 -08:00
Wliu
7e0635d2c0
Fix spec
2018-01-26 18:41:57 -05:00
Wliu
be24e6edf7
Revert change to move mouse cursor on right-click
2018-01-24 11:22:41 -05:00
David Wilson
6d09a5257a
Fix #16538 : Middle-click pastes into read only editor on Linux
...
This change fixes an issue where users on Linux are able to paste into
read only TextEditors by clicking the middle mouse button. The fix is
to check for whether the TextEditorComponent's isInputEnabled method
returns true before pasting with middle click on Linux.
2018-01-22 18:50:07 -08:00
Antonio Scandurra
8e74d06f64
Fix tests
2018-01-20 11:09:26 +01:00
Linus Eriksson
04507e9ee2
Use nested arrays instead of Range
2018-01-19 19:09:54 +01:00
Linus Eriksson
e07a9a6387
Merge branch 'master' of https://github.com/atom/atom into b3-failing-seed
2018-01-19 19:08:21 +01:00
Wliu
cd84216f11
Merge branch 'master' into wl-rm-safe-clipboard
2018-01-09 21:39:04 -05:00
Nathan Sobo
4926fe466c
Move highlights container into lines for theme compatibility
2018-01-08 13:16:46 -07:00
Wliu
a1668fc953
Remove old clipboard workaround on Linux
2018-01-04 20:59:32 -05:00
Antonio Scandurra
69799d35b2
Delete Chrome 56 workarounds
2017-12-22 14:44:17 +01:00
Wliu
db392502e4
Always move the cursor on middle-click
2017-12-05 23:54:43 +01:00
Max Brunsfeld
e08091f193
Make assignLanguageMode take a language id instead of a language name
2017-11-28 11:14:29 -08:00
Max Brunsfeld
20bf705000
Destroy editors after text editor component specs
...
This only now became necessary because TokenizedBuffer now *always*
receives a reference to the Atom config on construction, and always
tries to read from it when isFoldableAtRow is called, which can happen
after test cleanup due to resize observers.
2017-11-20 11:59:21 -08:00
Max Brunsfeld
f6c2e0eba4
Allow setting the null language mode w/ assignLanguageMode(buffer, null)
2017-11-20 09:48:00 -08:00
Max Brunsfeld
3d5cc6993c
Merge branch 'master' into mb-use-language-mode-api
2017-11-17 14:03:37 -08:00
Max Brunsfeld
91d4f53b28
Use assignLanguageMode in TextEditorComponent spec
2017-11-15 17:15:32 -08:00
Max Brunsfeld
653ecd7f52
Merge branch 'master' into mb-use-language-mode-api
2017-11-15 12:52:36 -08:00
Wliu
a59913f51c
Update specs
2017-11-15 21:49:43 +01:00
Wliu
22d8ae67df
Merge branch 'master' into b3-failing-seed
2017-11-12 13:27:28 +01:00
Linus Eriksson
9f83c4b15b
And don't focus the test
2017-11-06 23:55:24 +01:00
Linus Eriksson
bea8094765
Make the tests pass
2017-11-06 23:53:55 +01:00
Max Brunsfeld
e6c3891e62
Assign a language mode in text editor component specs
2017-11-03 15:08:02 -07:00
Nathan Sobo
f25570f135
Exclude Shift from keydown events that terminate selection drags
2017-11-01 14:00:43 -06:00
Nathan Sobo
11511f27d5
Don't terminate selection dragging when a modifier key is pressed
...
This preserves the ability to add selections via ctrl- or cmd-click.
2017-11-01 09:22:38 -06:00
Justin Ratner
ed94726fab
fix overlayComponent access syntax in test
2017-10-23 14:32:34 -06:00
Justin Ratner
089717cbd3
fix failing test
2017-10-20 15:46:27 -06:00
Linus Eriksson
612feb7cea
Fix the randomized test
2017-10-19 21:46:09 +02:00
Linus Eriksson
c1c9d3f75f
Handle edits that scroll up due to hiding the horizontal scrollbar
2017-10-19 21:39:59 +02:00
Antonio Scandurra
65af9e953b
Stop dragging only when user interacts with keyboard
...
Previously, we used to prevent the user from dragging the selection
further when the buffer was about to change. This was problematic
because any change in the buffer, even one that was performed
"automatically" by a package, would cancel the dragging action and
result in a confusing experience for the user.
On the other hand, we want to prevent users from accidentally selecting
text when they perform an edit (see #15217 , #15405 ).
This commit addresses both concerns by canceling the dragging as soon as
the user interacts with the keyboard, instead of canceling the dragging
when the buffer is about to change.
One downside of this approach is that it changes the behavior of
pressing a keystroke that does not result in a buffer change, e.g.
Shift, Arrow Keys, etc.
Signed-off-by: Jason Rudolph <jasonrudolph@github.com>
2017-10-17 18:50:20 +02:00