From da188203818d08606620eb59ab3337a815126bb6 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Thu, 1 Aug 2013 15:36:31 +0200 Subject: [db] improve font name/style matching with type1 fonts (/{b,i,bi} switches) --- luaotfload-database.lua | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/luaotfload-database.lua b/luaotfload-database.lua index 584e9ad..5b22892 100644 --- a/luaotfload-database.lua +++ b/luaotfload-database.lua @@ -1219,21 +1219,27 @@ t1_fullinfo = function (filename, _subfont, texmf, basename) style = "italic" end + local style_synonyms_set = style_synonyms.set if weight then weight = sanitize_string (weight) + local tmp = "" + if style_synonyms_set.bold[weight] then + tmp = "bold" + end if style then - if style_synonyms.set.bold[weight] then - style = "bold" .. style - end + style = tmp .. style else - if style_synonyms.set.regular[weight] then + if style_synonyms_set.regular[weight] then style = "regular" + else + style = tmp end end end if not style then style = "regular" + --- else italic end namedata.sanitized = sanitize_names ({ -- cgit v1.2.3