sidebar: ai: add light theme for source view

This commit is contained in:
end-4
2024-03-21 08:50:30 +07:00
parent 7ee3fb86e8
commit bc264b0fc4
3 changed files with 109 additions and 3 deletions
@@ -0,0 +1,107 @@
<?xml version="1.0" encoding="UTF-8"?>
<style-scheme id="custom-light" _name="Custom" version="1.0">
<author>end_4</author>
<_description>Catppuccin port but very random</_description>
<!-- The scheme tries to look like the default GVim scheme,
since it is also what the hardwired GtkSourceView 1 color
scheme did -->
<!-- Palette -->
<color name="white" value="#F8F8F2"/>
<color name="white" value="#53566F"/>
<color name="blue" value="#2E70F5"/>
<color name="magenta" value="#DA70D6"/>
<color name="violet" value="#934CF0"/>
<color name="cyan" value="#66D9EF"/>
<color name="grey" value="#817D69"/>
<color name="green" value="#44A230"/>
<color name="bordeaux" value="#B22757"/>
<color name="red" value="#E64856"/>
<color name="yellow" value="#E4D973"/>
<color name="purple" value="#934CF0"/>
<color name="onSuccess" value="#D1E8D5"/>
<color name="success" value="#213528"/>
<color name="onError" value="#ffb4a9"/>
<color name="error" value="#680003"/>
<!-- Global Settings -->
<style name="current-line" background="#EFF1F5"/>
<style name="current-line-number" background="#eeeeec"/>
<style name="draw-spaces" foreground="#babdb6"/>
<style name="background-pattern" background="#EFF1F5"/>
<!-- Bracket Matching -->
<!-- <style name="bracket-match" foreground="white" background="grey"/> -->
<!-- <style name="bracket-mismatch" foreground="white" background="red"/> -->
<!-- Right Margin -->
<style name="right-margin" foreground="#EFF1F5" background="#EFF1F5"/>
<!-- Search Matching -->
<style name="search-match" background="yellow"/>
<!-- Comments -->
<style name="def:comment" foreground="grey" italic="true"/>
<style name="def:shebang" foreground="grey" bold="true"/>
<style name="def:doc-comment-element" italic="true"/>
<!-- Constants -->
<style name="def:constant" foreground="black"/>
<style name="def:special-char" foreground="yellow"/>
<!-- Identifiers -->
<style name="def:identifier" foreground="green"/>
<!-- Statements -->
<style name="def:statement" foreground="cyan" bold="true"/>
<!-- Types -->
<style name="def:type" foreground="cyan" bold="true"/>
<!-- Others -->
<style name="def:preprocessor" foreground="purple"/>
<style name="def:error" background="red" bold="true"/>
<style name="def:warning" background="yellow"/>
<style name="def:note" foreground="bordeaux" bold="true"/>
<style name="def:underlined" italic="true" underline="single"/>
<!-- Heading styles, uncomment to enable -->
<!--
<style name="def:heading0" scale="5.0"/>
<style name="def:heading1" scale="2.5"/>
<style name="def:heading2" scale="2.0"/>
<style name="def:heading3" scale="1.7"/>
<style name="def:heading4" scale="1.5"/>
<style name="def:heading5" scale="1.3"/>
<style name="def:heading6" scale="1.2"/>
-->
<!-- Language specific styles -->
<style name="diff:added-line" background="success" foreground="onSuccess"/>
<style name="diff:removed-line" background="error" foreground="onError"/>
<style name="diff:changed-line" use-style="def:preprocessor"/>
<style name="diff:special-case" use-style="def:constant"/>
<style name="diff:location" use-style="def:statement"/>
<style name="diff:diff-file" use-style="def:type"/>
<style name="xml:tags" foreground="red"/>
<style name="xml:attribute-name" foreground="green"/>
<style name="xml:namespace" foreground="cyan" bold="true"/>
<style name="js:object" foreground="cyan" bold="true"/>
<style name="js:constructors" foreground="cyan"/>
<style name="latex:display-math" foreground="purple"/>
<style name="latex:command" foreground="green" bold="true"/>
<style name="latex:include" use-style="def:preprocessor"/>
<style name="sh:variable" foreground="purple"/>
<!-- legacy styles for old lang files -->
<style name="Others" foreground="cyan" bold="true"/>
<style name="Others 2" foreground="cyan"/>
<style name="Others 3" foreground="purple"/>
</style-scheme>
@@ -10,8 +10,8 @@ import md2pango from '../../.miscutils/md2pango.js';
import { darkMode } from "../../.miscutils/system.js";
const LATEX_DIR = `${GLib.get_user_cache_dir()}/ags/media/latex`;
const CUSTOM_SOURCEVIEW_SCHEME_PATH = `${App.configDir}/assets/themes/sourceviewtheme.xml`;
const CUSTOM_SCHEME_ID = 'custom';
const CUSTOM_SOURCEVIEW_SCHEME_PATH = `${App.configDir}/assets/themes/sourceviewtheme${darkMode ? '' : '-light'}.xml`;
const CUSTOM_SCHEME_ID = `custom${darkMode ? '' : '-light'}`;
const USERNAME = GLib.get_user_name();
/////////////////////// Custom source view colorscheme /////////////////////////
-1
View File
@@ -640,7 +640,6 @@ $colorpicker_rounding: 0.341rem;
@include small-rounding;
margin: 0rem 0.682rem;
padding: 0.682rem;
color: $onBackground;
}