Commit d2c9e39c authored by Oleg Korshul's avatar Oleg Korshul

correct font pick algorithm

parent d645e5dd
...@@ -316,7 +316,8 @@ function FD_FontDictionary() ...@@ -316,7 +316,8 @@ function FD_FontDictionary()
["OpenSymbol"], ["OpenSymbol"],
["Arial", "Liberation Sans", "Helvetica", "Nimbus Sans L"], ["Arial", "Liberation Sans", "Helvetica", "Nimbus Sans L"],
["Times New Roman", "Liberation Serif"], ["Times New Roman", "Liberation Serif"],
["Courier New", "Liberation Mono"] ["Courier New", "Liberation Mono"],
["Segoe", "Segoe UI"]
]; ];
this.FD_Ascii_Font_Like_Main = { this.FD_Ascii_Font_Like_Main = {
"Cambria Math" : 0, "Cambria Math" : 0,
...@@ -336,7 +337,10 @@ function FD_FontDictionary() ...@@ -336,7 +337,10 @@ function FD_FontDictionary()
"Liberation Serif" : 3, "Liberation Serif" : 3,
"Courier New" : 4, "Courier New" : 4,
"Liberation Mono" : 4 "Liberation Mono" : 4,
"Segoe" : 5,
"Segoe UI" : 5
}; };
this.ChangeGlyphsMap = { this.ChangeGlyphsMap = {
...@@ -1165,7 +1169,11 @@ CFontSelect.prototype = ...@@ -1165,7 +1169,11 @@ CFontSelect.prototype =
return 0; return 0;
if (-1 != sReqName.indexOf(this.m_wsFontName) || -1 != this.m_wsFontName.indexOf(sReqName)) if (-1 != sReqName.indexOf(this.m_wsFontName) || -1 != this.m_wsFontName.indexOf(sReqName))
{
if (g_fontApplication.g_fontDictionary.CheckLikeFonts(this.m_wsFontName, sReqName))
return 700;
return 1000; return 1000;
}
if (g_fontApplication.g_fontDictionary.CheckLikeFonts(this.m_wsFontName, sReqName)) if (g_fontApplication.g_fontDictionary.CheckLikeFonts(this.m_wsFontName, sReqName))
return 1000; return 1000;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment