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.

86 lines
2.5 KiB

  1. /************************************************************/
  2. /* Windows Write, Copyright 1985-1992 Microsoft Corporation */
  3. /************************************************************/
  4. //#define prmNil 0
  5. #define docNil (-1)
  6. #define cpNil ((typeCP) -1)
  7. #define cpMax ((typeCP) 2147483647)
  8. #define fcNil ((typeFC) -1)
  9. #define cp0 ((typeCP) 0)
  10. #define fnNil (32767)
  11. #define fc0 ((typeFC) 0)
  12. #define tcMax 255
  13. #ifdef SAND
  14. #define xaMax 9500
  15. #endif
  16. #define pn0 ((typePN) 0)
  17. #define cdocInit 4
  18. #define cwExpand 256
  19. #define cchMaxExpand (cwExpand * sizeof (int))
  20. /* FetchCp Modes */
  21. #define fcmChars 1
  22. #define fcmProps 2
  23. #define fcmBoth (fcmChars + fcmProps)
  24. #define fcmNoExpand 4
  25. #define fcmParseCaps 8 /* Return separate runs for U&lc if sm. caps*/
  26. /* Document types -- two bits only */
  27. #define dtyNormal 0
  28. #define dtyBuffer 1
  29. #define dtySsht 2
  30. #define dtyPrd 3
  31. #define dtySystem 4 /* Never written; smashed to dtyNormal */
  32. #define dtyHlp 5 /* Never written */
  33. #define dtyNormNoExt 6 /* Never written */
  34. #ifdef INTL /* international version */
  35. #define dtyWordDoc 6 /* when saving in Word format */
  36. #endif /* international version */
  37. #define dtyNetwork 7 /* Never written; smashed to dtyNormal */
  38. #define dtyAny 0
  39. struct DOD
  40. { /* Document descriptor */
  41. struct PCTB **hpctb; /* Piece table */
  42. typeCP cpMac; /* Number of lexemes in doc */
  43. unsigned fFormatted : 1; /* Default save is formatted */
  44. unsigned fDirty : 1; /* Document has been edited */
  45. unsigned fAbsLooks : 1; /* Absolute looks applied */
  46. unsigned fBackup : 1; /* Make auto backup of file? */
  47. unsigned fReadOnly: 1; /* Read only doc (no edits allowed)? */
  48. unsigned fDisplayable : 1;
  49. unsigned : 4;
  50. unsigned dty : 2; /* Document type */
  51. unsigned cref : 4; /* Reference count */
  52. CHAR (**hszFile)[]; /* Document name */
  53. struct FNTB **hfntb; /* Footnote table */
  54. #ifdef CASHMERE
  55. struct SETB **hsetb; /* Section table */
  56. #else
  57. struct SEP **hsep; /* Section properties */
  58. #endif
  59. int docSsht; /* Style sheet if dty == dtySsht */
  60. struct PGTB **hpgtb; /* Page table (for Jump Page) */
  61. struct FFNTB **hffntb; /* font name table */
  62. struct TBD (**hgtbd)[]; /* Table of tab stops */
  63. #ifdef SAND
  64. int vref; /* Volume that this document is on */
  65. #endif /* SAND */
  66. };
  67. #define cwDOD (sizeof (struct DOD) / sizeof (int))
  68. #define cbDOD (sizeof (struct DOD))
  69. struct FNTB **HfntbGet();
  70.