grid.h 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. /*
  2. Copyright 1993, 1998 The Open Group
  3. Permission to use, copy, modify, distribute, and sell this software and its
  4. documentation for any purpose is hereby granted without fee, provided that
  5. the above copyright notice appear in all copies and that both that
  6. copyright notice and this permission notice appear in supporting
  7. documentation.
  8. The above copyright notice and this permission notice shall be included
  9. in all copies or substantial portions of the Software.
  10. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  11. OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  12. MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  13. IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
  14. OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
  15. ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  16. OTHER DEALINGS IN THE SOFTWARE.
  17. Except as contained in this notice, the name of The Open Group shall
  18. not be used in advertising or otherwise to promote the sale, use or
  19. other dealings in this Software without prior written authorization
  20. from The Open Group.
  21. */
  22. #ifndef _FontGrid_h_
  23. #define _FontGrid_h_
  24. #ifdef XRENDER
  25. #include <X11/Xft/Xft.h>
  26. #include <X11/extensions/Xrender.h>
  27. #endif
  28. typedef struct _FontGridRec *FontGridWidget;
  29. extern WidgetClass fontgridWidgetClass;
  30. #define XtNcellRows "cellRows"
  31. #define XtCCellRows "CellRows"
  32. #define XtNcellColumns "cellColumns"
  33. #define XtCCellColumns "CellColumns"
  34. #define XtNcellWidth "cellWidth"
  35. #define XtCCellWidth "CellWidth"
  36. #define XtNcellHeight "cellHeight"
  37. #define XtCCellHeight "CellHeight"
  38. #define XtNcenterChars "centerChars"
  39. #define XtCCenterChars "CenterChars"
  40. #define XtNboxChars "boxChars"
  41. #define XtCBoxChars "BoxChars"
  42. #define XtNboxColor "boxColor"
  43. #define XtCBoxColor "BoxColor"
  44. #define XtNstartChar "startChar"
  45. #define XtCStartChar "StartChar"
  46. #define XtNinternalPad "internalPad"
  47. #define XtCInternalPad "InternalPad"
  48. #define XtNgridWidth "gridWidth"
  49. #define XtCGridWidth "GridWidth"
  50. #define XtRXftColor "XftColor"
  51. #define XtNface "face"
  52. #define XtCFace "Face"
  53. #define XtRXftFont "XftFont"
  54. typedef struct _FontGridCharRec {
  55. #ifdef XRENDER
  56. XftFont * theface;
  57. #endif
  58. XFontStruct * thefont;
  59. long thechar;
  60. } FontGridCharRec;
  61. extern void GetFontGridCellDimensions(
  62. Widget,
  63. long *,
  64. int *,
  65. int *
  66. );
  67. extern void GetPrevNextStates(
  68. Widget,
  69. Bool *,
  70. Bool *,
  71. Bool *,
  72. Bool *
  73. );
  74. long
  75. GridFirstChar (Widget w);
  76. long
  77. GridLastChar (Widget w);
  78. #endif /* _FontGrid_h_ */