Commit Graph

118 Commits

Author SHA1 Message Date
Indrek Ardel
55f3311c01 Remove unused variables 2016-09-26 20:52:13 +03:00
Antonio Scandurra
544b75c7b0 🔥 💚 Fix TokenizedBuffer specs 2016-04-05 12:19:45 +02:00
Antonio Scandurra
27aad42644 Handle tab length retokenization in DisplayLayer
We still want to keep the tab length in TokenizedBuffer, because we need
it to understand if a certain buffer row is foldable or not (due to the
indent level)
2016-03-25 10:33:12 +01:00
Antonio Scandurra
8f2ebe8b79 🔥 2016-03-21 17:46:58 +01:00
Nathan Sobo
5aba734a41 Remove specialTokens object from TokenizedLine 2016-03-18 19:21:12 -06:00
Nathan Sobo
b0c5870425 Remove dead code from TokenizedLine 2016-03-18 18:15:41 -06:00
Nathan Sobo
1994e3b404 Remove TokenizedLine::copy 2016-03-18 18:10:04 -06:00
Nathan Sobo
462157039b Drop indentLevel and soft wrap support from TokenizedLine 2016-03-18 18:09:23 -06:00
Antonio Scandurra
dfed7c4537 Merge branch 'master' into ns-use-display-layers
# Conflicts:
#	package.json
#	src/display-buffer.coffee
#	src/text-editor.coffee
#	src/tokenized-buffer.coffee
2016-03-10 13:53:14 +01:00
Koki Takahashi
fdac1e4663 🐛 Treat empty comment line as comment and add tests (Fix #4140) 2016-02-29 19:51:57 -07:00
Antonio Scandurra
2a35d19dd3 🐎 Memoize TokenizedLine.prototype.isComment 2016-02-17 16:00:35 +01:00
Antonio Scandurra
bea324eae9 🔥 Use just isFoldableAtBufferRow 2016-02-17 15:05:31 +01:00
Nathan Sobo
0d55a0bd76 Make TokenizedBuffer conform to text decoration layer interface 2016-01-13 18:22:04 -07:00
Antonio Scandurra
12376039a9 🎨 cjk -> CJK 2015-12-11 14:28:26 +01:00
Antonio Scandurra
173fbba02b Wrap at the first CJK character before the boundary 2015-12-11 14:26:51 +01:00
Antonio Scandurra
c22cae451b Wrap line at boundary if it includes a CJK character 2015-12-10 10:18:24 +01:00
Antonio Scandurra
e843c2f058 🐎 Fetch scopes only if required 2015-10-16 11:03:15 +02:00
Nathan Sobo
1223d7a154 Process closing scopes at wrap boundaries 2015-08-11 13:13:30 -06:00
Nathan Sobo
36d55c9384 Don’t break out soft tabs that are interrupted by a scope boundary 2015-06-08 22:56:32 +02:00
Nathan Sobo
4812dcc355 Include invisibles in TokenizedLine::copy 2015-06-02 00:02:34 +02:00
Nathan Sobo
865015e47d Correctly compute bufferDelta for last soft wrap line segment
Fixes #6885
2015-05-21 19:56:53 +02:00
Nathan Sobo
321d310e8a Avoid more allocations in transformContent 2015-05-21 19:56:53 +02:00
Nathan Sobo
b4444df442 Minimize substring calls and concatenation in transformContent 2015-05-21 19:56:53 +02:00
Nathan Sobo
2379b3803f Revert "Revert "Merge pull request #6757 from atom/ns-less-memory-for-tokens""
This reverts commit 7cb0bc3bc2.
2015-05-21 19:56:52 +02:00
Nathan Sobo
7cb0bc3bc2 Revert "Merge pull request #6757 from atom/ns-less-memory-for-tokens"
This reverts commit 0cd1f110b5, reversing
changes made to d75d202d33.

Conflicts:
	package.json
2015-05-21 16:25:23 +02:00
Nathan Sobo
2beb6c0fe0 Pass TokenIterator reference instead of using global singleton
Adds an extra reference to each tokenized line but is also more sane.

/cc @maxbrunsfeld
2015-05-20 19:29:38 +02:00
Nathan Sobo
a109b3811c Add TokenizedLine::getTokenIterator
This will not be part of the public API but will replace another
non-public API usage in autocomplete-plus.
2015-05-19 23:19:45 +02:00
Nathan Sobo
1923033198 Fix spurious lint error by rearranging syntax 2015-05-16 00:12:43 +02:00
Nathan Sobo
64c0ef8bd8 Remove more usages of tokens shim 2015-05-14 01:46:49 +02:00
Nathan Sobo
0eb97e6a96 Use TokenIterator for position translation 2015-05-14 00:33:27 +02:00
Nathan Sobo
da2df2297a Add a TokenIterator and use it for tokens shim 2015-05-14 00:15:31 +02:00
Nathan Sobo
a7550666dd Remove dead code 2015-05-13 22:50:05 +02:00
Nathan Sobo
dc473698a9 🎨 2015-05-13 22:03:29 +02:00
Nathan Sobo
00b30f7db8 Remove some dead code 2015-05-13 22:03:26 +02:00
Nathan Sobo
d7f5588904 Generate line HTML based on tags instead of tokens
This avoids creating a bunch of tokens as temporary objects since they
are no longer stored.
2015-05-13 21:57:53 +02:00
Nathan Sobo
6b51b5d02a Rename parentScopes to openScopes 2015-05-13 21:17:46 +02:00
Nathan Sobo
bf6754981b decodeContent -> decodeTokens 2015-05-13 21:17:46 +02:00
Nathan Sobo
8ab9a9f9bb Account for softWrapIndent when assigning indices on soft wrap line 2015-05-13 21:17:46 +02:00
Nathan Sobo
d90d1f0ea7 Don’t build ::specialTokens unless properties are provided 2015-05-13 21:17:45 +02:00
Nathan Sobo
6befa0200f Assign ::isHardTab to shim tokens 2015-05-13 21:17:45 +02:00
Nathan Sobo
75112a017d Fix assignment of last non-whitespace column for paired characters 2015-05-13 21:17:45 +02:00
Nathan Sobo
2afe013f9e Assign ::hasInvisibleCharacters on Token shims 2015-05-13 21:17:45 +02:00
Nathan Sobo
77e8a906c2 Fix soft wrapping with tags array, including soft-wrap indent 2015-05-13 21:17:45 +02:00
Nathan Sobo
70eb7f77b0 Drop unused methods 2015-05-13 21:17:45 +02:00
Nathan Sobo
a8d01bcec1 Fix bufferRangeForScopeAtPosition with new tags array scheme 2015-05-13 21:17:45 +02:00
Nathan Sobo
24967afed1 Substitute invisibles in initial scan 2015-05-13 21:17:45 +02:00
Nathan Sobo
6274ac25fa Fix TokenizedLine::copy for new representation 2015-05-13 21:17:44 +02:00
Nathan Sobo
f3f609861e Make TokenizedLine::softWrapAt work with new token representation 2015-05-13 21:17:44 +02:00
Nathan Sobo
9d93d18a8f Mark leading/trailing whitespace in new TokenizedLine representation 2015-05-13 21:17:44 +02:00
Nathan Sobo
9554bfd393 Break out hard tabs and paired characters from numeric tag arrays 2015-05-13 21:17:44 +02:00