[latex3-commits] [git/LaTeX3-latex3-luaotfload] dev: Fixed non-transparent coloschemes (178ff14)
Marcel Fabian Krüger
tex at 2krueger.de
Sat Feb 22 15:27:01 CET 2020
Repository : https://github.com/latex3/luaotfload
On branch : dev
Link : https://github.com/latex3/luaotfload/commit/178ff1423d9178808470857d83a5d06b083e13be
>---------------------------------------------------------------
commit 178ff1423d9178808470857d83a5d06b083e13be
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date: Sat Feb 22 15:27:01 2020 +0100
Fixed non-transparent coloschemes
>---------------------------------------------------------------
178ff1423d9178808470857d83a5d06b083e13be
src/luaotfload-colors.lua | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/luaotfload-colors.lua b/src/luaotfload-colors.lua
index ba42316..83c0fc1 100644
--- a/src/luaotfload-colors.lua
+++ b/src/luaotfload-colors.lua
@@ -157,11 +157,11 @@ local function get_glyph_color (font_id, char)
local properties = tfmdata and tfmdata.properties
local font_color = properties and properties.color_rgb
local font_transparent = properties and properties.color_a
- if type(font_color) == "table" and type(font_transparent) == "table" then
+ if type(font_color) == "table" then
local char_tbl = tfmdata.characters[char]
char = char_tbl and (char_tbl.index or char)
font_color = char and font_color[char] or font_color.default
- font_transparent = char and font_transparent[char] or font_transparent.default
+ font_transparent = font_transparent and (char and font_transparent[char] or font_transparent.default)
end
return font_color, font_transparent
end
More information about the latex3-commits
mailing list.