void Draw::DrawText(int x, int y, int angle, const wchar *text, Font font, Color ink, int n, const int *dx) { DUMP(font); DUMP(font.GetAscent()); DUMP(font.GetDescent()); if(IsNull(ink)) return; .....
* C:\1362\out\MSC8.Debug.Debug_full.Gui\ide.exe 03.08.2009 21:05:09, user: odyssey font = <Arial:20> font.Info().GetAscent() = 19 font.Info().GetDescent() = 4 font = <Arial:10> font.Info().GetAscent() = 10 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Italic> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Italic> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Italic> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Italic> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2
* c:\1\ide.exe 03.08.2009 21:10:53, user: kasome font = <Arial:20> font.Info().GetAscent() = 19 font.Info().GetDescent() = 4 font = <Arial:10> font.Info().GetAscent() = 10 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Italic> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Underline> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Underline> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Italic> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Underline> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Underline> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Italic> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3
struct PackageDisplay : Display { Font fnt; virtual Size GetStdSize(const Value& q) const { Size sz = GetTextSize(String(q), fnt); sz.cx += 20; sz.cy = max(sz.cy, 16); DUMP(sz.cy); return sz; } virtual void Paint(Draw& w, const Rect& r, const Value& q, Color ink, Color paper, dword style) const { w.DrawRect(r, paper); w.DrawImage(r.left, r.top + (r.Height() - 16) / 2, IdeImg::Package()); w.DrawText(r.left + 20, r.top + (r.Height() - Draw::GetStdFontCy()) / 2, String(q), fnt, ink); LOG(String(q) << " " << fnt); DUMP(Draw::GetStdFontCy()); DUMP(r.top + (r.Height() - Draw::GetStdFontCy()) / 2); DUMP(fnt.GetAscent()); DUMP(fnt.GetDescent()); } PackageDisplay() { fnt = StdFont(); } };
* C:\Test\Run\1362\ide.exe 04.08.2009 01:42:52, user: odyssey font = <Arial:20> font.Info().GetAscent() = 19 font.Info().GetDescent() = 4 font = <Arial:10> font.Info().GetAscent() = 10 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBookXML <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 18 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBookXML2 <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 35 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AnimatedHello <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 52 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:0> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Italic> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBookXML <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 18 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBookXML2 <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 35 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AnimatedHello <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 52 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11 Bold> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.Info().GetAscent() = 11 fnt.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2 font = <STDFONT:11> font.Info().GetAscent() = 11 font.Info().GetDescent() = 2
* C:\Test\Run\1362\ide.exe 04.08.2009 01:46:33, user: kasome font = <Arial:20> font.Info().GetAscent() = 19 font.Info().GetDescent() = 4 font = <Arial:10> font.Info().GetAscent() = 10 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <Arial:13> font.Info().GetAscent() = 13 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:0> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Italic> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Underline> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Underline> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Bold> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 AddressBook <STDFONT:12 Bold> Draw::GetStdFontCy() = 15 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 0 fnt.Info().GetAscent() = 12 fnt.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Bold> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 AddressBookXML <STDFONT:12 Bold> Draw::GetStdFontCy() = 15 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 17 fnt.Info().GetAscent() = 12 fnt.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Bold> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 AddressBookXML2 <STDFONT:12 Bold> Draw::GetStdFontCy() = 15 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 34 fnt.Info().GetAscent() = 12 fnt.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Bold> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 AnimatedHello <STDFONT:12 Bold> Draw::GetStdFontCy() = 15 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 51 fnt.Info().GetAscent() = 12 fnt.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12 Bold> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 AddressBook <STDFONT:12 Bold> Draw::GetStdFontCy() = 15 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 0 fnt.Info().GetAscent() = 12 fnt.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3 font = <STDFONT:12> font.Info().GetAscent() = 12 font.Info().GetDescent() = 3
* C:\Test\Run\1393\ide.exe 04.08.2009 01:50:21, user: odyssey font = <Arial:20> font.GetAscent() = 19 font.GetDescent() = 4 font = <Arial:10> font.GetAscent() = 10 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 18 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML2 <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 35 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AnimatedHello <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 52 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Italic> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 18 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML2 <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 35 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AnimatedHello <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 52 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2
* C:\Test\Run\1393\ide.exe 04.08.2009 01:55:22, user: kasome font = <Arial:20> font.GetAscent() = 19 font.GetDescent() = 4 font = <Arial:10> font.GetAscent() = 10 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Italic> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Underline> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Underline> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBook <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 8 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBookXML <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 25 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBookXML2 <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 42 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AnimatedHello <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 59 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBook <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 8 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3
* C:\Test\Run\1469\ide.exe 04.08.2009 01:58:56, user: odyssey font = <Arial:10> font.GetAscent() = 10 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 18 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML2 <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 35 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AnimatedHello <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 52 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Italic> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 18 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBookXML2 <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 35 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AnimatedHello <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 52 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11 Bold> font.GetAscent() = 11 font.GetDescent() = 2 AddressBook <STDFONT:11 Bold> Draw::GetStdFontCy() = 13 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 1 fnt.GetAscent() = 11 fnt.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2 font = <STDFONT:11> font.GetAscent() = 11 font.GetDescent() = 2
* C:\Test\Run\1469\ide.exe 04.08.2009 02:03:37, user: kasome font = <Arial:10> font.GetAscent() = 10 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <Arial:13> font.GetAscent() = 13 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Italic> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Underline> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Underline> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBook <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 8 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBookXML <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 25 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBookXML2 <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 42 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AnimatedHello <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 59 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12 Bold> font.GetAscent() = 12 font.GetDescent() = 3 AddressBook <STDFONT:12 Bold> Draw::GetStdFontCy() = 0 r.top + (r.Height() - Draw::GetStdFontCy()) / 2 = 8 fnt.GetAscent() = 12 fnt.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3 font = <STDFONT:12> font.GetAscent() = 12 font.GetDescent() = 3
void GetStdFontSys(String& name, int& height) { #ifdef PLATFORM_WINCE name = "Arial"; height = 10; #else NONCLIENTMETRICS ncm; ncm.cbSize = sizeof(ncm); ::SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(ncm), &ncm, 0); name = ncm.lfMenuFont.lfFaceName; height = abs((int)ncm.lfMenuFont.lfHeight); #endif DUMP(name); DUMP(height); }
void Font::SetStdFont(Font font) { DrawLock __; InitStdFont(); AStdFont = font; SyncStdFont(); LOG("SetStdFont " << font); } void Font::InitStdFont() { ONCELOCK { DrawLock __; List(); AStdFont = Arial(12); String name; int height = 0; GetStdFontSys(name, height); int q = FindFaceNameIndex(name); DUMP(q); if(q > 0) { AStdFont = Font(q, max(height, 1)); LOG("InitStdFont " << font); SyncStdFont(); } } }
* C:\Test\Run\1469\ide.exe 04.08.2009 09:53:40, user: kasome name = 新細明體 height = 12 q = 0
* C:\Test\Run\1469\ide.exe 04.08.2009 09:53:40, user: kasome name = 新細明體 height = 12 q = 0
int Font::FindFaceNameIndex(const String& name) { if(name == "STDFONT") return 0; DUMP(name); DUMP(name.GetLength()); DUMP(GetFaceCount()); for(int i = 1; i < GetFaceCount(); i++){ LOG( "GetFaceName(" << i << ") = " << GetFaceName(i) ); LOG( "GetFaceName(" << i << ").GetLength() = " << GetFaceName(i).GetLength() ); if(GetFaceName(i) == name){ return i; } } String n = Filter(name, FontFilter); for(int i = 1; i < GetFaceCount(); i++) if(Filter(GetFaceName(i), FontFilter) == n) return i; return 0; }
* c:\2009_08_10\MSC8.Debug.Debug_full.Gui\ide.exe 08.08.2009 18:39:20, user: kasome name = 新細明體 ==> the font we want to find ( it is encoded by "Big5", ==> a local character encoding method used in Taiwan for ==> Traditional Chinese characters ) name.GetLength() = 8 ==> it's length is 8 (2 bytes for one Chinese character) GetFaceCount() = 91 GetFaceName(1) = Times New Roman GetFaceName(1).GetLength() = 15 GetFaceName(2) = Arial GetFaceName(2).GetLength() = 5 GetFaceName(3) = Courier New GetFaceName(3).GetLength() = 11 .......................... GetFaceName(44) = Sylfaen GetFaceName(44).GetLength() = 7 GetFaceName(45) = 標楷體 GetFaceName(45).GetLength() = 9 GetFaceName(46) = 細明體 GetFaceName(46).GetLength() = 9 GetFaceName(47) = 新細明體 ==> the matched font ( it is encoded by "UTF8" ) GetFaceName(47).GetLength() = 12 ==> it's length is 12 (3 bytes for one Chinese character) GetFaceName(48) = Microsoft Sans Serif GetFaceName(48).GetLength() = 20 ...........................
void GetStdFontSys(String& name, int& height) { #ifdef PLATFORM_WINCE name = "Arial"; height = 10; #else NONCLIENTMETRICS ncm; ncm.cbSize = sizeof(ncm); ::SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(ncm), &ncm, 0); // name = ncm.lfMenuFont.lfFaceName; ==> original name = FromSystemCharset(ncm.lfMenuFont.lfFaceName); ==> modified height = abs((int)ncm.lfMenuFont.lfHeight); #endif }