From 74ef1b8344a34810771f69ef7b82a8aeca57e894 Mon Sep 17 00:00:00 2001 From: Colomban Wendling Date: Sun, 10 Aug 2014 02:21:54 +0200 Subject: [PATCH] Update for new Scintilla styles --- data/filetypes.rust | 3 +++ src/highlighting.c | 3 +++ src/highlightingmappings.h | 5 ++++- 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/data/filetypes.rust b/data/filetypes.rust index 7f8d2bd6..b6109c78 100644 --- a/data/filetypes.rust +++ b/data/filetypes.rust @@ -14,6 +14,9 @@ word4=type string=string_1 stringraw=string_2 character=character +bytestring=string_1 +bytestringraw=string_2 +bytecharacter=character operator=operator identifier=identifier_1 lifetime=parameter diff --git a/src/highlighting.c b/src/highlighting.c index 6a79ebf8..5a46189a 100644 --- a/src/highlighting.c +++ b/src/highlighting.c @@ -1550,8 +1550,11 @@ gboolean highlighting_is_string_style(gint lexer, gint style) case SCLEX_RUST: return (style == SCE_RUST_CHARACTER || + style == SCE_RUST_BYTECHARACTER || style == SCE_RUST_STRING || style == SCE_RUST_STRINGR || + style == SCE_RUST_BYTESTRING || + style == SCE_RUST_BYTESTRINGR || style == SCE_RUST_LEXERROR); } return FALSE; diff --git a/src/highlightingmappings.h b/src/highlightingmappings.h index 2b565278..d0042b20 100644 --- a/src/highlightingmappings.h +++ b/src/highlightingmappings.h @@ -1326,7 +1326,10 @@ static const HLStyle highlighting_styles_RUST[] = { SCE_RUST_IDENTIFIER, "identifier", FALSE }, { SCE_RUST_LIFETIME, "lifetime", FALSE }, { SCE_RUST_MACRO, "macro", FALSE }, - { SCE_RUST_LEXERROR, "lexerror", FALSE } + { SCE_RUST_LEXERROR, "lexerror", FALSE }, + { SCE_RUST_BYTESTRING, "bytestring", FALSE }, + { SCE_RUST_BYTESTRINGR, "bytestringr", FALSE }, + { SCE_RUST_BYTECHARACTER, "bytecharacter", FALSE } }; static const HLKeyword highlighting_keywords_RUST[] = {