diff options
| author | Francesco Abbate <francesco.bbt@gmail.com> | 2021-10-23 15:01:16 +0200 |
|---|---|---|
| committer | Francesco Abbate <francesco.bbt@gmail.com> | 2021-10-23 15:01:16 +0200 |
| commit | ffb66cefd77a4ad2c90e698df440d3f09d08feef (patch) | |
| tree | d437cfefbd7a64cfc92a082b9967b51e5da62c2c /data/plugins/language_python.lua | |
| parent | 6f732f67f9c8cfab3ee16a1d30c0629fb872dbf0 (diff) | |
| download | lite-xl-ffb66cefd77a4ad2c90e698df440d3f09d08feef.tar.gz lite-xl-ffb66cefd77a4ad2c90e698df440d3f09d08feef.zip | |
Fix python docstring highlighting
From PR:
https://github.com/lite-xl/lite-xl/pull/624
contributed by @dflock.
Diffstat (limited to 'data/plugins/language_python.lua')
| -rw-r--r-- | data/plugins/language_python.lua | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/data/plugins/language_python.lua b/data/plugins/language_python.lua index e19caa63..60aa41a6 100644 --- a/data/plugins/language_python.lua +++ b/data/plugins/language_python.lua @@ -6,16 +6,16 @@ syntax.add { headers = "^#!.*[ /]python", comment = "#", patterns = { - { pattern = { "#", "\n" }, type = "comment" }, - { pattern = { '[ruU]?"', '"', '\\' }, type = "string" }, - { pattern = { "[ruU]?'", "'", '\\' }, type = "string" }, - { pattern = { '"""', '"""' }, type = "string" }, - { pattern = "0x[%da-fA-F]+", type = "number" }, - { pattern = "-?%d+[%d%.eE]*", type = "number" }, - { pattern = "-?%.?%d+", type = "number" }, - { pattern = "[%+%-=/%*%^%%<>!~|&]", type = "operator" }, - { pattern = "[%a_][%w_]*%f[(]", type = "function" }, - { pattern = "[%a_][%w_]*", type = "symbol" }, + { pattern = { "#", "\n" }, type = "comment" }, + { pattern = { '[ruU]?"""', '"""'; '\\' }, type = "string" }, + { pattern = { '[ruU]?"', '"', '\\' }, type = "string" }, + { pattern = { "[ruU]?'", "'", '\\' }, type = "string" }, + { pattern = "0x[%da-fA-F]+", type = "number" }, + { pattern = "-?%d+[%d%.eE]*", type = "number" }, + { pattern = "-?%.?%d+", type = "number" }, + { pattern = "[%+%-=/%*%^%%<>!~|&]", type = "operator" }, + { pattern = "[%a_][%w_]*%f[(]", type = "function" }, + { pattern = "[%a_][%w_]*", type = "symbol" }, }, symbols = { ["class"] = "keyword", |
