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.

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