Source code of Windows XP (NT5)
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.

628 lines
21 KiB

  1. /*-------------------------------------------------------------------------
  2. | Objects.h |
  3. | Copyright (C) 1989 Microsoft Corporation |
  4. | |
  5. | mattb 4/19/89 |
  6. |-------------------------------------------------------------------------|
  7. | This file contains definitions associated with the layout objects used |
  8. | in help. |
  9. -------------------------------------------------------------------------*/
  10. #ifndef __OBJECTS_H__
  11. #define __OBJECTS_H__
  12. #include <address.h> // for VA
  13. #include <hash.h> // for HASH
  14. /*-------------------------------------------------------------------------
  15. | Objects fall in two ranges: Uncounted objects and counted objects. |
  16. | For uncounted objects, the count of object regions is contained in a |
  17. | fixed array, or calculated on the fly. (see datapres.c) |
  18. -------------------------------------------------------------------------*/
  19. #define bTypeParaGroup 1 /* Object type indicating paragraph group */
  20. #define bTypeTopic 2 /* Object type indicating topic break */
  21. #define bTypeBitmap 3 /* Bitmap */
  22. #define bTypeSbys 4 /* Side-by-side paragraphs */
  23. #define bTypeWindow 5 /* Windows */
  24. #define bTypeMarker 6 /* Generic inter-layout marker */
  25. #define MAX_UNCOUNTED_OBJ_TYPE 16 /* Unused numbers are reserved for future
  26. use. While uncounted objects can
  27. actually go up to 31, going past 15 will
  28. break the file format. */
  29. #define bTypeParaGroupCounted 32 /* Object type indicating paragraph group */
  30. #define bTypeTopicCounted 33 /* Object type indicating topic break */
  31. #define bTypeBitmapCounted 34 /* Bitmap */
  32. #define bTypeSbysCounted 35 /* Side-by-side paragraphs */
  33. #define bTypeWindowCounted 36 /* Windows */
  34. #define bTypeMultiParaGroup 37 /* Array of paragraph groups */
  35. #define MAX_OBJ_TYPE 37
  36. #define bMagicMBHD 0x11
  37. #define bMagicMFCP 0x22
  38. #define bMagicMOBJ 0x33
  39. #define bMagicMTOP 0x44
  40. #define bMagicMOPG 0x55
  41. #define bMagicMBMR 0x66
  42. #define bMagicMBHS 0x77
  43. #define bMagicMSBS 0x88
  44. #define bMagicMCOL 0x99
  45. #define cxTabsMax 32 /* Maximum number of tabs in MOPG */
  46. #define cbBLOCK_SIZE 4096 /* Size of blocks in the topic. */
  47. #define cbMAX_BLOCK_SIZE (1<<14) // max size of 2k block after decompress
  48. #define shrFclToBlknum 11 // offset to blknum transform, used in hc
  49. #define bHotspotInvisible 0
  50. #define bHotspotVisible 1
  51. /* Paragraph justification properties */
  52. #define wJustifyMost 2
  53. #define wJustifyLeft 0
  54. #define wJustifyRight 1
  55. #define wJustifyCenter 2
  56. /* Paragraph box line types */
  57. #define wBoxLineMost 5
  58. #define wBoxLineNormal 0
  59. #define wBoxLineThick 1
  60. #define wBoxLineDouble 2
  61. #define wBoxLineShadow 3
  62. #define wBoxLineDotted 4
  63. #define wBoxLineDash 5
  64. /* Border line orientations */
  65. /* The order must match order in MBOX */
  66. #define wBoxBorderNone ((WORD)(-1))
  67. #define wBoxBorderFull 0
  68. #define wBoxBorderTop 0
  69. #define wBoxBorderLeft 1
  70. #define wBoxBorderBottom 2
  71. #define wBoxBorderRight 3
  72. #define wBoxPatternNone 0
  73. #define wBoxPatternDkHoriz 1
  74. #define wBoxPatternDkVert 2
  75. #define wBoxPatternDkFdiag 3
  76. #define wBoxPatternDkBdiag 4
  77. #define wBoxPatternDkCross 5
  78. #define wBoxPatternDkDcross 6
  79. #define wBoxPatternHoriz 7
  80. #define wBoxPatternVert 8
  81. #define wBoxPatternFdiag 9
  82. #define wBoxPatternBdiag 10
  83. #define wBoxPatternCross 11
  84. #define wBoxPatternDcross 12
  85. /* Tab types */
  86. #define wTabTypeMost 3
  87. #define wTabTypeLeft 0
  88. #define wTabTypeRight 1
  89. #define wTabTypeCenter 2
  90. #define wTabTypeDecimal 3
  91. /* Used for various things */
  92. #define ldibNil ((LONG)-1) // Protect comparisons in WIN32
  93. /* End of a side by side paragraph list */
  94. #define cColumnMax 32
  95. #define iColumnNil ((WORD)-1) // (WORD) fixes 32bit BUG !! ARGHH!
  96. // Critical structures that gets messed up in /Zp8
  97. #pragma pack(1)
  98. /* MBHD- Memory resident block header structure */
  99. typedef struct mbhd
  100. {
  101. VA vaFCPPrev;
  102. VA vaFCPNext;
  103. VA vaFCPTopic;
  104. } MBHD, FAR *QMBHD;
  105. /* MFCP- Memory resident FCP header structure */
  106. typedef struct mfcp
  107. {
  108. long lcbSizeCompressed; /* Size of whole FC when compressed */
  109. long lcbSizeText; /* Size of uncompressed text (not FC) */
  110. VA vaPrevFc; /* File address to previous FC */
  111. VA vaNextFc; /* File address to next FC */
  112. ULONG ichText; /* Memory image offset to text */
  113. } MFCP, FAR *QMFCP;
  114. /* MOBJ- Memory resident generic object header */
  115. typedef struct mobj
  116. {
  117. BYTE bType;
  118. LONG lcbSize;
  119. WORD wObjInfo;
  120. } MOBJ, FAR *QMOBJ, FAR *LPMOBJ;
  121. /*** Group macro structures start ***/
  122. /* MTOP contains an offset into the Group subfile.
  123. * This offset serves as a group identifier and also
  124. * indicates where the group macro strings are in the
  125. * file.
  126. */
  127. #define NULLGROUP (0L) // NULL group number for MTOP
  128. #define NOGROUPEXIT ((ULONG)(-1)) // No group exit macros
  129. #define GRPFILENAME "|GMACROS" // Group macros subfile
  130. /*** Structure for group file entry (when not NULLGROUP)
  131. *
  132. * cbGrpMac - byte count of macro data including header
  133. * cbToExit - byte count to exit macros (including header)
  134. * NOGROUPEXIT indicates none
  135. *
  136. *
  137. * This structure is followed by SZ for entry macros and then
  138. * an SZ for exit macros if they exist.
  139. *
  140. * cbGrpMac == sizeof(GMH) means no macros
  141. * cbToExit == sizeof(GMH) means no entry macros
  142. * cbToExit == NOGROUPEXIT means no exit macros
  143. *
  144. * MTOP contains an offset into GRPFILENAME and a count of bytes
  145. * for the size of the macro data. Having the size in MTOP allows
  146. * quicker retreival. A size == sizeof(GMH) means the group
  147. * has no macros.
  148. *
  149. * This technique for determining where the group entry and exit
  150. * macros start is awkward, but there wasn't time to have the
  151. * compiler use a more flexible approach. Note that there
  152. * is no way to add new fields to the end of the group data.
  153. *
  154. ***/
  155. typedef struct gmh_tag {
  156. ULONG cbGrpMac; // cb group data
  157. ULONG cbToExit; // cb to exit macros or NOGROUPEXIT
  158. } GMH;
  159. typedef GMH FAR *QGMH;
  160. /*** Group macro structures end ***/
  161. #if 1
  162. /* MTOP- Memory resident topic object structure */
  163. typedef struct mtopent
  164. {
  165. ADDR addrPrev; /* Physical address */
  166. ADDR addrNext; /* Physical address */
  167. LONG lTopicNo;
  168. VA vaNSR; // non scrollable region, if any, vaNil if none.
  169. VA vaSR; // scrollable region, if any, vaNil if none.
  170. VA vaNextSeqTopic; // next sequential topic, for scrollbar calc.
  171. // For Help 3.0 files this will not be correct in
  172. // the case that there is padding between the MTOP
  173. // and the end of a block.
  174. ULONG ulGrpNum; // Group number
  175. ULONG ulGrpFileOff; // Offset into group file for macros
  176. ULONG cbGrpMacro; // Size of group macros
  177. } MTOP, FAR *QMTOP;
  178. #endif
  179. // The new mv2.0 FC header
  180. typedef struct tagFC {
  181. DWORD dwFcIndex;
  182. DWORD lichCumulativeText; // total of all previous lichText TO DO: REMOVE THIS EVENTUALLY
  183. MVADDR mva;
  184. WORD wUserFlags; // kevynct added
  185. WORD iSubtopic;
  186. LPCSTR lpszSubtopicUnique;
  187. LPCSTR lpszSubtopicTitle;
  188. DWORD lcbSize; // sizeof data + text
  189. DWORD lichText; // offset to text
  190. DWORD lcbText; // sizeof text
  191. LPBYTE lpbData; // start of the whoel thing
  192. DWORD dwReserved1; // Don't touch!
  193. DWORD dwReserved2; // Don't touch!
  194. } FC, FAR *LPFC;
  195. // The new mv2.0 topic header
  196. #pragma warning(disable : 4200) // for zero-sized array
  197. typedef struct tagTOPIC {
  198. HANDLE hTopic;
  199. VOID FAR * lpvMemory; // Using block mgr for strings/FC data
  200. DWORD dwReserved;
  201. DWORD dwReserved2;
  202. DWORD dwUser; // Anything you want!
  203. DWORD dwUserRef; // Anything you want!
  204. DWORD dwAllocatedSize;
  205. DWORD dwBrowseDefault; // zero if none
  206. HASH uhUnique;
  207. WORD wSubtopicCount;
  208. LPCSTR lpszTitle;
  209. LPCSTR lpszUserData;
  210. DWORD dwFcCount;
  211. FC fc[0];
  212. } TOPIC, FAR *LPTOPIC;
  213. #pragma warning(default : 4200)
  214. /* MPFG- Disk resident paragraph flag information */
  215. // kevynct: slightly modified to support paragraph styles
  216. typedef struct mpfg
  217. {
  218. // (kevynct) I have unionized the MPFG as it should have been in the first place.
  219. // but this will break the file format, so I'm ifdefing for now.
  220. // the difference is that in the old format, there was a separate SHORT for a style number
  221. // and another SHORT for the flags. if MV20_STYLEONLY is defined, these structures will be
  222. // merged and an fStyle added to the flags for the case where both a para style and para attributes
  223. // are specified.
  224. #ifdef MV20_STYLEONLY
  225. union {
  226. #endif //MV20_STYLEONLY
  227. struct {
  228. unsigned short fStyleOnly:1; // if set, mopg consists of a style number only and no more flags...
  229. unsigned short wStyle:15; // in the past, this was never set, and for rgf never will be
  230. } st;
  231. struct {
  232. #ifdef MV20_STYLEONLY
  233. unsigned short fStyleOnly:1;
  234. #endif //MV20_STYLEONLY
  235. unsigned short fMoreFlags:1;
  236. unsigned short fSpaceOver:1;
  237. unsigned short fSpaceUnder:1;
  238. unsigned short fLineSpacing:1;
  239. unsigned short fLeftIndent:1;
  240. unsigned short fRightIndent:1;
  241. unsigned short fFirstIndent:1;
  242. unsigned short fTabSpacing:1;
  243. unsigned short fBoxed:1;
  244. unsigned short fTabs:1;
  245. unsigned short wJustify:2;
  246. unsigned short fSingleLine:1;
  247. #ifdef MV20_STYLEONLY
  248. unsigned short fStyle:1;
  249. unsigned short wUnused:1;
  250. #else
  251. unsigned short wUnused:2;
  252. #endif //MV20_STYLEONLY
  253. } rgf;
  254. #ifdef MV20_STYLEONLY
  255. }
  256. #endif //MV20_STYLEONLY
  257. } MPFG, FAR *QMPFG, FAR *LPMPFG;
  258. typedef struct tagMBRD
  259. {
  260. unsigned short wLineType;
  261. unsigned short wWidth; // in twips.
  262. unsigned short wDistance; // distance from text, in twips
  263. unsigned long dwColor; // COLORREF
  264. } MBRD, FAR *LPMBRD;
  265. #define IS_VISIBLE_MBOX(x) ((x).fBorderAtAll || (x).fHasShading || (x).fHasPattern)
  266. /* MBOX- Memory/disk resident paragraph frame record */
  267. typedef struct mbox
  268. {
  269. // these initial flags describe the lines that are present in the box.
  270. // MBOX structures occur in the same order as the flags if they are present
  271. union {
  272. unsigned short wFlags;
  273. struct {
  274. unsigned short fBorderAtAll:1;
  275. unsigned short fFullBox:1; // if true, there is only one MBRD which is used for all lines
  276. unsigned short fTopLine:1; // else these four bits describe the MBRDs present
  277. unsigned short fLeftLine:1;
  278. unsigned short fBottomLine:1;
  279. unsigned short fRightLine:1;
  280. unsigned short fHasShading:1; // true if percent shading is used
  281. unsigned short fHasPattern:1; // true if pattern is used. mutex with shading if set
  282. unsigned short bUnused:8;
  283. };
  284. };
  285. union {
  286. unsigned short wPercentShading; // percent shading value.
  287. unsigned short wBoxPattern;
  288. };
  289. unsigned long dwClrPatFore; // line color for bkground patter.
  290. unsigned long dwClrPatBack; // background color for bkground patter.
  291. MBRD rgmbrd[4]; // up to four different lines can be part of a box
  292. } MBOX, FAR *QMBOX, FAR *LPMBOX;
  293. /* TAB: Tab data structure */
  294. typedef struct tab
  295. {
  296. SHORT x;
  297. SHORT wType;
  298. } TAB, FAR *QTAB;
  299. #define wParaStyleNil ((SHORT) 0x7FFF)
  300. #define wParaStyleDefault ((SHORT) 0)
  301. /* MOPG- Memory resident paragraph group object structure */
  302. typedef struct mopg
  303. {
  304. long libText;
  305. SHORT wStyle; // kevynct: the (optional) paragraph style to apply
  306. SHORT iFnt;
  307. SHORT fMoreFlags;
  308. SHORT fBoxed;
  309. SHORT wJustify;
  310. SHORT fSingleLine;
  311. SHORT wUnused;
  312. long lMoreFlags;
  313. SHORT ySpaceOver;
  314. SHORT ySpaceUnder;
  315. SHORT yLineSpacing;
  316. SHORT xLeftIndent;
  317. SHORT xRightIndent;
  318. SHORT xFirstIndent;
  319. SHORT xTabSpacing;
  320. MBOX mbox;
  321. SHORT cTabs;
  322. TAB rgtab[cxTabsMax];
  323. } MOPG, FAR *QMOPG, FAR *LPMOPG;
  324. // Values that can be used in the lMoreFlags field.
  325. #define PF_SIZESINTWIPS 0x00000001
  326. /* MBMR- Memory/disk resident bitmap record (layout component) */
  327. typedef struct mbmr
  328. {
  329. BYTE bVersion;
  330. SHORT dxSize;
  331. SHORT dySize;
  332. SHORT wColor;
  333. SHORT cHotspots;
  334. LONG lcbData;
  335. } MBMR, FAR *QMBMR;
  336. /* MBHS- Memory / disk resident bitmap hotspot record */
  337. typedef struct mbhs
  338. {
  339. BYTE bType;
  340. BYTE bAttributes;
  341. BYTE bFutureRegionType;
  342. SHORT xPos;
  343. SHORT yPos;
  344. SHORT dxSize;
  345. SHORT dySize;
  346. long lBinding;
  347. } MBHS, FAR *QMBHS;
  348. /* MSBS- Memory/disk resident side by side paragraph group object structure */
  349. typedef struct msbs
  350. {
  351. BYTE bcCol;
  352. BYTE bFlags;
  353. // new members go here
  354. SHORT dxRowIndent;
  355. SHORT dxRowWidth; // used for relative spacing: stores total width of table, zero otherwise
  356. SHORT dyRowHeight; // height of the table row in twips: zero if "automatic", < 0 if "absolute", > 0 if "at least"
  357. } MSBS, FAR *QMSBS, FAR *LPMSBS;
  358. // Values for use with the bFlags field of the MSBS structure.
  359. #define MSBS_ABSOLUTE 0x0001 // Must be 1 to correspond to old version
  360. #define MSBS_SIZESINTWIPS 0x0002
  361. /* MCOL- Memory/disk resident column structure */
  362. typedef struct mcol
  363. {
  364. unsigned short xWidthColumn; // cell width
  365. unsigned short xWidthSpace; // space between cells
  366. // new members for mv2.0
  367. MBOX mbox; // the cell's border formatting
  368. } MCOL, FAR *QMCOL, FAR *LPMCOL;
  369. /* MWIN- Memory/disk resident embedded window object structure */
  370. typedef struct mwin
  371. {
  372. WORD wStyle;
  373. SHORT dx;
  374. SHORT dy;
  375. char szData[1];
  376. } MWIN, FAR *QMWIN;
  377. // Critical structure that gets messed up in /Zp8
  378. #pragma pack()
  379. //wjc Size of command and data for searcher commands (see below)
  380. #define cbSearchFieldCommand 5
  381. #define cbDTypeCommand 3
  382. #define cbAliasCommand 7
  383. #define chCommand 0x00 /* Indicates a parallel command in text */
  384. // The following definitions describe the commands used in the layout command table.
  385. //
  386. // (kevynct) The following three commands were added during Viewer and are never used
  387. // at run-time. They really shouldn't have been put in here.
  388. // (kevynct) Removed for mv2.0, but not removed from cmd table space. sigh.
  389. #define bSearchFieldCommand 0x20 /* Followed by 4 byte ident */
  390. #define bDTypeCommand 0x21 /* Followed by 2 byte unsigned */
  391. #define bAliasCommand 0x22 /* Followed by 6 bytes (alias idx & highlight length) */
  392. #define IsFormatCommand(b) ((b) >= bSmallFormat0 && (b) <= bWordFormat)
  393. // Format change commands: the order of these should not be changed
  394. #define GetSmallFormat(b) ((b) & 0x0f)
  395. #define IsSmallFormat(b) ((b) & 0x0f) == bSmallFormat0)
  396. #define IsMediumFormat(b) ((b) == bByteFormat)
  397. #define bSmallFormat0 0x60 // Format change: 0 (least-sig nibble must be zero)
  398. #define bSmallFormat1 0x61 // Format change: 1
  399. #define bSmallFormat2 0x62 // Format change: 2
  400. #define bSmallFormat3 0x63 // Format change: 3
  401. #define bSmallFormat4 0x64 // Format change: 4
  402. #define bSmallFormat5 0x65 // Format change: 5
  403. #define bSmallFormat6 0x66 // Format change: 6
  404. #define bSmallFormat7 0x67 // Format change: 7
  405. #define bSmallFormat8 0x68 // Format change: 8
  406. #define bSmallFormat9 0x69 // Format change: 9
  407. #define bSmallFormat10 0x6a // Format change: 10
  408. #define bSmallFormat11 0x6b // Format change: 11
  409. #define bSmallFormat12 0x6c // Format change: 12
  410. #define bSmallFormat13 0x6d // Format change: 13
  411. #define bSmallFormat14 0x6e // Format change: 14
  412. #define bSmallFormat15 0x6f // Format change: 15
  413. #define bByteFormat 0x70 // Format change: (one-byte arg) 16-255. Must follow bSmallFormat15
  414. // New commands are allowed in this space
  415. #define bWordFormat 0x80 /* Format change, two byte arg (0-32767) */
  416. #define bNewLine 0x81 /* Newline */
  417. #define bNewPara 0x82 /* New paragraph */
  418. #define bTab 0x83 /* Left-aligned tab */
  419. #define bBlankLine 0x85 /* Followed by 16 bit skip count */
  420. #define bInlineObject 0x86 /* Followed by inline layout object */
  421. #define bWrapObjLeft 0x87 /* Left- aligned wrapping object */
  422. #define bWrapObjRight 0x88 /* Right-aligned wrapping object */
  423. #define bEndHotspot 0x89 /* End of a hotspot */
  424. #define bColdspot 0x8A /* Coldspot for searchable bitmaps */
  425. #define bNoBreakSpace 0x8B /* a non-breaking space */
  426. #define bOptionalHyphen 0x8C /* a potentially existing hypen */
  427. #define bBeginFold 0x8D // start of collapsable region
  428. #define bEndFold 0x8E // end of collapsable region
  429. /*
  430. Coldspot Commands
  431. A "coldspot" is understood by the runtime but not added
  432. to the hotspot list, since it is not a hotspot. This is used
  433. to create searchable regions in metafiles and bitmaps. Coldspots are
  434. always invisible, and currently not inserted into the command table.
  435. */
  436. /*
  437. Hotspot Commands
  438. Hotspot commands have first nibble of E or C.
  439. E - normal hotspot
  440. C - macro
  441. Bits in the second nibble have the following meaning:
  442. (set) (clear)
  443. 8 - long short
  444. 4 - invisible visible
  445. 2 - ITO HASH
  446. 1 - jump popup
  447. Long hotspots are followed by a word count prefixed block of binding
  448. data. The count does not include the command byte or the count word.
  449. Short hotspots are followed by four bytes of binding data.
  450. ** Note that some of the combinations of bits are meaningless.
  451. */
  452. #define fHSMask 0xD0
  453. #define fHS 0xC0
  454. #define fHSNorm 0x20
  455. #define fHSLong 0x08
  456. #define fHSInv 0x04
  457. #define fHSHash 0x02
  458. #define fHSJump 0x01
  459. #define FHotspot( b ) (((b) & fHSMask ) == fHS )
  460. #define FNormalHotspot( b ) (((b) & (fHSMask|fHSNorm)) == (fHS|fHSNorm))
  461. #define FLongHotspot( b ) (((b) & (fHSMask|fHSLong)) == (fHS|fHSLong))
  462. #define FInvisibleHotspot( b ) (((b) & (fHSMask|fHSInv )) == (fHS|fHSInv ))
  463. #define FHashHotspot( b ) (((b) & (fHSMask|fHSNorm|fHSHash)) == (fHS|fHSNorm|fHSHash))
  464. #define FJumpHotspot( b ) (((b) & (fHSMask|fHSNorm|fHSJump)) == (fHS|fHSNorm|fHSJump))
  465. #define FMacroHotspot( b ) (((b) & (fHSMask|fHSNorm)) == fHS)
  466. #define FShortHotspot( b ) (((b) & (fHSMask|fHSLong)) == fHS)
  467. #define FVisibleHotspot( b ) (((b) & (fHSMask|fHSInv )) == fHS)
  468. #define FItoHotspot( b ) (((b) & (fHSMask|fHSNorm|fHSHash)) == (fHS|fHSNorm))
  469. #define FPopupHotspot( b ) (((b) & (fHSMask|fHSNorm|fHSJump)) == (fHS|fHSNorm))
  470. #define bLongMacro (fHS |fHSLong )
  471. //
  472. //
  473. //
  474. #define bLongMacroInv (fHS |fHSLong|fHSInv )
  475. //
  476. //
  477. //
  478. #define bShortUidPopup (fHS|fHSNorm )
  479. #define bShortUidJump (fHS|fHSNorm |fHSJump)
  480. #define bShortHashPopup (fHS|fHSNorm |fHSHash )
  481. #define bShortHashJump (fHS|fHSNorm |fHSHash|fHSJump)
  482. // (fHS|fHSNorm |fHSInv )
  483. // (fHS|fHSNorm |fHSInv |fHSJump)
  484. #define bShortInvHashJump (fHS|fHSNorm |fHSInv|fHSHash|fHSJump)
  485. #define bShortInvHashPopup (fHS|fHSNorm |fHSInv|fHSHash )
  486. // (fHS|fHSNorm|fHSLong )
  487. // (fHS|fHSNorm|fHSLong |fHSJump)
  488. #define bLongHashPopup (fHS|fHSNorm|fHSLong |fHSHash )
  489. #define bLongHashJump (fHS|fHSNorm|fHSLong |fHSHash|fHSJump)
  490. // (fHS|fHSNorm|fHSLong|fHSInv )
  491. // (fHS|fHSNorm|fHSLong|fHSInv |fHSJump)
  492. #define bLongInvHashPopup (fHS|fHSNorm|fHSLong|fHSInv|fHSHash )
  493. #define bLongInvHashJump (fHS|fHSNorm|fHSLong|fHSInv|fHSHash|fHSJump)
  494. #define bEnd 0xFF /* End of text */
  495. // Upon encountering an embedded window with a class name of
  496. // EW_CALLBACK_CLASS, a special EW will be created and the data for
  497. // the embedded window will be saved. Upon an attempt to render this
  498. // embedded window, instead of actually creating a window, MediaView
  499. // will execute the qde->lpfnHotspotCallback() routine with a hotspot
  500. // of type HOTSPOT_EWSHOWN and with a pointer to the saved string
  501. // containing the data for the embedded window.
  502. #define EW_CALLBACK_CLASS "MVEWCallBack"
  503. #ifndef CONTENTTYPE_DEFINED
  504. #define CONTENTTYPE_DEFINED
  505. enum CONTENTTYPE
  506. {
  507. CONTENT_TEXT,
  508. CONTENT_BITMAP,
  509. CONTENT_WINDOW,
  510. CONTENT_UNKNOWN
  511. };
  512. #endif // CONTENTTYPE_DEFINED
  513. // These first four hotspot types are public.
  514. // They MUST correspond to those in MEDV14.H
  515. #define HOTSPOT_STRING 0
  516. #define HOTSPOT_HASH 1
  517. #define HOTSPOT_POPUPHASH 2
  518. #define HOTSPOT_UNKNOWN 3
  519. // These next six are not public.
  520. #define HOTSPOT_TOPICUID 4
  521. #define HOTSPOT_POPUPTOPICUID 5
  522. #define HOTSPOT_JI 6
  523. #define HOTSPOT_POPUPJI 7
  524. #define HOTSPOT_EWSHOWN 8 // Occurs when an embedded window with
  525. // the classname EW_CALLBACK_CLASS is shown.
  526. #define HOTSPOT_EWHIDDEN 9 // Occurs when an embedded window with the
  527. // classname EW_CALLBACK_CLASS is hidden.
  528. /* Function prototypes */
  529. VOID PASCAL FAR GetMacMFCP (QMFCP qmfcp, unsigned char far * qb);
  530. VOID PASCAL FAR GetMacMBHD (QMBHD qmbhd, unsigned char far * qb);
  531. #endif // !OBJECTS_H