Releases: kadet1090/KeyLighter
Releases · kadet1090/KeyLighter
v0.8.2
v0.8.1
v0.8.0
Added
Kadet\Highlighter\Language\CommonFeatures
helper with common language features like string handlingKadet\Highlighter\Matcher\DelegateRegexMatcher
classKadet\Highlighter\Parser\Rule::setMatcher
andKadet\Highlighter\Parser\Rule::getMatcher
methodsKadet\Highlighter\Parser\Context
class for storing context related informationKadet\Highlighter\Parser\Result::getStart
method$offset
argument toKadet\Highlighter\Parser\UnprocessedTokens
methodsKadet\Highlighter\Language\Language::by*
factory methodsKadet\Highlighter\Language\Language::getAliases*
static method, for language metadataKadet\Highlighter\Utils\Singleton::init
singletons constructordev:generate-table
anddev:aliases
commands for cli application
- C highlighting via
Kadet\Highlighter\Language\C
- Python highlighting via
Kadet\Highlighter\Language\Python
- Jinja/Django templates highlighting via
Kadet\Highlighter\Language\Python\Django
- Markdown highlighting via
Kadet\Highlighter\Language\Markdown
- C++ highlighting via
Kadet\Highlighter\Language\Cpp
- C# highlighting via
Kadet\Highlighter\Language\CSharp
- Java highlighting via
Kadet\Highlighter\Language\Java
- shell/bash/zsh highlighting via
Kadet\Highlighter\Language\Shell
- Go highlighting via
Kadet\Highlighter\Language\Go
- Ruby highlighting via
Kadet\Highlighter\Language\Ruby
- XML and HTML now highlights entities
- CSS highlights web colors
- PHP and few others, matches in-string expressions
Changed
Kadet\Highlighter\Parser\Result::__constructor($source, $tokens)
->Kadet\Highlighter\Parser\Result::__constructor($source, Token $start)
- Processing is now handled with
Kadet\Highlighter\Parser\Token\Token::process
method Kadet\Highlighter\Parser\Token\Token
simplifiedparameter
token renamed tosymbol.parameter
annotation
token renamed tosymbol.annotation
keyword.escape
token renamed tooperator.escape
- For semantic reasons
Kadet\Highlighter\Formatter\DebugFormatter
now extendsKadet\Highlighter\Formatter\CliFormatter
- CLI formatting styles now accept callables
- Token offsetting is now handed by containers rather than factory
- Completely rewritten console application - Now it's based on
symfony/console
- Console application now determines language based on filename
Fixed
- PHP now correctly matches multiple implemented interfaces
- PHP now correctly matches variables as first token
- PHP now correctly matches types in doc comments
- PHP now correctly handles escape sequences in single quoted strings (see #1)
- Languages injected inside injected languages are now handled correctly
Removed
Kadet\Highlighter\Parser\GreedyParser
in favor ofKadet\Highlighter\Parser\Token\Token::process
- Redundant
Kadet\Highlighter\Parser\Token\Token::$index
property start
andend
fromKadet\Highlighter\Parser\Token\Token
s constructor$option
s, now they are handled by factoryKadet\Highlighter\Parser\TokenFactory::getOffset
andsetOffset
methods
Other
- More tests
- About 10-15% performance improvement