diff options
author | Masamichi Hosoda <trueroad@trueroad.jp> | 2016-06-25 11:12:11 +0900 |
---|---|---|
committer | Masamichi Hosoda <trueroad@trueroad.jp> | 2016-07-04 21:46:34 +0900 |
commit | 3c2fbb63c2b588dc244197ab7de7f028807833bb (patch) | |
tree | 45193c580f31a479b56f42d4c43980528c61e8e3 | |
parent | fa2596b6ec273e7d82907f97acf0c65559b3c1b4 (diff) |
Issue 4876/2: Enable fontname replacing in Open_type_font class
This commit enables fontname replacing for CFF (OTF/OTC) fonts.
-rw-r--r-- | lily/include/open-type-font.hh | 1 | ||||
-rw-r--r-- | lily/open-type-font.cc | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/lily/include/open-type-font.hh b/lily/include/open-type-font.hh index bf36071e91..b86a560a73 100644 --- a/lily/include/open-type-font.hh +++ b/lily/include/open-type-font.hh @@ -30,6 +30,7 @@ class Open_type_font : public Font_metric { /* handle to face object */ FT_Face face_; + string postscript_name_; SCM lily_subfonts_; SCM lily_character_table_; diff --git a/lily/open-type-font.cc b/lily/open-type-font.cc index e4fb5d5d98..39e7b524ff 100644 --- a/lily/open-type-font.cc +++ b/lily/open-type-font.cc @@ -220,6 +220,8 @@ Open_type_font::Open_type_font (FT_Face face) index_to_charcode_map_ = make_index_to_charcode_map (face_); lily_index_to_bbox_table_ = scm_c_make_hash_table (257); + + postscript_name_ = get_postscript_name (face_); } void @@ -399,7 +401,7 @@ Open_type_font::get_global_table () const string Open_type_font::font_name () const { - return FT_Get_Postscript_Name (face_); + return postscript_name_; } SCM |