2017-05-23 17:12:47 +02:00
# Nano syntax file
# Language: Kotlin
# Maintainer: Bjarne Holen <bjarneholen@gmail.com>
2017-05-24 08:19:31 +02:00
# Edited by: Ritiek Malhotra <ritiekmalhotra123@gmail.com>
# Last Change: 2017 May 24
2017-05-24 21:36:26 +02:00
# Copyright (c) 2014, Bjarne Holen
2017-05-23 17:12:47 +02:00
2017-05-24 08:19:31 +02:00
syntax "kotlin" "\.kt$" "\.kts$"
color magenta "\b(([1-9][0-9]+)|0+)\.[0-9]+\b" "\b[1-9][0-9]*\b" "\b0[0-7]*\b" "\b0x[1-9a-f][0-9a-f]*\b"
color yellow "[.:;,+*|=!\%@]" "<" ">" "/" "-" "&"
2020-01-01 18:50:28 +01:00
color green "\<(namespace|as|type|class|this|super|val|var|fun|is|in|object|when|trait|import|where|by|get|set|abstract|enum|open|annotation|override|private|public|internal|protected|out|vararg|inline|final|package|lateinit|constructor|companion|const)\>"
2017-05-24 08:19:31 +02:00
color yellow "\<(true|false|null)\>"
color cyan "\<(break|catch|continue|do|else|finally|for|if|return|throw|try|while|repeat)\>"
color brightred "\<(inner|outer)\>"
2017-05-23 17:12:47 +02:00
##
## String highlighting. You will in general want your comments and
## strings to come last, because syntax highlighting rules will be
## applied in the order they are read in.
2017-05-24 08:19:31 +02:00
color brightblue "<[^= ]*>" ""(\\.|[^"])*""
2017-05-23 17:12:47 +02:00
## Comment highlighting
2019-12-02 14:28:54 +01:00
color red "^\s*//.*"
2019-12-15 21:57:35 +01:00
color red start="^\s*/\*" end="\*/"
2017-05-23 17:12:47 +02:00
## Trailing whitespace
color ,green "[[:space:]]+$"