From bfc3c6c8ee389b41d62995ba8fda82a4e0d1ce62 Mon Sep 17 00:00:00 2001 From: winston Date: Mon, 30 Oct 2023 01:14:10 +0100 Subject: [PATCH] chore: more fontStyle adjustments --- src/theme/semanticTokens.ts | 1 + src/theme/tokens/python.ts | 8 ++++++++ src/theme/tokens/rust.ts | 10 ++++++++++ 3 files changed, 19 insertions(+) diff --git a/src/theme/semanticTokens.ts b/src/theme/semanticTokens.ts index a4f1ce22..70bd54eb 100644 --- a/src/theme/semanticTokens.ts +++ b/src/theme/semanticTokens.ts @@ -12,6 +12,7 @@ export const getSemanticTokens = (context: ThemeContext): SemanticTokens => { "class:python": { foreground: palette.yellow }, "class.builtin:python": { foreground: palette.mauve }, "variable.typeHint:python": { foreground: palette.yellow }, + "function.decorator:python": { foreground: palette.peach }, // ignore `const`s being peach in JS & TS "variable.readonly:javascript": { foreground: palette.text }, diff --git a/src/theme/tokens/python.ts b/src/theme/tokens/python.ts index 91ec9490..32fb22dc 100644 --- a/src/theme/tokens/python.ts +++ b/src/theme/tokens/python.ts @@ -73,6 +73,7 @@ const tokens = (context: ThemeContext): TextmateColors => { ], settings: { foreground: palette.peach, + fontStyle: "italic", }, }, { @@ -122,6 +123,13 @@ const tokens = (context: ThemeContext): TextmateColors => { fontStyle: "italic", }, }, + { + name: "Python type hints", + scope: "meta.function.parameters.python", + settings: { + fontStyle: "", + }, + }, ]; }; diff --git a/src/theme/tokens/rust.ts b/src/theme/tokens/rust.ts index 38610a39..5aa0431f 100644 --- a/src/theme/tokens/rust.ts +++ b/src/theme/tokens/rust.ts @@ -17,6 +17,16 @@ const tokens = (context: ThemeContext): TextmateColors => { fontStyle: "italic", }, }, + { + name: "Rust attribute strings", + scope: [ + "meta.attribute.rust string.quoted.double.rust", + "meta.attribute.rust string.quoted.single.char.rust", + ], + settings: { + fontStyle: "", + }, + }, { name: "Rust keyword", scope: [