Text Rendering Tech

2,007 views
1,866 views

Published on

0 Comments
6 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
2,007
On SlideShare
0
From Embeds
0
Number of Embeds
8
Actions
Shares
0
Downloads
22
Comments
0
Likes
6
Embeds 0
No embeds

No notes for slide

Text Rendering Tech

  1. 1. jjgod <gzjjgod@gmail.com>
  2. 2. : X11, Mac OS X Win32 ( ) google URL
  3. 3. "hello world" “hello world”
  4. 4. : UTF-8 char *: "hello, world0" ASCII O(1) O(n) str[n] n Unix glib
  5. 5. : UTF-16/UCS-2 short [] = { 0, 'h', 0, 'e', 0, 'l', ... } Little Endian Big Endian ( ) Win32 Unicode Mac OS X Core Foundation, NSFoundation UCS-2 O(1) Plane 1+, Surrogate O(n)
  6. 6. : UTF-32 uint32_t [] = { 'h', 'e', 'l', 'l', 'o' } O(1) 4 ICU
  7. 7. glib: Unicode C ctype.h, string.h (C) libutf-8: UTF-8 (C) libutf8: C UTF-8 wchar_t (C) ICU: Unicode (C/C++)
  8. 8. (character) (glyph) 'h' 'A','´' 'Á'
  9. 9. : Layout Engine Widths in, Heights out. –– David Baron
  10. 10. :
  11. 11. : InstalledFontCollection (.NET), EnumFontFamilies (Win32 API, C) fontconfig: (C) ATS (Apple Type Services): Mac OS X API, Font
  12. 12. : fontconfig (*nix, Mac OS X, Win32) Xft X Hacker Keith Packard (fc-list, fc-match, fc-cache)
  13. 13. : : FreeType API , C API : TrueType, Type 1, OpenType, CFF, CID, dfont, pcf : fontconfig, xft, cairo, pango, ICU : metrics ( )
  14. 14. : : metrics
  15. 15. : Layout Engine Uniscribe: Windows Unicode Layout Engine (C++) pango: GTK+/GNOME (C) ICU: (C++) ATSUI (Apple Type Services for Unicode Imaging): Mac OS X 10.4-, deprecate (C) Core Text: Mac OS X 10.5 (C) Cocoa Text System: Mac OS X (Objective C)
  16. 16. helloworld HelloWorld
  17. 17. : Windows : 16pt : ClearType
  18. 18. : Mac OS X
  19. 19. : FreeType / TrueType Bytecode Interpreter / Auto-hinter Gamma : Maxim Shemanarev, Texts Rasterization Exposures (http://www.antigrain.com/research/font_rasterization)
  20. 20. Win32: Win32 Drawing Context TextOut Mac OS X: Quartz Context ATSUDrawText CGShowGlyphs FreeType pango, cairo
  21. 21. : GTK+ gchar * pango cairo_show_glyphs FT_Face fontconfig FreeType FCFontSet
  22. 22. : Core Text CFSTR * CTTypesetter CTLineDraw CTFont CTFontCollection Core Text CTFontDescriptor
  23. 23. : Win32 WCHAR Uniscribe TextOut HFONT EnumFontFamilies win32 api LOGFONT
  24. 24. Questions?

×