svbdf.h 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. /***************************************************************************/
  2. /* */
  3. /* svbdf.h */
  4. /* */
  5. /* The FreeType BDF services (specification). */
  6. /* */
  7. /* Copyright 2003, 2009, 2012 by */
  8. /* David Turner, Robert Wilhelm, and Werner Lemberg. */
  9. /* */
  10. /* This file is part of the FreeType project, and may only be used, */
  11. /* modified, and distributed under the terms of the FreeType project */
  12. /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
  13. /* this file you indicate that you have read the license and */
  14. /* understand and accept it fully. */
  15. /* */
  16. /***************************************************************************/
  17. #ifndef __SVBDF_H__
  18. #define __SVBDF_H__
  19. #include FT_BDF_H
  20. #include FT_INTERNAL_SERVICE_H
  21. FT_BEGIN_HEADER
  22. #define FT_SERVICE_ID_BDF "bdf"
  23. typedef FT_Error
  24. (*FT_BDF_GetCharsetIdFunc)( FT_Face face,
  25. const char* *acharset_encoding,
  26. const char* *acharset_registry );
  27. typedef FT_Error
  28. (*FT_BDF_GetPropertyFunc)( FT_Face face,
  29. const char* prop_name,
  30. BDF_PropertyRec *aproperty );
  31. FT_DEFINE_SERVICE( BDF )
  32. {
  33. FT_BDF_GetCharsetIdFunc get_charset_id;
  34. FT_BDF_GetPropertyFunc get_property;
  35. };
  36. #ifndef FT_CONFIG_OPTION_PIC
  37. #define FT_DEFINE_SERVICE_BDFRec( class_, \
  38. get_charset_id_, \
  39. get_property_ ) \
  40. static const FT_Service_BDFRec class_ = \
  41. { \
  42. get_charset_id_, get_property_ \
  43. };
  44. #else /* FT_CONFIG_OPTION_PIC */
  45. #define FT_DEFINE_SERVICE_BDFRec( class_, \
  46. get_charset_id_, \
  47. get_property_ ) \
  48. void \
  49. FT_Init_Class_ ## class_( FT_Service_BDFRec* clazz ) \
  50. { \
  51. clazz->get_charset_id = get_charset_id_; \
  52. clazz->get_property = get_property_; \
  53. }
  54. #endif /* FT_CONFIG_OPTION_PIC */
  55. /* */
  56. FT_END_HEADER
  57. #endif /* __SVBDF_H__ */
  58. /* END */