Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

122 lines
3.3 KiB

  1. //
  2. // PAGE.HPP
  3. // Page Class
  4. //
  5. // Copyright Microsoft 1998-
  6. //
  7. #ifndef __PAGE_HPP_
  8. #define __PAGE_HPP_
  9. //
  10. // Purpose: Handler for page of graphic objects
  11. //
  12. class DCWbGraphic;
  13. class DCWbGraphicPointer;
  14. //
  15. // Retrieving object data
  16. //
  17. PWB_GRAPHIC PG_GetData(WB_PAGE_HANDLE hPage, WB_GRAPHIC_HANDLE hGraphic);
  18. //
  19. // Allocating space for new objects
  20. //
  21. PWB_GRAPHIC PG_AllocateGraphic(WB_PAGE_HANDLE hPage, DWORD length);
  22. DCWbGraphic* PG_First(WB_PAGE_HANDLE hPage, WB_GRAPHIC_HANDLE * phGraphic, LPCRECT lprcUpdate=NULL, BOOL bCheckReallyHit=FALSE);
  23. DCWbGraphic* PG_Next(WB_PAGE_HANDLE hPage, WB_GRAPHIC_HANDLE * phGraphic, LPCRECT lprcUpdate=NULL, BOOL bCheckReallyHit=FALSE);
  24. DCWbGraphic* PG_After(WB_PAGE_HANDLE hPage, const DCWbGraphic& graphic);
  25. DCWbGraphic* PG_Before(WB_PAGE_HANDLE hPage, const DCWbGraphic& graphic);
  26. //
  27. // Retrieving remote pointer objects
  28. //
  29. DCWbGraphicPointer* PG_FirstPointer(WB_PAGE_HANDLE hPage, POM_OBJECT * ppUserNext);
  30. DCWbGraphicPointer* PG_NextPointer(WB_PAGE_HANDLE hPage, POM_OBJECT * ppUserNext);
  31. DCWbGraphicPointer* PG_NextPointer(WB_PAGE_HANDLE hPage, const DCWbGraphicPointer* pPointer);
  32. DCWbGraphicPointer* PG_LocalPointer(WB_PAGE_HANDLE);
  33. //
  34. // Deleting all objects
  35. //
  36. void PG_Clear(WB_PAGE_HANDLE hPage);
  37. //
  38. // Selecting objects
  39. //
  40. DCWbGraphic* PG_SelectLast(WB_PAGE_HANDLE hPage, POINT pt);
  41. DCWbGraphic* PG_SelectPrevious(WB_PAGE_HANDLE hPage, const DCWbGraphic& graphic,
  42. POINT pt);
  43. //
  44. // Return TRUE if the specified object is topmost in the page
  45. //
  46. BOOL PG_IsTopmost(WB_PAGE_HANDLE hPage, const DCWbGraphic* pGraphic);
  47. //
  48. // Update an existing object
  49. //
  50. void PG_GraphicUpdate(WB_PAGE_HANDLE hPage, WB_GRAPHIC_HANDLE *phGraphic,
  51. PWB_GRAPHIC pHeader);
  52. void PG_GraphicReplace(WB_PAGE_HANDLE hPage, WB_GRAPHIC_HANDLE *phGraphic,
  53. PWB_GRAPHIC pHeader);
  54. void PG_GraphicDelete(WB_PAGE_HANDLE hPage, const DCWbGraphic& graphic);
  55. //
  56. // Return the bounding rectangle of all the graphics on the page
  57. //
  58. void PG_GetAreaInUse(WB_PAGE_HANDLE hPage, LPRECT lprcArea);
  59. //
  60. // Draw the entire contents of the page into the device context
  61. // specified.
  62. //
  63. void PG_Draw(WB_PAGE_HANDLE hPage, HDC hdc, BOOL thumbNail = FALSE);
  64. //
  65. // Print an area of the page to the specified DC
  66. //
  67. void PG_Print(WB_PAGE_HANDLE hPage, HDC hdcPrinter, LPCRECT lprcArea);
  68. //
  69. // Return the palette to be used for displaying the page
  70. //
  71. HPALETTE PG_GetPalette(void);
  72. void PG_InitializePalettes(void);
  73. void PG_ReinitPalettes(void);
  74. //
  75. // Return the intersection of the given graphic's bounding rectangle
  76. // and any objects which are obscuring it
  77. //
  78. void PG_GetObscuringRect(WB_PAGE_HANDLE hPage, DCWbGraphic* pGraphic, LPRECT lprcObscuring);
  79. WB_GRAPHIC_HANDLE PG_ZGreaterGraphic(WB_PAGE_HANDLE hPage, WB_GRAPHIC_HANDLE hLastGraphic,
  80. WB_GRAPHIC_HANDLE hTestGraphic );
  81. //
  82. // Search for the next active pointer on this page
  83. //
  84. DCWbGraphicPointer* PG_LookForPointer(WB_PAGE_HANDLE hPage, POM_OBJECT hUser);
  85. //
  86. // Retrieving pages
  87. //
  88. WB_PAGE_HANDLE PG_GetNextPage(WB_PAGE_HANDLE hPage);
  89. WB_PAGE_HANDLE PG_GetPreviousPage(WB_PAGE_HANDLE hPage);
  90. //
  91. // Getting the index of a page
  92. //
  93. WB_PAGE_HANDLE PG_GetPageNumber(UINT uiPageNo);
  94. #endif // __PAGE_HPP_