Add two_face themes in cosmic-edit instead of cosmic-text
This commit is contained in:
parent
07145d6786
commit
e76b63a039
3 changed files with 153 additions and 80 deletions
|
|
@ -42,7 +42,14 @@ mod text_box;
|
|||
lazy_static::lazy_static! {
|
||||
static ref FONT_SYSTEM: Mutex<FontSystem> = Mutex::new(FontSystem::new());
|
||||
static ref SWASH_CACHE: Mutex<SwashCache> = Mutex::new(SwashCache::new());
|
||||
static ref SYNTAX_SYSTEM: SyntaxSystem = SyntaxSystem::new();
|
||||
static ref SYNTAX_SYSTEM: SyntaxSystem = {
|
||||
let lazy_theme_set = two_face::theme::LazyThemeSet::from(two_face::theme::extra());
|
||||
SyntaxSystem {
|
||||
//TODO: store newlines in buffer
|
||||
syntax_set: two_face::syntax::extra_no_newlines(),
|
||||
theme_set: syntect::highlighting::ThemeSet::from(&lazy_theme_set),
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue