/src/compiler/android-ndk/jni/freetype/include/freetype/internal/services/svcid.h

http://ftk.googlecode.com/ · C++ Header · 83 lines · 45 code · 21 blank · 17 comment · 0 complexity · 491412dd5d4315b7043c0f8d86eafe13 MD5 · raw file

  1. /***************************************************************************/
  2. /* */
  3. /* svcid.h */
  4. /* */
  5. /* The FreeType CID font services (specification). */
  6. /* */
  7. /* Copyright 2007, 2009 by Derek Clegg, Michael Toftdal. */
  8. /* */
  9. /* This file is part of the FreeType project, and may only be used, */
  10. /* modified, and distributed under the terms of the FreeType project */
  11. /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
  12. /* this file you indicate that you have read the license and */
  13. /* understand and accept it fully. */
  14. /* */
  15. /***************************************************************************/
  16. #ifndef __SVCID_H__
  17. #define __SVCID_H__
  18. #include FT_INTERNAL_SERVICE_H
  19. FT_BEGIN_HEADER
  20. #define FT_SERVICE_ID_CID "CID"
  21. typedef FT_Error
  22. (*FT_CID_GetRegistryOrderingSupplementFunc)( FT_Face face,
  23. const char* *registry,
  24. const char* *ordering,
  25. FT_Int *supplement );
  26. typedef FT_Error
  27. (*FT_CID_GetIsInternallyCIDKeyedFunc)( FT_Face face,
  28. FT_Bool *is_cid );
  29. typedef FT_Error
  30. (*FT_CID_GetCIDFromGlyphIndexFunc)( FT_Face face,
  31. FT_UInt glyph_index,
  32. FT_UInt *cid );
  33. FT_DEFINE_SERVICE( CID )
  34. {
  35. FT_CID_GetRegistryOrderingSupplementFunc get_ros;
  36. FT_CID_GetIsInternallyCIDKeyedFunc get_is_cid;
  37. FT_CID_GetCIDFromGlyphIndexFunc get_cid_from_glyph_index;
  38. };
  39. #ifndef FT_CONFIG_OPTION_PIC
  40. #define FT_DEFINE_SERVICE_CIDREC(class_, get_ros_, \
  41. get_is_cid_, get_cid_from_glyph_index_ ) \
  42. static const FT_Service_CIDRec class_ = \
  43. { \
  44. get_ros_, get_is_cid_, get_cid_from_glyph_index_ \
  45. };
  46. #else /* FT_CONFIG_OPTION_PIC */
  47. #define FT_DEFINE_SERVICE_CIDREC(class_, get_ros_, \
  48. get_is_cid_, get_cid_from_glyph_index_ ) \
  49. void \
  50. FT_Init_Class_##class_( FT_Library library, \
  51. FT_Service_CIDRec* clazz) \
  52. { \
  53. FT_UNUSED(library); \
  54. clazz->get_ros = get_ros_; \
  55. clazz->get_is_cid = get_is_cid_; \
  56. clazz->get_cid_from_glyph_index = get_cid_from_glyph_index_; \
  57. }
  58. #endif /* FT_CONFIG_OPTION_PIC */
  59. /* */
  60. FT_END_HEADER
  61. #endif /* __SVCID_H__ */
  62. /* END */