Commit Graph

2488 Commits

Author SHA1 Message Date
Nathan Sobo
2f60ffcfce Add ability to add panels to the config view 2013-04-26 15:32:47 -07:00
Nathan Sobo
8980a97895 Add atom.activatePackageConfig, which is called in config windows
This calls an optional `activateConfig` method on the package's main
module, which allows it to add a configuration interface to the
`configView`.
2013-04-26 15:32:47 -07:00
Nathan Sobo
9d2d3d5c00 Rename window methods to distinguish editor window from config window 2013-04-26 15:32:46 -07:00
Nathan Sobo
f62e81bca8 Add config.observeUserConfig 2013-04-26 15:32:46 -07:00
Nathan Sobo
ab1b90804e Add specs for successful calls to .loadUserConfig 2013-04-26 15:31:18 -07:00
Nathan Sobo
9fe264ded4 💄 2013-04-26 15:31:18 -07:00
Nathan Sobo
3a05731f2d Eliminate EditSession references from tokenized-buffer-spec 2013-04-25 17:16:51 -06:00
Nathan Sobo
9c7ff78fc8 Move language-specific integration tests to text-mate-grammar-spec 2013-04-25 17:15:27 -06:00
Nathan Sobo
4fdc9fba63 Eliminate EditSession dependencies in DisplayBuffer spec 2013-04-25 16:18:39 -06:00
Nathan Sobo
0d78098dbf Make TokenizedBuffer select its own grammar, not LanguageMode
This is part of an effort to disentangle LanguageMode, DisplayBuffer,
and TokenizedBuffer. It should be easy to create a DisplayBuffer
without creating an EditSession… let's get the dependencies flowing
in a single direction.
2013-04-25 15:13:00 -06:00
Nathan Sobo
0f623b3d08 Move structural folding logic to LanguageMode
DisplayBuffer should just focus on providing basic support for folding.
Scanning the structure of the code, looking at scopes, etc is more the
domain of the LanguageMode object.
2013-04-25 14:06:53 -06:00
Nathan Sobo
60f945aafd Move structural folding specs to edit-session-spec
Structural folding should really be handled at the edit session level
so that the DisplayBuffer doesn't need access to the LanguageMode. It
should only be concerned with the raw ability to create folds.
2013-04-25 14:06:53 -06:00
Nathan Sobo
ca3b0c97da 💄 getter renames 2013-04-25 14:06:52 -06:00
Kevin Sawicki
875555d933 Rename invisible class to invisible-character
Bootstrap defines this class with visibility: hidden
which we don't want since invisible characters should
be visible.
2013-04-25 10:02:33 -07:00
Kevin Sawicki
2803da2f8b Replace offsUtilscreen with offscreen 2013-04-24 17:59:50 -07:00
Kevin Sawicki
4e8c6e29ad Use @ instead of this. 2013-04-24 17:57:59 -07:00
Corey Johnson & Nathan Sobo
24ce415283 Move event listener calls from resetDisplay to edit
Fixes #140
2013-04-24 11:41:56 -07:00
probablycorey
9cc4c2e5de Allow off to be called before on without error
Previously calling `something.off 'event-name', handler` would throw
an error unless `on` was called first.
2013-04-24 11:41:56 -07:00
Kevin Sawicki
b65e1485a7 Copy folders to ~/.atom directory asynchronously 2013-04-24 10:12:30 -07:00
Kevin Sawicki
2f5a99fac2 Install atom command asynchronously 2013-04-24 10:12:29 -07:00
Corey Johnson & Nathan Sobo
9f235103f8 Add _.spliceWithArray to avoid stack overflows when splicing huge arrays 2013-04-23 11:16:55 -07:00
Kevin Sawicki & Nathan Sobo
125c41a2e2 Support space-separated event names in EventEmitter.on()/off() 2013-04-23 08:39:26 -07:00
Kevin Sawicki & Nathan Sobo
b9ad462c69 Retokenize when grammar with matching injection selector is updated 2013-04-23 08:39:26 -07:00
Kevin Sawicki & Nathan Sobo
0d35943386 Retokenize when grammar with matching injection selector is loaded 2013-04-23 08:39:26 -07:00
Kevin Sawicki
f0cf337857 Support grammars with an injectionSelector
These grammars can now contribute rules to other grammars when
their selector matches the current scope stack.
2013-04-23 08:39:26 -07:00
Kevin Sawicki
63d665e2cb Replace capture groups in pattern names with match 2013-04-23 08:39:25 -07:00
Nathan Sobo
35f0b7b49e Fix #505. Update grammars if any included grammars are updated. 2013-04-22 11:34:03 -06:00
Nathan Sobo
444325893b Allow subscribers to unsubscribe on a per-object basis
This makes use of the new ES6 WeakMap feature, which allows for a hash
map that's keyed by object.
2013-04-22 11:34:03 -06:00
Nathan Sobo
93910201b0 Re-tokenize buffer when its grammar is updated
This can happen if a grammar that the grammar includes is added or
removed from the syntax global.
2013-04-22 11:34:03 -06:00
Nathan Sobo
9204836d70 Update grammars when grammars they include are added/removed
If the Ruby on Rails grammar depends on HTML, but it isn't loaded, its
syntax highlighting won't include HTMl tokens. If we later load HTML,
we should update any buffer with the Rails grammar to reflect the
change. This commit changes grammars to memoize their initial rule and
repository. If an included grammar is added or removed, we clear the
memoized rules and emit a 'grammar-updated' event. Any tokenized
buffer that points to this grammar can then retokenize to reflect the
newly available/unavailable included grammar.
2013-04-22 11:33:59 -06:00
Kevin Sawicki
62c94959e1 Move injections spec to TextMateGrammar spec
This spec was previously in the TokenizeBuffer spec which
required having a PHP fixture and setting up an edit session
to verify a line could be tokenized which was unnecessary.
2013-04-19 10:58:35 -07:00
Kevin Sawicki & Nathan Sobo
1f4febcfaf Ignore child captures of captures with patterns 2013-04-19 10:58:35 -07:00
Kevin Sawicki
c63834924a Support patterns included in captures
Previously only the capture's name was considered when processing
tokens for capture indices.

Now the capture's patterns are matched against the captured region
if they exist.
2013-04-19 10:58:35 -07:00
Kevin Sawicki
9489ec6787 Add specs for & selectors 2013-04-19 10:58:35 -07:00
Kevin Sawicki & Nathan Sobo
1dffb9237a Use the earliest result when both injection and non-injection patterns match 2013-04-19 10:58:34 -07:00
Kevin Sawicki
c2eca1ff99 Add initial support for injection grammars
Build scope selectors and patterns when setting up the grammar
for all entries under the grammar's injection object.

Include the injection patterns in the scanner when the injection's
scope selector matches the current rule stack.
2013-04-19 10:58:34 -07:00
Kevin Sawicki
beeaa01d22 Support space-separated scopes in selector parser 2013-04-19 10:58:33 -07:00
Kevin Sawicki
3e5448b698 Add initial TextMate scope selector parser 2013-04-19 10:58:33 -07:00
Kevin Sawicki
4b48e07f83 Specify cwd instead of cd'ing 2013-04-18 20:41:17 -07:00
Kevin Sawicki
b5474790cb Remove unused imports 2013-04-18 20:18:37 -07:00
Garen Torikian
42290e87f8 80 is good. 2013-04-18 18:51:46 -07:00
Garen Torikian
cabee75f8a 💄 2013-04-18 15:02:22 -07:00
Garen Torikian
0acccc383e Remove test for folder not documented 2013-04-18 13:24:55 -07:00
Garen Torikian
130baf2235 Merge branch 'master' into api/docs 2013-04-17 16:08:18 -07:00
Nathan Sobo
fff4531663 Fix select-list auto-scrolling specs 2013-04-15 20:45:55 -06:00
Nathan Sobo
bc03810589 Set height on image view, not parent
Setting the height of the parent caused #jasmine-content to be tall
for the remainder of the specs
2013-04-15 20:45:55 -06:00
Nathan Sobo
d82daeccee Fix jasmine styling 2013-04-15 20:45:55 -06:00
Garen Torikian
4c56e8bb57 Merge branch 'master' into api/docs 2013-04-14 09:43:06 -07:00
Kevin Sawicki
7b42e975fb Include hidden files when running nak 2013-04-12 11:48:44 -07:00
Kevin Sawicki
4e59605728 Don't bubble move-to-top/bottom events
This will cause the editor to scroll as well when a select
list is a child of an editor such as in the autocomplete view.
2013-04-11 10:39:19 -07:00