From c4f7380a95aa78e8f3a41cb7f179ad083e476a39 Mon Sep 17 00:00:00 2001 From: jgmdev Date: Sat, 5 Mar 2022 19:13:24 -0400 Subject: [PATCH] language_md: removed scale adjustment code that was needed because of a bug on scale plugin. --- data/plugins/language_md.lua | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/data/plugins/language_md.lua b/data/plugins/language_md.lua index f7df1c79..5013279e 100644 --- a/data/plugins/language_md.lua +++ b/data/plugins/language_md.lua @@ -3,7 +3,6 @@ local syntax = require "core.syntax" local style = require "core.style" local core = require "core" -local initial_scale = SCALE local initial_color = style.syntax["keyword2"] -- Add 3 type of font styles for use on markdown files @@ -203,20 +202,9 @@ syntax.add { symbols = { }, } --- Adjust markdown fonts on scale changes. --- Note: this should be performed by lite-xl it self to all style.syntax_fonts +-- Adjust the color on theme changes core.add_thread(function() while true do - if initial_scale ~= SCALE then - for _, attr in pairs({"bold", "italic", "bold_italic"}) do - style.syntax_fonts["markdown_"..attr] = - style.syntax_fonts["markdown_"..attr]:copy( - style.code_font:get_size() - ) - end - initial_scale = SCALE - end - -- we also adjust the color on theme changes if initial_color ~= style.syntax["keyword2"] then for _, attr in pairs({"bold", "italic", "bold_italic"}) do style.syntax["markdown_"..attr] = style.syntax["keyword2"]