From 8dd8bf1c98e0d73e400287e4643deb9b3d4f1b2b Mon Sep 17 00:00:00 2001 From: KeShih Date: Sun, 20 Oct 2024 17:12:28 +0800 Subject: [PATCH] update --- src/Plugins/Freetype/rubber_unicode_font.cpp | 28 ++++++-------------- src/Plugins/Freetype/unicode_font.cpp | 1 - 2 files changed, 8 insertions(+), 21 deletions(-) diff --git a/src/Plugins/Freetype/rubber_unicode_font.cpp b/src/Plugins/Freetype/rubber_unicode_font.cpp index d570b88a0..c29f0dcfb 100644 --- a/src/Plugins/Freetype/rubber_unicode_font.cpp +++ b/src/Plugins/Freetype/rubber_unicode_font.cpp @@ -38,8 +38,7 @@ struct rubber_unicode_font_rep : font_rep { array subfn; bool big_sums; - tt_face math_face; - translator virt; + tt_face math_face; hashmap mapper; hashmap rewriter; @@ -130,8 +129,8 @@ rubber_unicode_font_rep::get_font (int nr) { ******************************************************************************/ int -parse_variant (string s, string& r, string& rg) { - cout << "parse_variant for " << s << LF; +parse_variant (string s, string& r) { + // cout << "parse_variant for " << s << LF; int var = 0; int n = N (s); int start= search_forwards ("-", 0, s); @@ -143,8 +142,7 @@ parse_variant (string s, string& r, string& rg) { else { var= max (0, as_int (s (end + 1, n))); } - r = s (start + 1, end); - rg= s (0, start); + r= s (start + 1, end); return var; } @@ -152,7 +150,6 @@ bool rubber_unicode_font_rep::search_font_sub_bis (string s, string& rew, int& nr) { // look up opentype math table string r; - string rg; int var= 0; bool ver= true; // verizontal or vertical, default is vertical rew = s; @@ -160,34 +157,25 @@ rubber_unicode_font_rep::search_font_sub_bis (string s, string& rew, int& nr) { // large,big,wide // left,right,mid? - if (starts (s, " " << r << ", " << rg << ", " - << var << LF; - if (r == "") return false; string uu= N (r) > 1 ? strict_cork_to_utf8 ("<" * r * ">") : r; diff --git a/src/Plugins/Freetype/unicode_font.cpp b/src/Plugins/Freetype/unicode_font.cpp index 192e4a195..23f5dbb17 100644 --- a/src/Plugins/Freetype/unicode_font.cpp +++ b/src/Plugins/Freetype/unicode_font.cpp @@ -1021,7 +1021,6 @@ unicode_font_rep::metric_to_design_unit (SI m) { font unicode_font_rep::make_rubber_font (font base) { - cout << "Make unicode rubber font " << this->res_name << LF; if (!is_nil (this->math_table)) { return rubber_unicode_font (this, this->math_face); }