Commit Graph

3921 Commits

Author SHA1 Message Date
probablycorey
6880368a79 Add soft wrap support to invisibles 2014-05-20 11:49:31 -07:00
probablycorey
c999a6e0e4 Show carriage return invisibles 2014-05-20 10:38:01 -07:00
probablycorey
2bbf5c7800 Remove unnecessary spec 2014-05-20 10:37:24 -07:00
probablycorey
273203e4c9 Fix typo 2014-05-20 10:37:02 -07:00
probablycorey
9b5593d020 Put EOL invisibles into their own scope 2014-05-19 17:27:59 -07:00
probablycorey
8b4cff474f Spec 💄 2014-05-19 17:10:04 -07:00
probablycorey
73ce81d597 Pass invisibles down to lines component 2014-05-19 16:56:53 -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
bfc382c398 Add specs for line/line-number preservation 2014-05-19 14:33:17 -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
Corey Johnson
9ca506de4b Merge pull request #2173 from Locke23rus/issue-1791
💄 Deprecate backspaceToBeginningOf{Word,Line}
2014-05-16 15:13:44 -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
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
b000e8e4a2 Get selection specs passing again 2014-05-16 15:31:16 -06:00
Nathan Sobo
64c82f1c87 Update cursor positioning text for simplified token markup 2014-05-16 15:31:15 -06:00
Nathan Sobo
0ad2730353 Update specs for new line node rendering approach
Lines are no longer translated on the GPU, and they aren't inserted into
the DOM in an order that reflects their order in the buffer.
2014-05-16 15:31:15 -06:00
Nathan Sobo
070d239f41 Blink cursors with a CSS animation
Now that they're on their own layer, I don't think it affects the
repaint timing when typing on lines (if it ever did).
2014-05-16 15:31:13 -06:00
Nathan Sobo
9001d34ddf Change selection specs to match new rendering scheme 2014-05-16 15:31:13 -06:00
Nathan Sobo
e44027b186 Fix the height/width of the editor in spec
Now that everything is absolutely position, the editor no longer assumes
a "natural" height and width. This can be addressed later if we want to
allow editors to expand based on their content.
2014-05-16 15:31:13 -06:00
Nathan Sobo
d53f97ecfe Fix horizontal scrolling spec 2014-05-16 15:31:13 -06:00
Nathan Sobo
f3efd7d60b Position cursors relative to scrollLeft and fix specs 2014-05-16 15:31:12 -06:00
Nathan Sobo
8d25da9474 Update line number rendering specs for new layer scheme 2014-05-16 15:31:12 -06:00
Nathan Sobo
1aee276b45 Update line rendering specs for new layer scheme 2014-05-16 15:31:12 -06:00
Nathan Sobo
3f1ce617a7 Try to fix flaky spec 2014-05-16 15:05:49 -06:00
Kirill Nikitin
8918eb4758 Bug #1791 Fix typo in example group name and function names. 2014-05-16 23:05:05 +04:00
Nathan Sobo
f2c7d171bf Fix another subscription leakage associated with theme manager specs 2014-05-16 09:14:21 -06:00
Nathan Sobo
7a4a85cb20 Fix failures running config specs locally 2014-05-16 09:00:01 -06:00
Nathan Sobo
ce668e7139 Fix subscription leak when ~/.atom/styles.less is present running specs 2014-05-16 08:33:49 -06:00
Kirill Nikitin
917b223c6c merge conflict 2014-05-16 11:45:43 +04:00
Corey Johnson
25f5717ccf Merge pull request #1971 from abe33/feature_proper_multiselections_copy_paste
Implements multiple selections clipboard paste
2014-05-12 11:10:37 -07:00
Kirill Nikitin
111b5d1fbe 💄 Deprecate backspaceToBeginningOf{Word,Line}
Rename functions `backspaceToBeginningOfWord` to `deleteToBeginningOfWord` and
`backspaceToBeginningOfLine to `deleteToBeginningOfLine`.
Rename commands `editor:backspace-to-beginning-of-word` to
`delete-to-beginning-of-word` and `editor:backspace-to-beginning-of-line` to
`editor:delete-to-beginning-of-line`.

Fix #1791
2014-05-12 02:50:20 +04:00
abe33
b2e86c80c4 Change test to cover all Selection::copy branches 2014-05-12 00:06:13 +02:00
Nathan Sobo
76b9982e04 Emit stylesheet-added/removed from ThemeManager w/ CSSStyleSheet objects
This enables subscribers to detect not just that stylesheets have
changed, but specifically how they have changed. This is used by the
React editor component to only refresh scrollbars when a stylesheet
that actually contains selectors for scrollbar elements is added or
removed.
2014-05-09 11:33:04 -06:00
Nathan Sobo
1c1ace90db Hide and show scrollbars before measuring them after stylesheet changes
We measure the scrollbar-corner node when there's a stylesheet change,
but Chromium won't apply the new style if it was already visible before
the change. This commit hides and shows it before measuring so we get
accurate values.
2014-05-09 11:33:04 -06:00
Nathan Sobo
bdd605e85b Explicitly assign dummy scrollbars to the correct width/height
Previously, dummy scrollbars were always 15px wide/tall. This caused
them to obscure the ability to click for the entire 15px region, even if
the actual scrollbar was styled to be much thinner. Now we explicitly
measure the size of scrollbars on mount and when the stylesheets change
and set the height/width explicitly.
2014-05-09 11:33:04 -06:00
Nathan Sobo
e1b4b921ba Hide scrollbar when not scrollable in a given direction 2014-05-09 11:33:04 -06:00
Nathan Sobo
ab1ede5fe6 Add a dummy scrollbar corner
Horizontal / vertical scrollbars render a 'corner' on the lower right
when they would otherwise overlap. I previously relied on drawing both
dummy scrollbars at their full width/height so the corner got rendered,
but that interfered with the display of the horizontal scrollbar in
certain circumstances because it was too wide to scroll. This commit
provides that behavior with an absolutely positioned div with the same
dimensions as the intersection of scrollbars when both are visible.
2014-05-09 11:33:04 -06:00
Nathan Sobo
5e6d91d66c Don't allow spec window size to interfere with the size of the editor 2014-05-09 11:33:04 -06:00
Nathan Sobo
dbd271f70a Don't obscure last character of long lines with vertical scrollbar
This entailed quite a few changes to dial in scrollbars. The scrollbars
are now adjusted in size to account for the width of the opposite
scrollbar. If the width or height are not explicitly constrained and we
are scrollable in the opposite direction that is constrained, we account
for the width of the opposite scrollbar in assigning a natural height
or width based on the content.
2014-05-09 11:33:04 -06:00
Nathan Sobo
527ada47f9 Account for gutter width in scrollWidth of horizontal scrollbar
Because the scrollbar now spans the entire editor but the scrollable
area does not include the gutter, we need to add the current width of
the gutter to the scroll width of the horizontal scrollbar to allow
it to scroll to the end of the longest lines.
2014-05-09 11:33:03 -06:00
Nathan Sobo
afb70d0a95 Remove stray return in spec 2014-05-09 11:33:03 -06:00
Nathan Sobo
b5f910ad06 Update line number padding when max digits changes 2014-05-09 11:33:03 -06:00
Nathan Sobo
7b4bc16531 Fix specs that broke when accounting for horizontal scrollbar height 2014-05-09 11:33:03 -06:00
Nathan Sobo
e6df30e94c Respect horizontal scrollbar when rendering the vertical, and vice versa
We set overflow to hidden in the opposite scroll direction only if we
can't actually scroll in that direction, causing the white square where
neither scrollbar overlaps to appear at the lower right corner.
2014-05-09 11:33:03 -06:00
Nathan Sobo
d9ba9262bf Update scrollTop to valid position when scrollbar disappears 2014-05-09 11:33:03 -06:00
Nathan Sobo
c4be32a5dd Revert "Revert "Don't obscure the last line of the editor with the horizontal scrollbar""
This reverts commit 1d634e471e.
2014-05-09 11:33:03 -06:00
abe33
ed1c8897ec 😅 Forgot to remove the test focus 2014-05-09 00:07:00 +02:00
abe33
554165ca48 💄 Harmonize lineForRow calls in specs 2014-05-09 00:02:31 +02:00