Commit Graph

19 Commits

Author SHA1 Message Date
Johannes Altmanninger
0a9c90fecf rc: use a separate *-insert hook to auto-insert comments
This should cover all filetypes that already auto-insert comments,
except for rust.kak, which is left for a follow-up.

Most of these are straightforward, some explanation for special cases:

rc/filetype/zig.kak rc/filetype/cue.kak

  These indent hooks used their own logic to indent after "{" only if
  no comment was inserted. Replace this logic by checking if a comment
  was inserted. This works because these "*-insert" hooks are run
  before their respective "*-indent" hooks.
 
rc/filetype/php.kak

  This also has some logic to insert "*" after "/*" lines. Basic
  usage seems to work still. In future this should borrow from the
  c-family one, which works a bit better.
2021-04-17 20:56:23 +02:00
tgirod
f21867d2ac
fix comment highlighting
`#` will be considered a comment only if it is the first character of the line, including blank characters.
2020-10-28 09:36:28 +01:00
Johannes Altmanninger
ab76ec981a Avoid extra indent when line does not end on keyword
For example there was an indent after a line like "echo todo" with filetype sh
because the "do" in "todo" was recognised as keyword.
2020-08-23 19:15:52 +02:00
Evan Relf
77ec8b70a8
Fix Haskell multi-line quasiquoter highlighting 2019-12-12 16:00:50 -08:00
Evan Relf
991ed97f4c
Fix incomplete highlighting of Haskell via keyword 2019-12-12 15:45:43 -08:00
Evan Relf
9eb9747396 Improve highlighting of Haskell function names 2019-12-12 15:27:48 -08:00
Evan Relf
024a3afff0 Highlight Haskell type and data family keyword 2019-12-12 15:27:48 -08:00
Evan Relf
63bbfc253b Relocate Haskell quasiquote region highlighter 2019-12-12 15:27:48 -08:00
Evan Relf
199b4e2f66
Highlight Haskell deriving strategies keywords 2019-11-18 00:15:33 -08:00
Evan Relf
237acbcfeb
Improve Haskell quasiquote highlighting
Now only the inside of the quasiquote gets the string coloring applied.
2019-11-18 00:14:41 -08:00
Evan Relf
f40064b8d6
Add forall unicode character as Haskell keyword 2019-11-18 00:14:22 -08:00
Frank LENORMAND
21614cb06e src: Create a <semicolon> named key
This commit allows using the <semicolon> expansion in commands, instead
of `\;`.

It makes commands look more elegant, and prevents new-comers from
falling into the trap of using <a-;> without escaping the semicolon.
2019-10-22 11:02:06 +02:00
Maxime Coste
e4fb70ebec Replace ModeChange hooks by ModePush and ModePop
Remove deprecated InsertBegin, InsertEnd, NormalBegin, NormalEnd
hooks.

Closes #2545
2019-10-16 20:45:53 +11:00
Maxime Coste
d793ca76b6 Merge branch 'haskell' of http://github.com/evanrelf/kakoune 2019-10-01 20:07:29 +10:00
Evan Relf
c544e01b7d
Add additional syntax highlighting for Haskell
- Function names in type signatures are now highlighted
- Quasiquotes are now highlighted
2019-09-28 15:38:43 -07:00
Jason Felice
f88cf7ffb4 rc, doc: set extra_word_chars on buffer, not window
For clojure.kak and haskell.kak, set extra_word_chars on the buffer
and not the window, so that the buffer's word db is updated correctly
for word completion.

Document this.

Also, minor refactor of clojure.kak.

Closes #3108
2019-09-26 09:55:02 -04:00
Justin Frank
80ac46e09d Fixed many of the filetype support modules to not use BufSetOption to load 2019-04-09 20:54:19 -07:00
Justin Frank
c3f694a28f Modified base files to use modules 2019-04-08 17:02:44 -07:00
Alex Leferry 2
c0dccdd90d Add categories in rc/
Closes #2783
2019-03-21 01:06:16 +01:00