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.

677 lines
25 KiB

  1. /*
  2. * File: tom.idl
  3. *
  4. * idl file that defines the TOM interfaces and data structures
  5. */
  6. #include <olectl.h>
  7. import "oaidl.idl";
  8. import "ocidl.idl";
  9. interface ITextSelection; // Forward declarations
  10. interface ITextRange;
  11. interface ITextFont;
  12. interface ITextPara;
  13. interface ITextStoryRanges;
  14. interface ITextMsgFilter;
  15. interface ITextDocument2;
  16. [uuid(8CC497C9-A1DF-11ce-8098-00AA0047BE5D), version(1.0)]
  17. library tom {
  18. importlib("stdole32.tlb");
  19. typedef enum
  20. {
  21. // Quad State
  22. tomFalse = 0,
  23. tomTrue = -1,
  24. tomUndefined = -9999999,
  25. tomToggle = -9999998,
  26. tomAutoColor = -9999997,
  27. tomDefault = -9999996,
  28. // Undo suspension
  29. tomSuspend = -9999995,
  30. tomResume = -9999994,
  31. tomApplyNow = 0, // TOM 1.1
  32. tomApplyLater = 1, // TOM 1.1
  33. tomTrackParms = 2, // TOM 1.1
  34. tomCacheParms = 3, // TOM 1.1
  35. tomApplyTmp = 4,
  36. // Counts to reach story start or end in any units
  37. tomBackward = 0xc0000001,
  38. tomForward = 0x3fffffff,
  39. tomMove = 0,
  40. tomExtend = 1,
  41. // SelectionType
  42. tomNoSelection = 0,
  43. tomSelectionIP = 1,
  44. tomSelectionNormal = 2,
  45. tomSelectionFrame = 3,
  46. tomSelectionColumn = 4,
  47. tomSelectionRow = 5,
  48. tomSelectionBlock = 6,
  49. tomSelectionInlineShape = 7,
  50. tomSelectionShape = 8,
  51. // Selection flags
  52. tomSelStartActive = 1,
  53. tomSelAtEOL = 2,
  54. tomSelOvertype = 4,
  55. tomSelActive = 8,
  56. tomSelReplace = 16,
  57. // Point from selection parameters
  58. tomEnd = 0, // use End of selection (GetPoint method)
  59. tomStart = 32, // use Start of selection (can't conflict
  60. tomCollapseEnd = 0, // with text align flags, which use low 5
  61. tomCollapseStart = 1, // bits). Extra values also included
  62. tomClientCoord = 256, // use Client Coordinates (GetPoint method)
  63. // default is to use system coordinates
  64. tomAllowOffClient = 512, // Allow pts outside client RECT
  65. // Underline
  66. tomNone = 0,
  67. tomSingle = 1,
  68. tomWords = 2,
  69. tomDouble = 3,
  70. tomDotted = 4,
  71. tomDash = 5,
  72. tomDashDot = 6,
  73. tomDashDotDot = 7,
  74. tomWave = 8,
  75. tomThick = 9,
  76. tomHair = 10,
  77. tomDoubleWave = 11,
  78. tomHeavyWave = 12,
  79. tomLongDash = 13,
  80. tomThickDash = 14,
  81. tomThickDashDot = 15,
  82. tomThickDashDotDot = 16,
  83. tomThickDotted = 17,
  84. tomThickLongDash = 18,
  85. // Line Spacing
  86. tomLineSpaceSingle = 0,
  87. tomLineSpace1pt5 = 1,
  88. tomLineSpaceDouble = 2,
  89. tomLineSpaceAtLeast = 3,
  90. tomLineSpaceExactly = 4,
  91. tomLineSpaceMultiple = 5,
  92. // Paragraph, Numbering, and Tab Alignment
  93. tomAlignLeft = 0,
  94. tomAlignCenter = 1,
  95. tomAlignRight = 2,
  96. tomAlignJustify = 3,
  97. tomAlignDecimal = 3,
  98. tomAlignBar = 4,
  99. tomAlignInterWord = 3,
  100. tomAlignInterLetter = 4,
  101. tomAlignScaled = 5,
  102. tomAlignGlyphs = 6,
  103. tomAlignSnapGrid = 7,
  104. // Tab leader
  105. tomSpaces = 0,
  106. tomDots = 1,
  107. tomDashes = 2,
  108. tomLines = 3,
  109. tomThickLines = 4,
  110. tomEquals = 5,
  111. // Tab index
  112. tomTabBack = -3, // Positive numbers are tab index
  113. tomTabNext = -2, // These are relative indices
  114. tomTabHere = -1,
  115. // Numbering
  116. tomListNone = 0,
  117. tomListBullet = 1,
  118. tomListNumberAsArabic = 2,
  119. tomListNumberAsLCLetter = 3,
  120. tomListNumberAsUCLetter = 4,
  121. tomListNumberAsLCRoman = 5,
  122. tomListNumberAsUCRoman = 6,
  123. tomListNumberAsSequence = 7, // NumberingStart gives first Unicode to use
  124. tomListParentheses = 0x10000,
  125. tomListPeriod = 0x20000,
  126. tomListPlain = 0x30000,
  127. // Units
  128. tomCharacter = 1, // character
  129. tomWord = 2, // word
  130. tomSentence = 3, // sentence
  131. tomParagraph = 4, // paragraph
  132. tomLine = 5, // line (on display)
  133. tomStory = 6, // entire story
  134. tomScreen = 7, // window end (or start) (for Ctrl PgUp/PgDn)
  135. tomSection = 8, // section
  136. tomColumn = 9, // table column if in table
  137. tomRow = 10, // table row
  138. tomWindow = 11, // windowful (for PgUp/PgDn)
  139. tomCell = 12, // table cell
  140. tomCharFormat = 13, // run of constant character formatting
  141. tomParaFormat = 14, // run of constant paragraph formatting
  142. tomTable = 15, // table
  143. tomObject = 16, // embedded object
  144. tomPage = 17, // page (in page views)
  145. // Find flags
  146. tomMatchWord = 2, // Match whole words
  147. tomMatchCase = 4, // Match case
  148. tomMatchPattern = 8, // Match pattern
  149. // Story type
  150. tomUnknownStory = 0,
  151. tomMainTextStory = 1,
  152. tomFootnotesStory = 2,
  153. tomEndnotesStory = 3,
  154. tomCommentsStory = 4,
  155. tomTextFrameStory = 5,
  156. tomEvenPagesHeaderStory = 6,
  157. tomPrimaryHeaderStory = 7,
  158. tomEvenPagesFooterStory = 8,
  159. tomPrimaryFooterStory = 9,
  160. tomFirstPageHeaderStory = 10,
  161. tomFirstPageFooterStory = 11,
  162. // Animations
  163. tomNoAnimation = 0,
  164. tomLasVegasLights = 1,
  165. tomBlinkingBackground = 2,
  166. tomSparkleText = 3,
  167. tomMarchingBlackAnts = 4,
  168. tomMarchingRedAnts = 5,
  169. tomShimmer = 6,
  170. tomWipeDown = 7,
  171. tomWipeRight = 8,
  172. tomAnimationMax = 8,
  173. // Change Case
  174. tomLowerCase = 0,
  175. tomUpperCase = 1,
  176. tomTitleCase = 2,
  177. tomSentenceCase = 4,
  178. tomToggleCase = 5,
  179. // File
  180. tomReadOnly = 0x0100, // Open only for reading
  181. tomShareDenyRead = 0x0200, // Other programs cannot read
  182. tomShareDenyWrite = 0x0400, // Other programs cannot write
  183. tomPasteFile = 0x1000, // Replace selection with file
  184. tomCreateNew = 0x0010, // Create new if one doesn't exist
  185. tomCreateAlways = 0x0020, // Create new file destroying existing
  186. tomOpenExisting = 0x0030, // Open existing file; else fail
  187. tomOpenAlways = 0x0040, // Open if there, else create new
  188. tomTruncateExisting = 0x0050, // Open existing file, but with 0 length
  189. tomRTF = 0x0001, // Open as RTF
  190. tomText = 0x0002, // Open as text (Ansi or Unicode)
  191. tomHTML = 0x0003, // Open as HTML
  192. tomWordDocument = 0x0004, // Open as Word document
  193. // Attributes
  194. tomBold = 0x80000001,
  195. tomItalic = 0x80000002,
  196. tomUnderline = 0x80000004,
  197. tomStrikeout = 0x80000008,
  198. tomProtected = 0x80000010,
  199. tomLink = 0x80000020,
  200. tomSmallCaps = 0x80000040,
  201. tomAllCaps = 0x80000080,
  202. tomHidden = 0x80000100,
  203. tomOutline = 0x80000200,
  204. tomShadow = 0x80000400,
  205. tomEmboss = 0x80000800,
  206. tomImprint = 0x80001000,
  207. tomDisabled = 0x80002000,
  208. tomRevised = 0x80004000,
  209. // Caret Type
  210. tomNormalCaret = 0x0000, // Default caret
  211. tomKoreanBlockCaret = 0x0001, // Korean block caret
  212. // Client Rect
  213. tomIncludeInset = 0x0001, // include inset (GetClientRect)
  214. // GetPreferredFont Option values
  215. tomIgnoreCurrentFont = 0x0000,
  216. tomMatchFontCharset = 0x0001,
  217. tomMatchFontSignature = 0x0002,
  218. // Special value used in SetLanguageID/GetLanguageID to
  219. // Set/Get font charset and pitch/family
  220. tomCharset = 0x80000000,
  221. // GetFEFlags
  222. tomRE10Mode = 0x0001,
  223. tomUseAtFont = 0x0002,
  224. tomTextFlowMask = 0x000C,
  225. tomTextFlowES = 0x0000,
  226. tomTextFlowSW = 0x0004,
  227. tomTextFlowWN = 0x0008,
  228. tomTextFlowNE = 0x000C,
  229. tomUsePassword = 0x0010,
  230. tomNoIME = 0x00080000,
  231. tomSelfIME = 0x00040000
  232. } tomConstants;
  233. interface ITextDocument;
  234. interface ITextRange;
  235. interface ITextSelection;
  236. interface ITextFont;
  237. interface ITextPara;
  238. interface ITextStoryRanges;
  239. interface ITextDocument2;
  240. interface ITextMsgFilter;
  241. }
  242. [odl, uuid(8CC497C0-A1DF-11ce-8098-00AA0047BE5D), version(1.0), dual, nonextensible]
  243. interface ITextDocument : IDispatch
  244. {
  245. // Properties
  246. [id(0), propget] HRESULT Name ([out, retval] BSTR *pName);
  247. [id(1), propget] HRESULT Selection ([out, retval] ITextSelection **ppSel);
  248. [id(2), propget] HRESULT StoryCount ([out, retval] long *pCount);
  249. [id(3), propget] HRESULT StoryRanges ([out, retval] ITextStoryRanges **ppStories);
  250. [id(4), propget] HRESULT Saved ([out, retval] long *pValue);
  251. [id(4), propput] HRESULT Saved ([in] long Value);
  252. [id(5), propget] HRESULT DefaultTabStop ([out, retval] float *pValue);
  253. [id(5), propput] HRESULT DefaultTabStop ([in] float Value);
  254. // Methods
  255. [id(6)] HRESULT New ();
  256. [id(7)] HRESULT Open ([in] VARIANT *pVar, [in] long Flags, [in] long CodePage);
  257. [id(8)] HRESULT Save ([in] VARIANT *pVar, [in] long Flags, [in] long CodePage);
  258. [id(9)] HRESULT Freeze ([out, retval] long *pCount);
  259. [id(10)] HRESULT Unfreeze ([out, retval] long *pCount);
  260. [id(11)] HRESULT BeginEditCollection ();
  261. [id(12)] HRESULT EndEditCollection ();
  262. [id(13)] HRESULT Undo ([in] long Count, [out, retval] long *prop);
  263. [id(14)] HRESULT Redo ([in] long Count, [out, retval] long *prop);
  264. [id(15)] HRESULT Range ([in] long cp1, [in] long cp2, [out, retval] ITextRange **ppRange);
  265. [id(16)] HRESULT RangeFromPoint ([in] long x, [in] long y,
  266. [out, retval] ITextRange **ppRange);
  267. }
  268. [odl, uuid(8CC497C2-A1DF-11ce-8098-00AA0047BE5D), version(1.0), dual, nonextensible]
  269. interface ITextRange : IDispatch // Start and limit end positions
  270. {
  271. // Range Properties
  272. [id( 0), propget] HRESULT Text ([out,retval] BSTR *pbstr);
  273. [id( 0), propput] HRESULT Text ([in] BSTR bstr);
  274. [id(0x201), propget] HRESULT Char ([out, retval] long *pch);
  275. [id(0x201), propput] HRESULT Char ([in] long ch);
  276. [id(0x202), propget] HRESULT Duplicate ([out, retval] ITextRange **ppRange);
  277. [id(0x203), propget] HRESULT FormattedText ([out, retval] ITextRange **ppRange);
  278. [id(0x203), propput] HRESULT FormattedText ([in] ITextRange *pRange);
  279. [id(0x204), propget] HRESULT Start ([out, retval] long *pcpFirst);
  280. [id(0x204), propput] HRESULT Start ([in] long cpFirst);
  281. [id(0x205), propget] HRESULT End ([out, retval] long *pcpLim);
  282. [id(0x205), propput] HRESULT End ([in] long cpLim);
  283. [id(0x206), propget] HRESULT Font ([out, retval] ITextFont **pFont);
  284. [id(0x206), propput] HRESULT Font ([in] ITextFont *pFont);
  285. [id(0x207), propget] HRESULT Para ([out, retval] ITextPara **pPara);
  286. [id(0x207), propput] HRESULT Para ([in] ITextPara *pPara);
  287. [id(0x208), propget] HRESULT StoryLength ([out, retval] long *pcch);
  288. [id(0x209), propget] HRESULT StoryType ([out, retval] long *pValue);
  289. // Range Methods
  290. [id(0x210)] HRESULT Collapse ([in] long bStart);
  291. [id(0x211)] HRESULT Expand ([in] long Unit, [out, retval] long *pDelta);
  292. [id(0x212)] HRESULT GetIndex ([in] long Unit, [out, retval] long *pIndex);
  293. [id(0x213)] HRESULT SetIndex ([in] long Unit, [in] long Index, [in] long Extend);
  294. [id(0x214)] HRESULT SetRange ([in] long cpActive, [in] long cpOther);
  295. [id(0x215)] HRESULT InRange ([in] ITextRange *pRange, [out, retval] long *pb);
  296. [id(0x216)] HRESULT InStory ([in] ITextRange *pRange, [out, retval] long *pb);
  297. [id(0x217)] HRESULT IsEqual ([in] ITextRange *pRange, [out, retval] long *pb);
  298. [id(0x218)] HRESULT Select ();
  299. [id(0x219)] HRESULT StartOf ([in] long Unit, [in] long Extend,
  300. [out, retval] long *pDelta);
  301. [id(0x220)] HRESULT EndOf ([in] long Unit, [in] long Extend,
  302. [out, retval] long *pDelta);
  303. [id(0x221)] HRESULT Move ([in] long Unit,
  304. [in] long Count, [out, retval] long *pDelta);
  305. [id(0x222)] HRESULT MoveStart ([in] long Unit,
  306. [in] long Count, [out, retval] long *pDelta);
  307. [id(0x223)] HRESULT MoveEnd ([in] long Unit,
  308. [in] long Count, [out, retval] long *pDelta);
  309. [id(0x224)] HRESULT MoveWhile ([in] VARIANT *Cset,
  310. [in] long Count, [out, retval] long *pDelta);
  311. [id(0x225)] HRESULT MoveStartWhile ([in] VARIANT *Cset,
  312. [in] long Count, [out, retval] long *pDelta);
  313. [id(0x226)] HRESULT MoveEndWhile ([in] VARIANT *Cset,
  314. [in] long Count, [out, retval] long *pDelta);
  315. [id(0x227)] HRESULT MoveUntil ([in] VARIANT *Cset,
  316. [in] long Count, [out, retval] long *pDelta);
  317. [id(0x228)] HRESULT MoveStartUntil ([in] VARIANT *Cset,
  318. [in] long Count, [out, retval] long *pDelta);
  319. [id(0x229)] HRESULT MoveEndUntil ([in] VARIANT *Cset,
  320. [in] long Count, [out, retval] long *pDelta);
  321. [id(0x230)] HRESULT FindText ( [in] BSTR bstr, [in] long cch,
  322. [in] long Flags, [out, retval] long *pLength);
  323. [id(0x231)] HRESULT FindTextStart ( [in] BSTR bstr, [in] long cch,
  324. [in] long Flags, [out, retval] long *pLength);
  325. [id(0x232)] HRESULT FindTextEnd ( [in] BSTR bstr, [in] long cch,
  326. [in] long Flags, [out, retval] long *pLength);
  327. [id(0x233)] HRESULT Delete ([in] long Unit, [in] long Count,
  328. [out, retval] long *pDelta);
  329. [id(0x234)] HRESULT Cut ([out] VARIANT *pVar);
  330. [id(0x235)] HRESULT Copy ([out] VARIANT *pVar);
  331. [id(0x236)] HRESULT Paste ([in] VARIANT *pVar, [in] long Format);
  332. [id(0x237)] HRESULT CanPaste ([in] VARIANT *pVar, [in] long Format,
  333. [out, retval] long *pb);
  334. [id(0x238)] HRESULT CanEdit ([out, retval] long *pbCanEdit);
  335. [id(0x239)] HRESULT ChangeCase ([in] long Type);
  336. [id(0x240)] HRESULT GetPoint ([in] long Type, [out] long *px, [out] long *py);
  337. [id(0x241)] HRESULT SetPoint ([in] long x, [in] long y, [in] long Type, [in] long Extend);
  338. [id(0x242)] HRESULT ScrollIntoView ([in] long Value);
  339. [id(0x243)] HRESULT GetEmbeddedObject ([out, retval] IUnknown **ppv);
  340. }
  341. [odl, uuid(8CC497C1-A1DF-11ce-8098-00AA0047BE5D), version(1.0), dual, nonextensible]
  342. interface ITextSelection : ITextRange
  343. {
  344. [id(0x101), propget] HRESULT Flags ([out,retval] long *pFlags);
  345. [id(0x101), propput] HRESULT Flags ([in] LONG Flags);
  346. [id(0x102), propget] HRESULT Type ([out, retval] long *pType);
  347. [id(0x103)] HRESULT MoveLeft([in] long Unit, [in] long Count, [in] long Extend,
  348. [out, retval] long *pDelta);
  349. [id(0x104)] HRESULT MoveRight([in] long Unit, [in] long Count, [in] long Extend,
  350. [out, retval] long *pDelta);
  351. [id(0x105)] HRESULT MoveUp ([in] long Unit, [in] long Count, [in] long Extend,
  352. [out, retval] long *pDelta);
  353. [id(0x106)] HRESULT MoveDown([in] long Unit, [in] long Count, [in] long Extend,
  354. [out, retval] long *pDelta);
  355. [id(0x107)] HRESULT HomeKey ([in] long Unit, [in] long Extend,
  356. [out, retval] long *pDelta);
  357. [id(0x108)] HRESULT EndKey ([in] long Unit, [in] long Extend,
  358. [out, retval] long *pDelta);
  359. [id(0x109)] HRESULT TypeText ([in] BSTR bstr);
  360. }
  361. [odl, uuid(8CC497C3-A1DF-11ce-8098-00AA0047BE5D), version(1.0), dual, nonextensible]
  362. interface ITextFont : IDispatch
  363. {
  364. // Common format properties and methods
  365. [id( 0), propget] HRESULT Duplicate ([out, retval] ITextFont **ppFont);
  366. [id( 0), propput] HRESULT Duplicate ([in] ITextFont *pFont);
  367. [id(0x301)] HRESULT CanChange ([out, retval] long *pB);
  368. [id(0x302)] HRESULT IsEqual ([in] ITextFont *pFont, [out, retval] long *pB);
  369. [id(0x303)] HRESULT Reset ([in] long Value);
  370. [id(0x304), propget] HRESULT Style ([out, retval] long *pValue);
  371. [id(0x304), propput] HRESULT Style ([in] long Value);
  372. // Character format properties and methods
  373. [id(0x305), propget] HRESULT AllCaps ([out, retval] long *pValue);
  374. [id(0x305), propput] HRESULT AllCaps ([in] long Value);
  375. [id(0x306), propget] HRESULT Animation ([out, retval] long *pValue);
  376. [id(0x306), propput] HRESULT Animation ([in] long Value);
  377. [id(0x307), propget] HRESULT BackColor ([out, retval] long *pValue);
  378. [id(0x307), propput] HRESULT BackColor ([in] long Value);
  379. [id(0x308), propget] HRESULT Bold ([out, retval] long *pValue);
  380. [id(0x308), propput] HRESULT Bold ([in] long Value);
  381. [id(0x309), propget] HRESULT Emboss ([out, retval] long *pValue);
  382. [id(0x309), propput] HRESULT Emboss ([in] long Value);
  383. [id(0x310), propget] HRESULT ForeColor ([out, retval] long *pValue);
  384. [id(0x310), propput] HRESULT ForeColor ([in] long Value);
  385. [id(0x311), propget] HRESULT Hidden ([out, retval] long *pValue);
  386. [id(0x311), propput] HRESULT Hidden ([in] long Value);
  387. [id(0x312), propget] HRESULT Engrave ([out, retval] long *pValue);
  388. [id(0x312), propput] HRESULT Engrave ([in] long Value);
  389. [id(0x313), propget] HRESULT Italic ([out, retval] long *pValue);
  390. [id(0x313), propput] HRESULT Italic ([in] long Value);
  391. [id(0x314), propget] HRESULT Kerning ([out, retval] float *pValue);
  392. [id(0x314), propput] HRESULT Kerning ([in] float Value);
  393. [id(0x315), propget] HRESULT LanguageID ([out, retval] long *pValue);
  394. [id(0x315), propput] HRESULT LanguageID ([in] long Value);
  395. [id(0x316), propget] HRESULT Name ([out, retval] BSTR *pbstr);
  396. [id(0x316), propput] HRESULT Name ([in] BSTR bstr);
  397. [id(0x317), propget] HRESULT Outline ([out, retval] long *pValue);
  398. [id(0x317), propput] HRESULT Outline ([in] long Value);
  399. [id(0x318), propget] HRESULT Position ([out, retval] float *pValue);
  400. [id(0x318), propput] HRESULT Position ([in] float Value);
  401. [id(0x319), propget] HRESULT Protected ([out, retval] long *pValue);
  402. [id(0x319), propput] HRESULT Protected ([in] long Value);
  403. [id(0x320), propget] HRESULT Shadow ([out, retval] long *pValue);
  404. [id(0x320), propput] HRESULT Shadow ([in] long Value);
  405. [id(0x321), propget] HRESULT Size ([out, retval] float *pValue);
  406. [id(0x321), propput] HRESULT Size ([in] float Value);
  407. [id(0x322), propget] HRESULT SmallCaps ([out, retval] long *pValue);
  408. [id(0x322), propput] HRESULT SmallCaps ([in] long Value);
  409. [id(0x323), propget] HRESULT Spacing ([out, retval] float *pValue);
  410. [id(0x323), propput] HRESULT Spacing ([in] float Value);
  411. [id(0x324), propget] HRESULT StrikeThrough ([out, retval] long *pValue);
  412. [id(0x324), propput] HRESULT StrikeThrough ([in] long Value);
  413. [id(0x325), propget] HRESULT Subscript ([out, retval] long *pValue);
  414. [id(0x325), propput] HRESULT Subscript ([in] long Value);
  415. [id(0x326), propget] HRESULT Superscript ([out, retval] long *pValue);
  416. [id(0x326), propput] HRESULT Superscript ([in] long Value);
  417. [id(0x327), propget] HRESULT Underline ([out, retval] long *pValue);
  418. [id(0x327), propput] HRESULT Underline ([in] long Value);
  419. [id(0x328), propget] HRESULT Weight ([out, retval] long *pValue);
  420. [id(0x328), propput] HRESULT Weight ([in] long Value);
  421. }
  422. [odl, uuid(8CC497C4-A1DF-11ce-8098-00AA0047BE5D), version(1.0), dual, nonextensible]
  423. interface ITextPara : IDispatch
  424. {
  425. // Common format properties and methods
  426. [id( 0), propget] HRESULT Duplicate ([out, retval] ITextPara **ppPara);
  427. [id( 0), propput] HRESULT Duplicate ([in] ITextPara *pPara);
  428. [id(0x401)] HRESULT CanChange ([out, retval] long *pB);
  429. [id(0x402)] HRESULT IsEqual ([in] ITextPara *pPara, [out, retval] long *pB);
  430. [id(0x403)] HRESULT Reset ([in] long Value);
  431. [id(0x404), propget] HRESULT Style ([out, retval] long *pValue);
  432. [id(0x404), propput] HRESULT Style ([in] long Value);
  433. // Paragraph format properties and methods
  434. [id(0x405), propget] HRESULT Alignment ([out,retval] long *pValue);
  435. [id(0x405), propput] HRESULT Alignment ([in] long Value);
  436. [id(0x406), propget] HRESULT Hyphenation ([out, retval] long *pValue);
  437. [id(0x406), propput] HRESULT Hyphenation ([in] long Value);
  438. [id(0x407), propget] HRESULT FirstLineIndent ([out, retval] float *pValue);
  439. [id(0x408), propget] HRESULT KeepTogether ([out, retval] long *pValue);
  440. [id(0x408), propput] HRESULT KeepTogether ([in] long Value);
  441. [id(0x409), propget] HRESULT KeepWithNext ([out, retval] long *pValue);
  442. [id(0x409), propput] HRESULT KeepWithNext ([in] long Value);
  443. [id(0x410), propget] HRESULT LeftIndent ([out, retval] float *pValue);
  444. [id(0x411), propget] HRESULT LineSpacing ([out, retval] float *pValue);
  445. [id(0x412), propget] HRESULT LineSpacingRule ([out, retval] long *pValue);
  446. [id(0x413), propget] HRESULT ListAlignment ([out, retval] long *pValue);
  447. [id(0x413), propput] HRESULT ListAlignment ([in] long Value);
  448. [id(0x414), propget] HRESULT ListLevelIndex ([out, retval] long *pValue);
  449. [id(0x414), propput] HRESULT ListLevelIndex ([in] long Value);
  450. [id(0x415), propget] HRESULT ListStart ([out, retval] long *pValue);
  451. [id(0x415), propput] HRESULT ListStart ([in] long Value);
  452. [id(0x416), propget] HRESULT ListTab ([out, retval] float *pValue);
  453. [id(0x416), propput] HRESULT ListTab ([in] float Value);
  454. [id(0x417), propget] HRESULT ListType ([out, retval] long *pValue);
  455. [id(0x417), propput] HRESULT ListType ([in] long Value);
  456. [id(0x418), propget] HRESULT NoLineNumber ([out, retval] long *pValue);
  457. [id(0x418), propput] HRESULT NoLineNumber ([in] long Value);
  458. [id(0x419), propget] HRESULT PageBreakBefore ([out, retval] long *pValue);
  459. [id(0x419), propput] HRESULT PageBreakBefore ([in] long Value);
  460. [id(0x420), propget] HRESULT RightIndent ([out, retval] float *pValue);
  461. [id(0x420), propput] HRESULT RightIndent ([in] float Value);
  462. [id(0x421)] HRESULT SetIndents ([in] float StartIndent,
  463. [in] float LeftIndent, [in] float RightIndent);
  464. [id(0x422)] HRESULT SetLineSpacing ([in] long LineSpacingRule,
  465. [in] float LineSpacing);
  466. [id(0x423), propget] HRESULT SpaceAfter ([out, retval] float *pValue);
  467. [id(0x423), propput] HRESULT SpaceAfter ([in] float Value);
  468. [id(0x424), propget] HRESULT SpaceBefore ([out, retval] float *pValue);
  469. [id(0x424), propput] HRESULT SpaceBefore ([in] float Value);
  470. [id(0x425), propget] HRESULT WidowControl ([out, retval] long *pValue);
  471. [id(0x425), propput] HRESULT WidowControl ([in] long Value);
  472. // Tab methods and property
  473. [id(0x426), propget] HRESULT TabCount ([out, retval] long *pCount);
  474. [id(0x427)] HRESULT AddTab ([in] float tbPos, [in] long tbAlign,
  475. [in] long tbLeader);
  476. [id(0x428)] HRESULT ClearAllTabs ();
  477. [id(0x429)] HRESULT DeleteTab ([in] float tbPos);
  478. [id(0x430)] HRESULT GetTab ([in] long iTab, [out] float *ptbPos,
  479. [out] long *ptbAlign, [out] long *ptbLeader);
  480. }
  481. [odl, uuid(8CC497C5-A1DF-11ce-8098-00AA0047BE5D), version(1.0), dual, nonextensible]
  482. interface ITextStoryRanges : IDispatch
  483. {
  484. [id(-4), restricted] HRESULT _NewEnum ([out, retval] IUnknown **ppunkEnum);
  485. [id(0)] HRESULT Item ([in] long Index, [out, retval] ITextRange **ppRange);
  486. [id(2), propget] HRESULT Count ([out, retval] long *pCount);
  487. }
  488. [uuid(01c25500-4268-11d1-883a-3c8b00c10000), version(1.0), dual, nonextensible]
  489. interface ITextDocument2 : ITextDocument
  490. {
  491. [id(21), helpstring("method AttachMsgFilter")]
  492. HRESULT AttachMsgFilter([in] IUnknown *pFilter);
  493. [id(22), helpstring("method SetEffectColor")]
  494. HRESULT SetEffectColor([in] long Index, [in] COLORREF cr);
  495. [id(23), helpstring("method GetEffectColor")]
  496. HRESULT GetEffectColor([in] long Index, [out] COLORREF *pcr);
  497. [id(24), propget, helpstring("method GetCaretType")]
  498. HRESULT CaretType ([out, retval] long *pCaretType);
  499. [id(24), propput, helpstring("method SetCaretType")]
  500. HRESULT CaretType ([in] long CaretType);
  501. [id(25), helpstring("method GetImmContext")]
  502. HRESULT GetImmContext([out, retval] long *pContext);
  503. [id(26), helpstring("method ReleaseImmContext")]
  504. HRESULT ReleaseImmContext([in] long Context);
  505. [id(27), helpstring("method GetPreferredFont")]
  506. HRESULT GetPreferredFont([in] long cp, [in] long CodePage, [in] long Option,
  507. [in] long curCodepage, [in] long curFontSize, [out] BSTR *pbstr,
  508. [out] long *pPitchAndFamily, [out] long *pNewFontSize );
  509. [id(28), propget, helpstring("method GetNotificationMode")]
  510. HRESULT NotificationMode([out, retval] long *pMode);
  511. [id(28), propput, helpstring("method SetNotificationMode")]
  512. HRESULT NotificationMode([in] long Mode);
  513. [id(29), helpstring("method GetClientRect")]
  514. HRESULT GetClientRect([in] long Type,
  515. [out] long *pLeft,
  516. [out] long *pTop,
  517. [out] long *pRight,
  518. [out] long *pBottom);
  519. [id(30), propget, helpstring("method GetSelectionEx")]
  520. HRESULT SelectionEx([out, retval] ITextSelection **ppSel);
  521. [id(31), helpstring("method GetWindow")]
  522. HRESULT GetWindow([out] long *phWnd);
  523. [id(32), helpstring("method GetFEFlags")]
  524. HRESULT GetFEFlags([out] long *pFlags);
  525. [id(33), helpstring("method UpdateWindow")]
  526. HRESULT UpdateWindow(void);
  527. [id(34), helpstring("method CheckTextLimit")]
  528. HRESULT CheckTextLimit(long cch, long *pcch);
  529. [id(35), helpstring("method IMEInProgress")]
  530. HRESULT IMEInProgress(long Mode);
  531. [id(36), helpstring("method SysBeep")]
  532. HRESULT SysBeep(void);
  533. [id(37), helpstring("method Update")]
  534. HRESULT Update([in] long Mode);
  535. [id(38), helpstring("method Notify")]
  536. HRESULT Notify([in] long Notify);
  537. [id(39), helpstring("method GetDocumentFont")]
  538. HRESULT GetDocumentFont([out, retval] ITextFont **ppITextFont);
  539. [id(40), helpstring("method GetDocumentPara")]
  540. HRESULT GetDocumentPara([out, retval] ITextPara **ppITextPara);
  541. [id(41), helpstring("method GetCallManager")]
  542. HRESULT GetCallManager([out, retval] IUnknown **ppVoid);
  543. [id(42), helpstring("method ReleaseCallManager")]
  544. HRESULT ReleaseCallManager(IUnknown *pVoid);
  545. }
  546. [uuid(a3787420-4267-11d1-883a-3c8b00c10000), version(1.0),nonextensible]
  547. interface ITextMsgFilter : IUnknown
  548. {
  549. [id(1), helpstring("method AttachDocument")]
  550. HRESULT AttachDocument([in] HWND hwnd, [in] ITextDocument2 *pTextDoc, [in] IUnknown *punk);
  551. [id(2), helpstring("method HandleMessage")]
  552. HRESULT HandleMessage([in,out] UINT *pmsg, [in,out] WPARAM *pwparam, [in,out] LPARAM *plparam, [out] LRESULT *plres);
  553. [id(3), helpstring("method AttachMsgFilter")]
  554. HRESULT AttachMsgFilter([in] ITextMsgFilter *pMsgFilter);
  555. }