Backport fix for dark theme Markdown highlighting

This commit is contained in:
Adam Williamson 2022-05-10 17:42:26 -07:00
parent 1b1009d4c4
commit 6b8305f2dc
2 changed files with 53 additions and 1 deletions

View File

@ -0,0 +1,44 @@
From fba1defab604bad77ba637881507a904183b4cbe Mon Sep 17 00:00:00 2001
From: Christian Hergert <chergert@redhat.com>
Date: Thu, 21 Apr 2022 13:01:11 -0700
Subject: [PATCH] Adwaita-dark.xml: add styling for common markdown features
Related #265
---
data/styles/Adwaita-dark.xml | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/data/styles/Adwaita-dark.xml b/data/styles/Adwaita-dark.xml
index 04416677..b770174a 100644
--- a/data/styles/Adwaita-dark.xml
+++ b/data/styles/Adwaita-dark.xml
@@ -97,13 +97,13 @@
<style name="bracket-match" bold="true"/>
<style name="current-line" background="libadwaita-dark-alt"/>
<style name="current-line-number" background="libadwaita-dark-alt" foreground="light_7"/>
+ <style name="cursor" foreground="light_5"/>
<style name="draw-spaces" foreground="dark_3"/>
<style name="line-numbers" background="libadwaita-dark" foreground="dark_2"/>
<style name="map-overlay" background="dark_1"/>
<style name="right-margin" background="dark_1" foreground="dark_1"/>
<style name="search-match" background="yellow_4" foreground="dark_4"/>
<style name="text" background="libadwaita-dark" foreground="light_5"/>
- <style name="cursor" foreground="light_5"/>
<!-- Defaults -->
<style name="def:base-n-integer" foreground="violet_2"/>
@@ -113,9 +113,11 @@
<style name="def:decimal" foreground="violet_2"/>
<style name="def:deletion" strikethrough="true"/>
<style name="def:doc-comment-element" foreground="light_7"/>
+ <style name="def:emphasis" italic="true"/>
<style name="def:floating-point" foreground="violet_2"/>
<style name="def:function" foreground="blue_2"/>
<style name="def:heading" foreground="teal_3" bold="true"/>
+ <style name="def:inline-code" foreground="violet_2"/>
<style name="def:keyword" foreground="orange_2" bold="true"/>
<style name="def:link-destination" foreground="blue_2" italic="true" underline="low"/>
<style name="def:link-text" foreground="red_2"/>
--
2.36.0

View File

@ -5,13 +5,18 @@
Name: gtksourceview5 Name: gtksourceview5
Version: 5.4.1 Version: 5.4.1
Release: 1%{?dist} Release: 2%{?dist}
Summary: Source code editing widget Summary: Source code editing widget
License: LGPLv2+ License: LGPLv2+
URL: https://wiki.gnome.org/Projects/GtkSourceView URL: https://wiki.gnome.org/Projects/GtkSourceView
Source0: https://download.gnome.org/sources/gtksourceview/%{api_ver}.4/gtksourceview-%{version}.tar.xz Source0: https://download.gnome.org/sources/gtksourceview/%{api_ver}.4/gtksourceview-%{version}.tar.xz
# Fix markdown highlighting in dark theme
# https://gitlab.gnome.org/GNOME/gtksourceview/-/issues/265
# https://gitlab.gnome.org/GNOME/gtksourceview/-/commit/fba1defab604bad77ba637881507a904183b4cbe
Patch0: 0001-Adwaita-dark.xml-add-styling-for-common-markdown-fea.patch
BuildRequires: gcc BuildRequires: gcc
BuildRequires: gettext BuildRequires: gettext
BuildRequires: gi-docgen BuildRequires: gi-docgen
@ -94,6 +99,9 @@ the functionality of the installed %{name} package.
%{_datadir}/installed-tests %{_datadir}/installed-tests
%changelog %changelog
* Tue May 10 2022 Adam Williamson <awilliam@redhat.com> - 5.4.1-2
- Backport fix for dark theme Markdown highlighting
* Fri Apr 22 2022 David King <amigadave@amigadave.com> - 5.4.1-1 * Fri Apr 22 2022 David King <amigadave@amigadave.com> - 5.4.1-1
- Update to 5.4.1 (#2077674) - Update to 5.4.1 (#2077674)