Instead of starting the default shell and sending it text (hoping
it will support POSIX like shell syntax), just use the `env` utility
to set the correct environment and exec kakoune.
- Added <?php and ?> tags, and highlight everything outside as html
- Highlight documentation comments and @fields
- Added basic string interpolation highlighting
Letting any character to be escaped is error prone as it looks like
\l could mean [:lower:] (as it used to with boost) when it only means
literal l.
Fix the haskell.kak file as well.
Fixes#1945
Previously, two underscore characters in a document would mark the entire
space between them as italic, no matter how far apart. Now we only accept a
single consecutive newline within an inline-formatted span, so hard-wrapped
documents will still format nicely but stray characters won't mess up your
entire document.
Note that the highlighter for backtick-enclosed spans was modified,
even though it's redundant with the code-block highlighting introduced
in 5bc62c694.
As well as the traditional `[text](url)` syntax, Markdown allows the text to
be followed by a tag in square brackets. If the text is followed by nothing
at all, then the tag for that link is the text itself. The actual URL
is supplied later in the document, like a footnote at the bottom of the page:
Some text with [a link][tag] and [another link].
[tag]: http://www.example.com/link1
[another link]: http://www.example.com/link2
This adds the "link" face to the URL in such footnote lines.
Makes all the suggestions on the completion menu have the same format:
{type}{suggestedWord}{extra description}
the type column is aligned to 6 characters wide (and aligned to the right),
to allow the suggestion to be easily visually detectable and, as a bonus,
the type too.
For example, a bit of menu would look like this:
fn stdout() -> Stdout
trait BufRead: Read
struct BufReader<R>
Type is one of the following:
- fn
- enum
- mod
- trait
- struct
It also trims the module extra bits to only 30 characters long (it can be a lot longer than that)
When AWK processes the racer response, it adds a trailing ':' that
kakoune completion expects to lead to a row having an 'a|b|c' shape,
but it's empty instead. Removing the extra ':' allows the racer
complation to actually work.
There does not seem to be any reasonable use cases of not collapsing
jumps when the input is not comming from the user. Always collapse
them.
It could make sense to move jump collapsing out of context_wrap as
in general any action not comming directly from the user should
collapse them, at the moment a comment or mapping will not collapse
jumps, which is unfortunate.
The use of `%{...%reg{...}}` was not being expanded correctly, as
the enclosing %{...} prevents the internal %expand{...} from being
considered.
The introduction of an additional command allows us to bypass
quoting hell as the expansion of %reg{5} could contain arbitrary
text.
With the introduction of -match-capture for the lua region highlighter,
the string closing regex had spurious captures that were not going to
match.
Fixes#1850
This commit avoids false positives when highlighting literals such as
`$window`, which is a regular variable but still highlighted as a
special value.
Special highlighting of variables that start with a dollar sign `$`
was also removed, as not all variables start with a dollar sign,
and we don't have a reliable way yet to detect variables.
unsetting static_words whenever any buffer filetype is set to non ocaml
is wrong, it breaks static_words for every filetype whose filetype hook
run before the ocaml ones.
Block comments in Lua were broken, apparently due to the opening
sequence being interpreted as a line comment. Changing the order in the
highlighter seems to fix this issue.
Fixes#1735
We need \K to not interfer with languages own interpretation of ` like multiline strings in javascript
We need \b in e.g. java\b otherwise it blocks javascript
I couldn't get the bare ``` to not block the other highlighters when introducing \K any other way than negative lookahead of all possible highlighers
Commit 870d2d22d7 introduced a regression
in the highlighting of qualified Haskell variables, such as `Foo.bar`.
After that commit `Fo` was highlighted as a constructor (note, not
`Foo`, just `Fo` without the trailing `o`). This restores the original
behavior.