/*** Autogenerated by WIDL 5.11 from ../../wine/include/tom.idl - Do not edit ***/

#ifdef _WIN32
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 475
#endif
#include <rpc.h>
#include <rpcndr.h>
#endif

#ifndef COM_NO_WINDOWS_H
#include <windows.h>
#include <ole2.h>
#endif

#ifndef __tom_h__
#define __tom_h__

/* Forward declarations */

#ifndef __ITextDocument_FWD_DEFINED__
#define __ITextDocument_FWD_DEFINED__
typedef interface ITextDocument ITextDocument;
#ifdef __cplusplus
interface ITextDocument;
#endif /* __cplusplus */
#endif

#ifndef __ITextDocument2Old_FWD_DEFINED__
#define __ITextDocument2Old_FWD_DEFINED__
typedef interface ITextDocument2Old ITextDocument2Old;
#ifdef __cplusplus
interface ITextDocument2Old;
#endif /* __cplusplus */
#endif

#ifndef __ITextDocument2_FWD_DEFINED__
#define __ITextDocument2_FWD_DEFINED__
typedef interface ITextDocument2 ITextDocument2;
#ifdef __cplusplus
interface ITextDocument2;
#endif /* __cplusplus */
#endif

#ifndef __ITextRange_FWD_DEFINED__
#define __ITextRange_FWD_DEFINED__
typedef interface ITextRange ITextRange;
#ifdef __cplusplus
interface ITextRange;
#endif /* __cplusplus */
#endif

#ifndef __ITextSelection_FWD_DEFINED__
#define __ITextSelection_FWD_DEFINED__
typedef interface ITextSelection ITextSelection;
#ifdef __cplusplus
interface ITextSelection;
#endif /* __cplusplus */
#endif

#ifndef __ITextFont_FWD_DEFINED__
#define __ITextFont_FWD_DEFINED__
typedef interface ITextFont ITextFont;
#ifdef __cplusplus
interface ITextFont;
#endif /* __cplusplus */
#endif

#ifndef __ITextPara_FWD_DEFINED__
#define __ITextPara_FWD_DEFINED__
typedef interface ITextPara ITextPara;
#ifdef __cplusplus
interface ITextPara;
#endif /* __cplusplus */
#endif

#ifndef __ITextStoryRanges_FWD_DEFINED__
#define __ITextStoryRanges_FWD_DEFINED__
typedef interface ITextStoryRanges ITextStoryRanges;
#ifdef __cplusplus
interface ITextStoryRanges;
#endif /* __cplusplus */
#endif

/* Headers for imported files */

#include <oaidl.h>
#include <ocidl.h>

#ifdef __cplusplus
extern "C" {
#endif

#ifdef WINE_NO_UNICODE_MACROS
#undef FindText
#endif
typedef enum tagTomConstants {
    tomFalse = (int)0,
    tomTrue = (int)-1,
    tomUndefined = (int)-9999999,
    tomToggle = (int)-9999998,
    tomAutoColor = (int)-9999997,
    tomDefault = (int)-9999996,
    tomSuspend = (int)-9999995,
    tomResume = (int)-9999994,
    tomApplyNow = (int)0,
    tomApplyLater = (int)1,
    tomTrackParms = (int)2,
    tomCacheParms = (int)3,
    tomApplyTmp = (int)4,
    tomDisableSmartFont = (int)8,
    tomEnableSmartFont = (int)9,
    tomUsePoints = (int)10,
    tomUseTwips = (int)11,
    tomBackward = (int)0xc0000001,
    tomForward = (int)0x3fffffff,
    tomMove = (int)0,
    tomExtend = (int)1,
    tomNoSelection = (int)0,
    tomSelectionIP = (int)1,
    tomSelectionNormal = (int)2,
    tomSelectionFrame = (int)3,
    tomSelectionColumn = (int)4,
    tomSelectionRow = (int)5,
    tomSelectionBlock = (int)6,
    tomSelectionInlineShape = (int)7,
    tomSelectionShape = (int)8,
    tomSelStartActive = (int)1,
    tomSelAtEOL = (int)2,
    tomSelOvertype = (int)4,
    tomSelActive = (int)8,
    tomSelReplace = (int)16,
    tomEnd = (int)0,
    tomStart = (int)32,
    tomCollapseEnd = (int)0,
    tomCollapseStart = (int)1,
    tomClientCoord = (int)256,
    tomNone = (int)0,
    tomSingle = (int)1,
    tomWords = (int)2,
    tomDouble = (int)3,
    tomDotted = (int)4,
    tomDash = (int)5,
    tomDashDot = (int)6,
    tomDashDotDot = (int)7,
    tomWave = (int)8,
    tomThick = (int)9,
    tomHair = (int)10,
    tomLineSpaceSingle = (int)0,
    tomLineSpace1pt5 = (int)1,
    tomLineSpaceDouble = (int)2,
    tomLineSpaceAtLeast = (int)3,
    tomLineSpaceExactly = (int)4,
    tomLineSpaceMultiple = (int)5,
    tomAlignLeft = (int)0,
    tomAlignCenter = (int)1,
    tomAlignRight = (int)2,
    tomAlignJustify = (int)3,
    tomAlignDecimal = (int)3,
    tomAlignBar = (int)4,
    tomAlignInterWord = (int)3,
    tomAlignInterLetter = (int)4,
    tomAlignScaled = (int)5,
    tomAlignGlyphs = (int)6,
    tomAlignSnapGrid = (int)7,
    tomSpaces = (int)0,
    tomDots = (int)1,
    tomDashes = (int)2,
    tomLines = (int)3,
    tomThickLines = (int)4,
    tomEquals = (int)5,
    tomTabBack = (int)-3,
    tomTabNext = (int)-2,
    tomTabHere = (int)-1,
    tomListBullet = (int)1,
    tomListNumberAsArabic = (int)2,
    tomListNumberAsLCLetter = (int)3,
    tomListNumberAsUCLetter = (int)4,
    tomListNumberAsLCRoman = (int)5,
    tomListNumberAsUCRoman = (int)6,
    tomListNumberAsSequence = (int)7,
    tomListParentheses = (int)0x10000,
    tomListPeriod = (int)0x20000,
    tomListPlain = (int)0x30000,
    tomCharacter = (int)1,
    tomWord = (int)2,
    tomSentence = (int)3,
    tomParagraph = (int)4,
    tomLine = (int)5,
    tomStory = (int)6,
    tomScreen = (int)7,
    tomSection = (int)8,
    tomColumn = (int)9,
    tomRow = (int)10,
    tomWindow = (int)11,
    tomCell = (int)12,
    tomCharFormat = (int)13,
    tomParaFormat = (int)14,
    tomTable = (int)15,
    tomObject = (int)16,
    tomMatchWord = (int)2,
    tomMatchCase = (int)4,
    tomMatchPattern = (int)8,
    tomUnknownStory = (int)0,
    tomMainTextStory = (int)1,
    tomFootnotesStory = (int)2,
    tomEndnotesStory = (int)3,
    tomCommentsStory = (int)4,
    tomTextFrameStory = (int)5,
    tomEvenPagesHeaderStory = (int)6,
    tomPrimaryHeaderStory = (int)7,
    tomEvenPagesFooterStory = (int)8,
    tomPrimaryFooterStory = (int)9,
    tomFirstPageHeaderStory = (int)10,
    tomFirstPageFooterStory = (int)11,
    tomNoAnimation = (int)0,
    tomLasVegasLights = (int)1,
    tomBlinkingBackground = (int)2,
    tomSparkleText = (int)3,
    tomMarchingBlackAnts = (int)4,
    tomMarchingRedAnts = (int)5,
    tomShimmer = (int)6,
    tomWipeDown = (int)7,
    tomWipeRight = (int)8,
    tomAnimationMax = (int)8,
    tomLowerCase = (int)0,
    tomUpperCase = (int)1,
    tomTitleCase = (int)2,
    tomSentenceCase = (int)4,
    tomToggleCase = (int)5,
    tomReadOnly = (int)0x100,
    tomShareDenyRead = (int)0x200,
    tomShareDenyWrite = (int)0x400,
    tomPasteFile = (int)0x1000,
    tomCreateNew = (int)0x10,
    tomCreateAlways = (int)0x20,
    tomOpenExisting = (int)0x30,
    tomOpenAlways = (int)0x40,
    tomTruncateExisting = (int)0x50,
    tomRTF = (int)0x1,
    tomText = (int)0x2,
    tomHTML = (int)0x3,
    tomWordDocument = (int)0x4,
    tomBold = (int)0x80000001,
    tomItalic = (int)0x80000002,
    tomUnderline = (int)0x80000004,
    tomStrikeout = (int)0x80000008,
    tomProtected = (int)0x80000010,
    tomLink = (int)0x80000020,
    tomSmallCaps = (int)0x80000040,
    tomAllCaps = (int)0x80000080,
    tomHidden = (int)0x80000100,
    tomOutline = (int)0x80000200,
    tomShadow = (int)0x80000400,
    tomEmboss = (int)0x80000800,
    tomImprint = (int)0x80001000,
    tomDisabled = (int)0x80002000,
    tomRevised = (int)0x80004000,
    tomNormalCaret = (int)0,
    tomKoreanBlockCaret = (int)0x1,
    tomIncludeInset = (int)0x1,
    tomIgnoreCurrentFont = (int)0,
    tomMatchFontCharset = (int)0x1,
    tomMatchFontSignature = (int)0x2,
    tomCharset = (int)0x80000000,
    tomRE10Mode = (int)0x1,
    tomNoIME = (int)0x80000,
    tomSelfIME = (int)0x40000
} tomConstants;
#ifndef __ITextRange_FWD_DEFINED__
#define __ITextRange_FWD_DEFINED__
typedef interface ITextRange ITextRange;
#ifdef __cplusplus
interface ITextRange;
#endif /* __cplusplus */
#endif

#ifndef __ITextSelection_FWD_DEFINED__
#define __ITextSelection_FWD_DEFINED__
typedef interface ITextSelection ITextSelection;
#ifdef __cplusplus
interface ITextSelection;
#endif /* __cplusplus */
#endif

#ifndef __ITextStoryRanges_FWD_DEFINED__
#define __ITextStoryRanges_FWD_DEFINED__
typedef interface ITextStoryRanges ITextStoryRanges;
#ifdef __cplusplus
interface ITextStoryRanges;
#endif /* __cplusplus */
#endif

/*****************************************************************************
 * ITextDocument interface
 */
#ifndef __ITextDocument_INTERFACE_DEFINED__
#define __ITextDocument_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextDocument, 0x8cc497c0, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("8cc497c0-a1df-11ce-8098-00aa0047be5d")
ITextDocument : public IDispatch
{
    virtual HRESULT STDMETHODCALLTYPE GetName(
        BSTR *pName) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSelection(
        ITextSelection **ppSel) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStoryCount(
        LONG *pCount) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStoryRanges(
        ITextStoryRanges **ppStories) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSaved(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSaved(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetDefaultTabStop(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetDefaultTabStop(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE New(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE Open(
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage) = 0;

    virtual HRESULT STDMETHODCALLTYPE Save(
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage) = 0;

    virtual HRESULT STDMETHODCALLTYPE Freeze(
        LONG *pCount) = 0;

    virtual HRESULT STDMETHODCALLTYPE Unfreeze(
        LONG *pCount) = 0;

    virtual HRESULT STDMETHODCALLTYPE BeginEditCollection(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE EndEditCollection(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE Undo(
        LONG Count,
        LONG *prop) = 0;

    virtual HRESULT STDMETHODCALLTYPE Redo(
        LONG Count,
        LONG *prop) = 0;

    virtual HRESULT STDMETHODCALLTYPE Range(
        LONG cp1,
        LONG cp2,
        ITextRange **ppRange) = 0;

    virtual HRESULT STDMETHODCALLTYPE RangeFromPoint(
        LONG x,
        LONG y,
        ITextRange **ppRange) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextDocument, 0x8cc497c0, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d)
#endif
#else
typedef struct ITextDocumentVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextDocument *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextDocument *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextDocument *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextDocument *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextDocument *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextDocument *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextDocument *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextDocument methods ***/
    HRESULT (STDMETHODCALLTYPE *GetName)(
        ITextDocument *This,
        BSTR *pName);

    HRESULT (STDMETHODCALLTYPE *GetSelection)(
        ITextDocument *This,
        ITextSelection **ppSel);

    HRESULT (STDMETHODCALLTYPE *GetStoryCount)(
        ITextDocument *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *GetStoryRanges)(
        ITextDocument *This,
        ITextStoryRanges **ppStories);

    HRESULT (STDMETHODCALLTYPE *GetSaved)(
        ITextDocument *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSaved)(
        ITextDocument *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetDefaultTabStop)(
        ITextDocument *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetDefaultTabStop)(
        ITextDocument *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *New)(
        ITextDocument *This);

    HRESULT (STDMETHODCALLTYPE *Open)(
        ITextDocument *This,
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage);

    HRESULT (STDMETHODCALLTYPE *Save)(
        ITextDocument *This,
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage);

    HRESULT (STDMETHODCALLTYPE *Freeze)(
        ITextDocument *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *Unfreeze)(
        ITextDocument *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *BeginEditCollection)(
        ITextDocument *This);

    HRESULT (STDMETHODCALLTYPE *EndEditCollection)(
        ITextDocument *This);

    HRESULT (STDMETHODCALLTYPE *Undo)(
        ITextDocument *This,
        LONG Count,
        LONG *prop);

    HRESULT (STDMETHODCALLTYPE *Redo)(
        ITextDocument *This,
        LONG Count,
        LONG *prop);

    HRESULT (STDMETHODCALLTYPE *Range)(
        ITextDocument *This,
        LONG cp1,
        LONG cp2,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *RangeFromPoint)(
        ITextDocument *This,
        LONG x,
        LONG y,
        ITextRange **ppRange);

    END_INTERFACE
} ITextDocumentVtbl;

interface ITextDocument {
    CONST_VTBL ITextDocumentVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextDocument_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextDocument_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextDocument_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextDocument_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextDocument_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextDocument_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextDocument_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextDocument methods ***/
#define ITextDocument_GetName(This,pName) (This)->lpVtbl->GetName(This,pName)
#define ITextDocument_GetSelection(This,ppSel) (This)->lpVtbl->GetSelection(This,ppSel)
#define ITextDocument_GetStoryCount(This,pCount) (This)->lpVtbl->GetStoryCount(This,pCount)
#define ITextDocument_GetStoryRanges(This,ppStories) (This)->lpVtbl->GetStoryRanges(This,ppStories)
#define ITextDocument_GetSaved(This,pValue) (This)->lpVtbl->GetSaved(This,pValue)
#define ITextDocument_SetSaved(This,Value) (This)->lpVtbl->SetSaved(This,Value)
#define ITextDocument_GetDefaultTabStop(This,pValue) (This)->lpVtbl->GetDefaultTabStop(This,pValue)
#define ITextDocument_SetDefaultTabStop(This,Value) (This)->lpVtbl->SetDefaultTabStop(This,Value)
#define ITextDocument_New(This) (This)->lpVtbl->New(This)
#define ITextDocument_Open(This,pVar,Flags,CodePage) (This)->lpVtbl->Open(This,pVar,Flags,CodePage)
#define ITextDocument_Save(This,pVar,Flags,CodePage) (This)->lpVtbl->Save(This,pVar,Flags,CodePage)
#define ITextDocument_Freeze(This,pCount) (This)->lpVtbl->Freeze(This,pCount)
#define ITextDocument_Unfreeze(This,pCount) (This)->lpVtbl->Unfreeze(This,pCount)
#define ITextDocument_BeginEditCollection(This) (This)->lpVtbl->BeginEditCollection(This)
#define ITextDocument_EndEditCollection(This) (This)->lpVtbl->EndEditCollection(This)
#define ITextDocument_Undo(This,Count,prop) (This)->lpVtbl->Undo(This,Count,prop)
#define ITextDocument_Redo(This,Count,prop) (This)->lpVtbl->Redo(This,Count,prop)
#define ITextDocument_Range(This,cp1,cp2,ppRange) (This)->lpVtbl->Range(This,cp1,cp2,ppRange)
#define ITextDocument_RangeFromPoint(This,x,y,ppRange) (This)->lpVtbl->RangeFromPoint(This,x,y,ppRange)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextDocument_QueryInterface(ITextDocument* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextDocument_AddRef(ITextDocument* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextDocument_Release(ITextDocument* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextDocument_GetTypeInfoCount(ITextDocument* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextDocument_GetTypeInfo(ITextDocument* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextDocument_GetIDsOfNames(ITextDocument* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextDocument_Invoke(ITextDocument* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextDocument methods ***/
static FORCEINLINE HRESULT ITextDocument_GetName(ITextDocument* This,BSTR *pName) {
    return This->lpVtbl->GetName(This,pName);
}
static FORCEINLINE HRESULT ITextDocument_GetSelection(ITextDocument* This,ITextSelection **ppSel) {
    return This->lpVtbl->GetSelection(This,ppSel);
}
static FORCEINLINE HRESULT ITextDocument_GetStoryCount(ITextDocument* This,LONG *pCount) {
    return This->lpVtbl->GetStoryCount(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument_GetStoryRanges(ITextDocument* This,ITextStoryRanges **ppStories) {
    return This->lpVtbl->GetStoryRanges(This,ppStories);
}
static FORCEINLINE HRESULT ITextDocument_GetSaved(ITextDocument* This,LONG *pValue) {
    return This->lpVtbl->GetSaved(This,pValue);
}
static FORCEINLINE HRESULT ITextDocument_SetSaved(ITextDocument* This,LONG Value) {
    return This->lpVtbl->SetSaved(This,Value);
}
static FORCEINLINE HRESULT ITextDocument_GetDefaultTabStop(ITextDocument* This,float *pValue) {
    return This->lpVtbl->GetDefaultTabStop(This,pValue);
}
static FORCEINLINE HRESULT ITextDocument_SetDefaultTabStop(ITextDocument* This,float Value) {
    return This->lpVtbl->SetDefaultTabStop(This,Value);
}
static FORCEINLINE HRESULT ITextDocument_New(ITextDocument* This) {
    return This->lpVtbl->New(This);
}
static FORCEINLINE HRESULT ITextDocument_Open(ITextDocument* This,VARIANT *pVar,LONG Flags,LONG CodePage) {
    return This->lpVtbl->Open(This,pVar,Flags,CodePage);
}
static FORCEINLINE HRESULT ITextDocument_Save(ITextDocument* This,VARIANT *pVar,LONG Flags,LONG CodePage) {
    return This->lpVtbl->Save(This,pVar,Flags,CodePage);
}
static FORCEINLINE HRESULT ITextDocument_Freeze(ITextDocument* This,LONG *pCount) {
    return This->lpVtbl->Freeze(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument_Unfreeze(ITextDocument* This,LONG *pCount) {
    return This->lpVtbl->Unfreeze(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument_BeginEditCollection(ITextDocument* This) {
    return This->lpVtbl->BeginEditCollection(This);
}
static FORCEINLINE HRESULT ITextDocument_EndEditCollection(ITextDocument* This) {
    return This->lpVtbl->EndEditCollection(This);
}
static FORCEINLINE HRESULT ITextDocument_Undo(ITextDocument* This,LONG Count,LONG *prop) {
    return This->lpVtbl->Undo(This,Count,prop);
}
static FORCEINLINE HRESULT ITextDocument_Redo(ITextDocument* This,LONG Count,LONG *prop) {
    return This->lpVtbl->Redo(This,Count,prop);
}
static FORCEINLINE HRESULT ITextDocument_Range(ITextDocument* This,LONG cp1,LONG cp2,ITextRange **ppRange) {
    return This->lpVtbl->Range(This,cp1,cp2,ppRange);
}
static FORCEINLINE HRESULT ITextDocument_RangeFromPoint(ITextDocument* This,LONG x,LONG y,ITextRange **ppRange) {
    return This->lpVtbl->RangeFromPoint(This,x,y,ppRange);
}
#endif
#endif

#endif


#endif  /* __ITextDocument_INTERFACE_DEFINED__ */

/*****************************************************************************
 * ITextDocument2Old interface
 */
#ifndef __ITextDocument2Old_INTERFACE_DEFINED__
#define __ITextDocument2Old_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextDocument2Old, 0x01c25500, 0x4268, 0x11d1, 0x88,0x3a, 0x3c,0x8b,0x00,0xc1,0x00,0x00);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("01c25500-4268-11d1-883a-3c8b00c10000")
ITextDocument2Old : public ITextDocument
{
    virtual HRESULT STDMETHODCALLTYPE AttachMsgFilter(
        IUnknown *filter) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetEffectColor(
        LONG index,
        COLORREF cr) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEffectColor(
        LONG index,
        COLORREF *cr) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetCaretType(
        LONG *type) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetCaretType(
        LONG type) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetImmContext(
        LONG *context) = 0;

    virtual HRESULT STDMETHODCALLTYPE ReleaseImmContext(
        LONG context) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetPreferredFont(
        LONG cp,
        LONG codepage,
        LONG option,
        LONG current_codepage,
        LONG current_fontsize,
        BSTR *bstr,
        LONG *pitch_family,
        LONG *new_fontsize) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetNotificationMode(
        LONG *mode) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetNotificationMode(
        LONG mode) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetClientRect(
        LONG type,
        LONG *left,
        LONG *top,
        LONG *right,
        LONG *bottom) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSelectionEx(
        ITextSelection **selection) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetWindow(
        LONG *hwnd) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetFEFlags(
        LONG *flags) = 0;

    virtual HRESULT STDMETHODCALLTYPE UpdateWindow(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE CheckTextLimit(
        LONG cch,
        LONG *exceed) = 0;

    virtual HRESULT STDMETHODCALLTYPE IMEInProgress(
        LONG mode) = 0;

    virtual HRESULT STDMETHODCALLTYPE SysBeep(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE Update(
        LONG mode) = 0;

    virtual HRESULT STDMETHODCALLTYPE Notify(
        LONG notify) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextDocument2Old, 0x01c25500, 0x4268, 0x11d1, 0x88,0x3a, 0x3c,0x8b,0x00,0xc1,0x00,0x00)
#endif
#else
typedef struct ITextDocument2OldVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextDocument2Old *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextDocument2Old *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextDocument2Old *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextDocument2Old *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextDocument2Old *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextDocument2Old *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextDocument2Old *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextDocument methods ***/
    HRESULT (STDMETHODCALLTYPE *GetName)(
        ITextDocument2Old *This,
        BSTR *pName);

    HRESULT (STDMETHODCALLTYPE *GetSelection)(
        ITextDocument2Old *This,
        ITextSelection **ppSel);

    HRESULT (STDMETHODCALLTYPE *GetStoryCount)(
        ITextDocument2Old *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *GetStoryRanges)(
        ITextDocument2Old *This,
        ITextStoryRanges **ppStories);

    HRESULT (STDMETHODCALLTYPE *GetSaved)(
        ITextDocument2Old *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSaved)(
        ITextDocument2Old *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetDefaultTabStop)(
        ITextDocument2Old *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetDefaultTabStop)(
        ITextDocument2Old *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *New)(
        ITextDocument2Old *This);

    HRESULT (STDMETHODCALLTYPE *Open)(
        ITextDocument2Old *This,
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage);

    HRESULT (STDMETHODCALLTYPE *Save)(
        ITextDocument2Old *This,
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage);

    HRESULT (STDMETHODCALLTYPE *Freeze)(
        ITextDocument2Old *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *Unfreeze)(
        ITextDocument2Old *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *BeginEditCollection)(
        ITextDocument2Old *This);

    HRESULT (STDMETHODCALLTYPE *EndEditCollection)(
        ITextDocument2Old *This);

    HRESULT (STDMETHODCALLTYPE *Undo)(
        ITextDocument2Old *This,
        LONG Count,
        LONG *prop);

    HRESULT (STDMETHODCALLTYPE *Redo)(
        ITextDocument2Old *This,
        LONG Count,
        LONG *prop);

    HRESULT (STDMETHODCALLTYPE *Range)(
        ITextDocument2Old *This,
        LONG cp1,
        LONG cp2,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *RangeFromPoint)(
        ITextDocument2Old *This,
        LONG x,
        LONG y,
        ITextRange **ppRange);

    /*** ITextDocument2Old methods ***/
    HRESULT (STDMETHODCALLTYPE *AttachMsgFilter)(
        ITextDocument2Old *This,
        IUnknown *filter);

    HRESULT (STDMETHODCALLTYPE *SetEffectColor)(
        ITextDocument2Old *This,
        LONG index,
        COLORREF cr);

    HRESULT (STDMETHODCALLTYPE *GetEffectColor)(
        ITextDocument2Old *This,
        LONG index,
        COLORREF *cr);

    HRESULT (STDMETHODCALLTYPE *GetCaretType)(
        ITextDocument2Old *This,
        LONG *type);

    HRESULT (STDMETHODCALLTYPE *SetCaretType)(
        ITextDocument2Old *This,
        LONG type);

    HRESULT (STDMETHODCALLTYPE *GetImmContext)(
        ITextDocument2Old *This,
        LONG *context);

    HRESULT (STDMETHODCALLTYPE *ReleaseImmContext)(
        ITextDocument2Old *This,
        LONG context);

    HRESULT (STDMETHODCALLTYPE *GetPreferredFont)(
        ITextDocument2Old *This,
        LONG cp,
        LONG codepage,
        LONG option,
        LONG current_codepage,
        LONG current_fontsize,
        BSTR *bstr,
        LONG *pitch_family,
        LONG *new_fontsize);

    HRESULT (STDMETHODCALLTYPE *GetNotificationMode)(
        ITextDocument2Old *This,
        LONG *mode);

    HRESULT (STDMETHODCALLTYPE *SetNotificationMode)(
        ITextDocument2Old *This,
        LONG mode);

    HRESULT (STDMETHODCALLTYPE *GetClientRect)(
        ITextDocument2Old *This,
        LONG type,
        LONG *left,
        LONG *top,
        LONG *right,
        LONG *bottom);

    HRESULT (STDMETHODCALLTYPE *GetSelectionEx)(
        ITextDocument2Old *This,
        ITextSelection **selection);

    HRESULT (STDMETHODCALLTYPE *GetWindow)(
        ITextDocument2Old *This,
        LONG *hwnd);

    HRESULT (STDMETHODCALLTYPE *GetFEFlags)(
        ITextDocument2Old *This,
        LONG *flags);

    HRESULT (STDMETHODCALLTYPE *UpdateWindow)(
        ITextDocument2Old *This);

    HRESULT (STDMETHODCALLTYPE *CheckTextLimit)(
        ITextDocument2Old *This,
        LONG cch,
        LONG *exceed);

    HRESULT (STDMETHODCALLTYPE *IMEInProgress)(
        ITextDocument2Old *This,
        LONG mode);

    HRESULT (STDMETHODCALLTYPE *SysBeep)(
        ITextDocument2Old *This);

    HRESULT (STDMETHODCALLTYPE *Update)(
        ITextDocument2Old *This,
        LONG mode);

    HRESULT (STDMETHODCALLTYPE *Notify)(
        ITextDocument2Old *This,
        LONG notify);

    END_INTERFACE
} ITextDocument2OldVtbl;

interface ITextDocument2Old {
    CONST_VTBL ITextDocument2OldVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextDocument2Old_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextDocument2Old_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextDocument2Old_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextDocument2Old_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextDocument2Old_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextDocument2Old_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextDocument2Old_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextDocument methods ***/
#define ITextDocument2Old_GetName(This,pName) (This)->lpVtbl->GetName(This,pName)
#define ITextDocument2Old_GetSelection(This,ppSel) (This)->lpVtbl->GetSelection(This,ppSel)
#define ITextDocument2Old_GetStoryCount(This,pCount) (This)->lpVtbl->GetStoryCount(This,pCount)
#define ITextDocument2Old_GetStoryRanges(This,ppStories) (This)->lpVtbl->GetStoryRanges(This,ppStories)
#define ITextDocument2Old_GetSaved(This,pValue) (This)->lpVtbl->GetSaved(This,pValue)
#define ITextDocument2Old_SetSaved(This,Value) (This)->lpVtbl->SetSaved(This,Value)
#define ITextDocument2Old_GetDefaultTabStop(This,pValue) (This)->lpVtbl->GetDefaultTabStop(This,pValue)
#define ITextDocument2Old_SetDefaultTabStop(This,Value) (This)->lpVtbl->SetDefaultTabStop(This,Value)
#define ITextDocument2Old_New(This) (This)->lpVtbl->New(This)
#define ITextDocument2Old_Open(This,pVar,Flags,CodePage) (This)->lpVtbl->Open(This,pVar,Flags,CodePage)
#define ITextDocument2Old_Save(This,pVar,Flags,CodePage) (This)->lpVtbl->Save(This,pVar,Flags,CodePage)
#define ITextDocument2Old_Freeze(This,pCount) (This)->lpVtbl->Freeze(This,pCount)
#define ITextDocument2Old_Unfreeze(This,pCount) (This)->lpVtbl->Unfreeze(This,pCount)
#define ITextDocument2Old_BeginEditCollection(This) (This)->lpVtbl->BeginEditCollection(This)
#define ITextDocument2Old_EndEditCollection(This) (This)->lpVtbl->EndEditCollection(This)
#define ITextDocument2Old_Undo(This,Count,prop) (This)->lpVtbl->Undo(This,Count,prop)
#define ITextDocument2Old_Redo(This,Count,prop) (This)->lpVtbl->Redo(This,Count,prop)
#define ITextDocument2Old_Range(This,cp1,cp2,ppRange) (This)->lpVtbl->Range(This,cp1,cp2,ppRange)
#define ITextDocument2Old_RangeFromPoint(This,x,y,ppRange) (This)->lpVtbl->RangeFromPoint(This,x,y,ppRange)
/*** ITextDocument2Old methods ***/
#define ITextDocument2Old_AttachMsgFilter(This,filter) (This)->lpVtbl->AttachMsgFilter(This,filter)
#define ITextDocument2Old_SetEffectColor(This,index,cr) (This)->lpVtbl->SetEffectColor(This,index,cr)
#define ITextDocument2Old_GetEffectColor(This,index,cr) (This)->lpVtbl->GetEffectColor(This,index,cr)
#define ITextDocument2Old_GetCaretType(This,type) (This)->lpVtbl->GetCaretType(This,type)
#define ITextDocument2Old_SetCaretType(This,type) (This)->lpVtbl->SetCaretType(This,type)
#define ITextDocument2Old_GetImmContext(This,context) (This)->lpVtbl->GetImmContext(This,context)
#define ITextDocument2Old_ReleaseImmContext(This,context) (This)->lpVtbl->ReleaseImmContext(This,context)
#define ITextDocument2Old_GetPreferredFont(This,cp,codepage,option,current_codepage,current_fontsize,bstr,pitch_family,new_fontsize) (This)->lpVtbl->GetPreferredFont(This,cp,codepage,option,current_codepage,current_fontsize,bstr,pitch_family,new_fontsize)
#define ITextDocument2Old_GetNotificationMode(This,mode) (This)->lpVtbl->GetNotificationMode(This,mode)
#define ITextDocument2Old_SetNotificationMode(This,mode) (This)->lpVtbl->SetNotificationMode(This,mode)
#define ITextDocument2Old_GetClientRect(This,type,left,top,right,bottom) (This)->lpVtbl->GetClientRect(This,type,left,top,right,bottom)
#define ITextDocument2Old_GetSelectionEx(This,selection) (This)->lpVtbl->GetSelectionEx(This,selection)
#define ITextDocument2Old_GetWindow(This,hwnd) (This)->lpVtbl->GetWindow(This,hwnd)
#define ITextDocument2Old_GetFEFlags(This,flags) (This)->lpVtbl->GetFEFlags(This,flags)
#define ITextDocument2Old_UpdateWindow(This) (This)->lpVtbl->UpdateWindow(This)
#define ITextDocument2Old_CheckTextLimit(This,cch,exceed) (This)->lpVtbl->CheckTextLimit(This,cch,exceed)
#define ITextDocument2Old_IMEInProgress(This,mode) (This)->lpVtbl->IMEInProgress(This,mode)
#define ITextDocument2Old_SysBeep(This) (This)->lpVtbl->SysBeep(This)
#define ITextDocument2Old_Update(This,mode) (This)->lpVtbl->Update(This,mode)
#define ITextDocument2Old_Notify(This,notify) (This)->lpVtbl->Notify(This,notify)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextDocument2Old_QueryInterface(ITextDocument2Old* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextDocument2Old_AddRef(ITextDocument2Old* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextDocument2Old_Release(ITextDocument2Old* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextDocument2Old_GetTypeInfoCount(ITextDocument2Old* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetTypeInfo(ITextDocument2Old* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetIDsOfNames(ITextDocument2Old* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextDocument2Old_Invoke(ITextDocument2Old* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextDocument methods ***/
static FORCEINLINE HRESULT ITextDocument2Old_GetName(ITextDocument2Old* This,BSTR *pName) {
    return This->lpVtbl->GetName(This,pName);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetSelection(ITextDocument2Old* This,ITextSelection **ppSel) {
    return This->lpVtbl->GetSelection(This,ppSel);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetStoryCount(ITextDocument2Old* This,LONG *pCount) {
    return This->lpVtbl->GetStoryCount(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetStoryRanges(ITextDocument2Old* This,ITextStoryRanges **ppStories) {
    return This->lpVtbl->GetStoryRanges(This,ppStories);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetSaved(ITextDocument2Old* This,LONG *pValue) {
    return This->lpVtbl->GetSaved(This,pValue);
}
static FORCEINLINE HRESULT ITextDocument2Old_SetSaved(ITextDocument2Old* This,LONG Value) {
    return This->lpVtbl->SetSaved(This,Value);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetDefaultTabStop(ITextDocument2Old* This,float *pValue) {
    return This->lpVtbl->GetDefaultTabStop(This,pValue);
}
static FORCEINLINE HRESULT ITextDocument2Old_SetDefaultTabStop(ITextDocument2Old* This,float Value) {
    return This->lpVtbl->SetDefaultTabStop(This,Value);
}
static FORCEINLINE HRESULT ITextDocument2Old_New(ITextDocument2Old* This) {
    return This->lpVtbl->New(This);
}
static FORCEINLINE HRESULT ITextDocument2Old_Open(ITextDocument2Old* This,VARIANT *pVar,LONG Flags,LONG CodePage) {
    return This->lpVtbl->Open(This,pVar,Flags,CodePage);
}
static FORCEINLINE HRESULT ITextDocument2Old_Save(ITextDocument2Old* This,VARIANT *pVar,LONG Flags,LONG CodePage) {
    return This->lpVtbl->Save(This,pVar,Flags,CodePage);
}
static FORCEINLINE HRESULT ITextDocument2Old_Freeze(ITextDocument2Old* This,LONG *pCount) {
    return This->lpVtbl->Freeze(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument2Old_Unfreeze(ITextDocument2Old* This,LONG *pCount) {
    return This->lpVtbl->Unfreeze(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument2Old_BeginEditCollection(ITextDocument2Old* This) {
    return This->lpVtbl->BeginEditCollection(This);
}
static FORCEINLINE HRESULT ITextDocument2Old_EndEditCollection(ITextDocument2Old* This) {
    return This->lpVtbl->EndEditCollection(This);
}
static FORCEINLINE HRESULT ITextDocument2Old_Undo(ITextDocument2Old* This,LONG Count,LONG *prop) {
    return This->lpVtbl->Undo(This,Count,prop);
}
static FORCEINLINE HRESULT ITextDocument2Old_Redo(ITextDocument2Old* This,LONG Count,LONG *prop) {
    return This->lpVtbl->Redo(This,Count,prop);
}
static FORCEINLINE HRESULT ITextDocument2Old_Range(ITextDocument2Old* This,LONG cp1,LONG cp2,ITextRange **ppRange) {
    return This->lpVtbl->Range(This,cp1,cp2,ppRange);
}
static FORCEINLINE HRESULT ITextDocument2Old_RangeFromPoint(ITextDocument2Old* This,LONG x,LONG y,ITextRange **ppRange) {
    return This->lpVtbl->RangeFromPoint(This,x,y,ppRange);
}
/*** ITextDocument2Old methods ***/
static FORCEINLINE HRESULT ITextDocument2Old_AttachMsgFilter(ITextDocument2Old* This,IUnknown *filter) {
    return This->lpVtbl->AttachMsgFilter(This,filter);
}
static FORCEINLINE HRESULT ITextDocument2Old_SetEffectColor(ITextDocument2Old* This,LONG index,COLORREF cr) {
    return This->lpVtbl->SetEffectColor(This,index,cr);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetEffectColor(ITextDocument2Old* This,LONG index,COLORREF *cr) {
    return This->lpVtbl->GetEffectColor(This,index,cr);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetCaretType(ITextDocument2Old* This,LONG *type) {
    return This->lpVtbl->GetCaretType(This,type);
}
static FORCEINLINE HRESULT ITextDocument2Old_SetCaretType(ITextDocument2Old* This,LONG type) {
    return This->lpVtbl->SetCaretType(This,type);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetImmContext(ITextDocument2Old* This,LONG *context) {
    return This->lpVtbl->GetImmContext(This,context);
}
static FORCEINLINE HRESULT ITextDocument2Old_ReleaseImmContext(ITextDocument2Old* This,LONG context) {
    return This->lpVtbl->ReleaseImmContext(This,context);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetPreferredFont(ITextDocument2Old* This,LONG cp,LONG codepage,LONG option,LONG current_codepage,LONG current_fontsize,BSTR *bstr,LONG *pitch_family,LONG *new_fontsize) {
    return This->lpVtbl->GetPreferredFont(This,cp,codepage,option,current_codepage,current_fontsize,bstr,pitch_family,new_fontsize);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetNotificationMode(ITextDocument2Old* This,LONG *mode) {
    return This->lpVtbl->GetNotificationMode(This,mode);
}
static FORCEINLINE HRESULT ITextDocument2Old_SetNotificationMode(ITextDocument2Old* This,LONG mode) {
    return This->lpVtbl->SetNotificationMode(This,mode);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetClientRect(ITextDocument2Old* This,LONG type,LONG *left,LONG *top,LONG *right,LONG *bottom) {
    return This->lpVtbl->GetClientRect(This,type,left,top,right,bottom);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetSelectionEx(ITextDocument2Old* This,ITextSelection **selection) {
    return This->lpVtbl->GetSelectionEx(This,selection);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetWindow(ITextDocument2Old* This,LONG *hwnd) {
    return This->lpVtbl->GetWindow(This,hwnd);
}
static FORCEINLINE HRESULT ITextDocument2Old_GetFEFlags(ITextDocument2Old* This,LONG *flags) {
    return This->lpVtbl->GetFEFlags(This,flags);
}
static FORCEINLINE HRESULT ITextDocument2Old_UpdateWindow(ITextDocument2Old* This) {
    return This->lpVtbl->UpdateWindow(This);
}
static FORCEINLINE HRESULT ITextDocument2Old_CheckTextLimit(ITextDocument2Old* This,LONG cch,LONG *exceed) {
    return This->lpVtbl->CheckTextLimit(This,cch,exceed);
}
static FORCEINLINE HRESULT ITextDocument2Old_IMEInProgress(ITextDocument2Old* This,LONG mode) {
    return This->lpVtbl->IMEInProgress(This,mode);
}
static FORCEINLINE HRESULT ITextDocument2Old_SysBeep(ITextDocument2Old* This) {
    return This->lpVtbl->SysBeep(This);
}
static FORCEINLINE HRESULT ITextDocument2Old_Update(ITextDocument2Old* This,LONG mode) {
    return This->lpVtbl->Update(This,mode);
}
static FORCEINLINE HRESULT ITextDocument2Old_Notify(ITextDocument2Old* This,LONG notify) {
    return This->lpVtbl->Notify(This,notify);
}
#endif
#endif

#endif


#endif  /* __ITextDocument2Old_INTERFACE_DEFINED__ */

#ifndef __ITextDisplays_FWD_DEFINED__
#define __ITextDisplays_FWD_DEFINED__
typedef interface ITextDisplays ITextDisplays;
#ifdef __cplusplus
interface ITextDisplays;
#endif /* __cplusplus */
#endif

#ifndef __ITextFont2_FWD_DEFINED__
#define __ITextFont2_FWD_DEFINED__
typedef interface ITextFont2 ITextFont2;
#ifdef __cplusplus
interface ITextFont2;
#endif /* __cplusplus */
#endif

#ifndef __ITextPara2_FWD_DEFINED__
#define __ITextPara2_FWD_DEFINED__
typedef interface ITextPara2 ITextPara2;
#ifdef __cplusplus
interface ITextPara2;
#endif /* __cplusplus */
#endif

#ifndef __ITextRange2_FWD_DEFINED__
#define __ITextRange2_FWD_DEFINED__
typedef interface ITextRange2 ITextRange2;
#ifdef __cplusplus
interface ITextRange2;
#endif /* __cplusplus */
#endif

#ifndef __ITextSelection2_FWD_DEFINED__
#define __ITextSelection2_FWD_DEFINED__
typedef interface ITextSelection2 ITextSelection2;
#ifdef __cplusplus
interface ITextSelection2;
#endif /* __cplusplus */
#endif

#ifndef __ITextStory_FWD_DEFINED__
#define __ITextStory_FWD_DEFINED__
typedef interface ITextStory ITextStory;
#ifdef __cplusplus
interface ITextStory;
#endif /* __cplusplus */
#endif

#ifndef __ITextStoryRanges2_FWD_DEFINED__
#define __ITextStoryRanges2_FWD_DEFINED__
typedef interface ITextStoryRanges2 ITextStoryRanges2;
#ifdef __cplusplus
interface ITextStoryRanges2;
#endif /* __cplusplus */
#endif

#ifndef __ITextStrings_FWD_DEFINED__
#define __ITextStrings_FWD_DEFINED__
typedef interface ITextStrings ITextStrings;
#ifdef __cplusplus
interface ITextStrings;
#endif /* __cplusplus */
#endif

/*****************************************************************************
 * ITextDocument2 interface
 */
#ifndef __ITextDocument2_INTERFACE_DEFINED__
#define __ITextDocument2_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextDocument2, 0xc241f5e0, 0x7206, 0x11d8, 0xa2,0xc7, 0x00,0xa0,0xd1,0xd6,0xc6,0xb3);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("c241f5e0-7206-11d8-a2c7-00a0d1d6c6b3")
ITextDocument2 : public ITextDocument
{
    virtual HRESULT STDMETHODCALLTYPE GetCaretType(
        LONG *value) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetCaretType(
        LONG value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetDisplays(
        ITextDisplays **displays) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetDocumentFont(
        ITextFont2 **font) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetDocumentFont(
        ITextFont2 *font) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetDocumentPara(
        ITextPara2 **para) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetDocumentPara(
        ITextPara2 *para) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEastAsianFlags(
        LONG *flags) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetGenerator(
        BSTR *bstr) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetIMEInProgress(
        LONG value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetNotificationMode(
        LONG *mode) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetNotificationMode(
        LONG mode) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSelection2(
        ITextSelection2 **selection) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStoryRanges2(
        ITextStoryRanges2 **stories) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetTypographyOptions(
        LONG *options) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetVersion(
        LONG *value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetWindow(
        LONG *hwnd) = 0;

    virtual HRESULT STDMETHODCALLTYPE AttachMsgFilter(
        IUnknown *filter) = 0;

    virtual HRESULT STDMETHODCALLTYPE CheckTextLimit(
        LONG cch,
        LONG *exceed) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetCallManager(
        IUnknown **manager) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetClientRect(
        LONG type,
        LONG *left,
        LONG *top,
        LONG *right,
        LONG *bottom) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEffectColor(
        LONG index,
        COLORREF *cr) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetImmContext(
        LONG *context) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetPreferredFont(
        LONG cp,
        LONG codepage,
        LONG option,
        LONG current_codepage,
        LONG current_fontsize,
        BSTR *bstr,
        LONG *pitch_family,
        LONG *new_fontsize) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetProperty(
        LONG type,
        LONG *value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStrings(
        ITextStrings **strings) = 0;

    virtual HRESULT STDMETHODCALLTYPE Notify(
        LONG notify) = 0;

    virtual HRESULT STDMETHODCALLTYPE Range2(
        LONG cp_active,
        LONG cp_anchor,
        ITextRange2 **range) = 0;

    virtual HRESULT STDMETHODCALLTYPE RangeFromPoint2(
        LONG x,
        LONG y,
        LONG type,
        ITextRange2 **range) = 0;

    virtual HRESULT STDMETHODCALLTYPE ReleaseCallManager(
        IUnknown *manager) = 0;

    virtual HRESULT STDMETHODCALLTYPE ReleaseImmContext(
        LONG context) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetEffectColor(
        LONG index,
        LONG value) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetProperty(
        LONG type,
        LONG value) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetTypographyOptions(
        LONG options,
        LONG mask) = 0;

    virtual HRESULT STDMETHODCALLTYPE SysBeep(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE Update(
        LONG value) = 0;

    virtual HRESULT STDMETHODCALLTYPE UpdateWindow(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetMathProperties(
        LONG *options) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetMathProperties(
        LONG options,
        LONG mask) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetActiveStory(
        ITextStory **story) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetActiveStory(
        ITextStory *story) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetMainStory(
        ITextStory **story) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetNewStory(
        ITextStory **story) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStory(
        LONG index,
        ITextStory **story) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextDocument2, 0xc241f5e0, 0x7206, 0x11d8, 0xa2,0xc7, 0x00,0xa0,0xd1,0xd6,0xc6,0xb3)
#endif
#else
typedef struct ITextDocument2Vtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextDocument2 *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextDocument2 *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextDocument2 *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextDocument2 *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextDocument2 *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextDocument2 *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextDocument2 *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextDocument methods ***/
    HRESULT (STDMETHODCALLTYPE *GetName)(
        ITextDocument2 *This,
        BSTR *pName);

    HRESULT (STDMETHODCALLTYPE *GetSelection)(
        ITextDocument2 *This,
        ITextSelection **ppSel);

    HRESULT (STDMETHODCALLTYPE *GetStoryCount)(
        ITextDocument2 *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *GetStoryRanges)(
        ITextDocument2 *This,
        ITextStoryRanges **ppStories);

    HRESULT (STDMETHODCALLTYPE *GetSaved)(
        ITextDocument2 *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSaved)(
        ITextDocument2 *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetDefaultTabStop)(
        ITextDocument2 *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetDefaultTabStop)(
        ITextDocument2 *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *New)(
        ITextDocument2 *This);

    HRESULT (STDMETHODCALLTYPE *Open)(
        ITextDocument2 *This,
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage);

    HRESULT (STDMETHODCALLTYPE *Save)(
        ITextDocument2 *This,
        VARIANT *pVar,
        LONG Flags,
        LONG CodePage);

    HRESULT (STDMETHODCALLTYPE *Freeze)(
        ITextDocument2 *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *Unfreeze)(
        ITextDocument2 *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *BeginEditCollection)(
        ITextDocument2 *This);

    HRESULT (STDMETHODCALLTYPE *EndEditCollection)(
        ITextDocument2 *This);

    HRESULT (STDMETHODCALLTYPE *Undo)(
        ITextDocument2 *This,
        LONG Count,
        LONG *prop);

    HRESULT (STDMETHODCALLTYPE *Redo)(
        ITextDocument2 *This,
        LONG Count,
        LONG *prop);

    HRESULT (STDMETHODCALLTYPE *Range)(
        ITextDocument2 *This,
        LONG cp1,
        LONG cp2,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *RangeFromPoint)(
        ITextDocument2 *This,
        LONG x,
        LONG y,
        ITextRange **ppRange);

    /*** ITextDocument2 methods ***/
    HRESULT (STDMETHODCALLTYPE *GetCaretType)(
        ITextDocument2 *This,
        LONG *value);

    HRESULT (STDMETHODCALLTYPE *SetCaretType)(
        ITextDocument2 *This,
        LONG value);

    HRESULT (STDMETHODCALLTYPE *GetDisplays)(
        ITextDocument2 *This,
        ITextDisplays **displays);

    HRESULT (STDMETHODCALLTYPE *GetDocumentFont)(
        ITextDocument2 *This,
        ITextFont2 **font);

    HRESULT (STDMETHODCALLTYPE *SetDocumentFont)(
        ITextDocument2 *This,
        ITextFont2 *font);

    HRESULT (STDMETHODCALLTYPE *GetDocumentPara)(
        ITextDocument2 *This,
        ITextPara2 **para);

    HRESULT (STDMETHODCALLTYPE *SetDocumentPara)(
        ITextDocument2 *This,
        ITextPara2 *para);

    HRESULT (STDMETHODCALLTYPE *GetEastAsianFlags)(
        ITextDocument2 *This,
        LONG *flags);

    HRESULT (STDMETHODCALLTYPE *GetGenerator)(
        ITextDocument2 *This,
        BSTR *bstr);

    HRESULT (STDMETHODCALLTYPE *SetIMEInProgress)(
        ITextDocument2 *This,
        LONG value);

    HRESULT (STDMETHODCALLTYPE *GetNotificationMode)(
        ITextDocument2 *This,
        LONG *mode);

    HRESULT (STDMETHODCALLTYPE *SetNotificationMode)(
        ITextDocument2 *This,
        LONG mode);

    HRESULT (STDMETHODCALLTYPE *GetSelection2)(
        ITextDocument2 *This,
        ITextSelection2 **selection);

    HRESULT (STDMETHODCALLTYPE *GetStoryRanges2)(
        ITextDocument2 *This,
        ITextStoryRanges2 **stories);

    HRESULT (STDMETHODCALLTYPE *GetTypographyOptions)(
        ITextDocument2 *This,
        LONG *options);

    HRESULT (STDMETHODCALLTYPE *GetVersion)(
        ITextDocument2 *This,
        LONG *value);

    HRESULT (STDMETHODCALLTYPE *GetWindow)(
        ITextDocument2 *This,
        LONG *hwnd);

    HRESULT (STDMETHODCALLTYPE *AttachMsgFilter)(
        ITextDocument2 *This,
        IUnknown *filter);

    HRESULT (STDMETHODCALLTYPE *CheckTextLimit)(
        ITextDocument2 *This,
        LONG cch,
        LONG *exceed);

    HRESULT (STDMETHODCALLTYPE *GetCallManager)(
        ITextDocument2 *This,
        IUnknown **manager);

    HRESULT (STDMETHODCALLTYPE *GetClientRect)(
        ITextDocument2 *This,
        LONG type,
        LONG *left,
        LONG *top,
        LONG *right,
        LONG *bottom);

    HRESULT (STDMETHODCALLTYPE *GetEffectColor)(
        ITextDocument2 *This,
        LONG index,
        COLORREF *cr);

    HRESULT (STDMETHODCALLTYPE *GetImmContext)(
        ITextDocument2 *This,
        LONG *context);

    HRESULT (STDMETHODCALLTYPE *GetPreferredFont)(
        ITextDocument2 *This,
        LONG cp,
        LONG codepage,
        LONG option,
        LONG current_codepage,
        LONG current_fontsize,
        BSTR *bstr,
        LONG *pitch_family,
        LONG *new_fontsize);

    HRESULT (STDMETHODCALLTYPE *GetProperty)(
        ITextDocument2 *This,
        LONG type,
        LONG *value);

    HRESULT (STDMETHODCALLTYPE *GetStrings)(
        ITextDocument2 *This,
        ITextStrings **strings);

    HRESULT (STDMETHODCALLTYPE *Notify)(
        ITextDocument2 *This,
        LONG notify);

    HRESULT (STDMETHODCALLTYPE *Range2)(
        ITextDocument2 *This,
        LONG cp_active,
        LONG cp_anchor,
        ITextRange2 **range);

    HRESULT (STDMETHODCALLTYPE *RangeFromPoint2)(
        ITextDocument2 *This,
        LONG x,
        LONG y,
        LONG type,
        ITextRange2 **range);

    HRESULT (STDMETHODCALLTYPE *ReleaseCallManager)(
        ITextDocument2 *This,
        IUnknown *manager);

    HRESULT (STDMETHODCALLTYPE *ReleaseImmContext)(
        ITextDocument2 *This,
        LONG context);

    HRESULT (STDMETHODCALLTYPE *SetEffectColor)(
        ITextDocument2 *This,
        LONG index,
        LONG value);

    HRESULT (STDMETHODCALLTYPE *SetProperty)(
        ITextDocument2 *This,
        LONG type,
        LONG value);

    HRESULT (STDMETHODCALLTYPE *SetTypographyOptions)(
        ITextDocument2 *This,
        LONG options,
        LONG mask);

    HRESULT (STDMETHODCALLTYPE *SysBeep)(
        ITextDocument2 *This);

    HRESULT (STDMETHODCALLTYPE *Update)(
        ITextDocument2 *This,
        LONG value);

    HRESULT (STDMETHODCALLTYPE *UpdateWindow)(
        ITextDocument2 *This);

    HRESULT (STDMETHODCALLTYPE *GetMathProperties)(
        ITextDocument2 *This,
        LONG *options);

    HRESULT (STDMETHODCALLTYPE *SetMathProperties)(
        ITextDocument2 *This,
        LONG options,
        LONG mask);

    HRESULT (STDMETHODCALLTYPE *GetActiveStory)(
        ITextDocument2 *This,
        ITextStory **story);

    HRESULT (STDMETHODCALLTYPE *SetActiveStory)(
        ITextDocument2 *This,
        ITextStory *story);

    HRESULT (STDMETHODCALLTYPE *GetMainStory)(
        ITextDocument2 *This,
        ITextStory **story);

    HRESULT (STDMETHODCALLTYPE *GetNewStory)(
        ITextDocument2 *This,
        ITextStory **story);

    HRESULT (STDMETHODCALLTYPE *GetStory)(
        ITextDocument2 *This,
        LONG index,
        ITextStory **story);

    END_INTERFACE
} ITextDocument2Vtbl;

interface ITextDocument2 {
    CONST_VTBL ITextDocument2Vtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextDocument2_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextDocument2_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextDocument2_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextDocument2_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextDocument2_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextDocument2_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextDocument2_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextDocument methods ***/
#define ITextDocument2_GetName(This,pName) (This)->lpVtbl->GetName(This,pName)
#define ITextDocument2_GetSelection(This,ppSel) (This)->lpVtbl->GetSelection(This,ppSel)
#define ITextDocument2_GetStoryCount(This,pCount) (This)->lpVtbl->GetStoryCount(This,pCount)
#define ITextDocument2_GetStoryRanges(This,ppStories) (This)->lpVtbl->GetStoryRanges(This,ppStories)
#define ITextDocument2_GetSaved(This,pValue) (This)->lpVtbl->GetSaved(This,pValue)
#define ITextDocument2_SetSaved(This,Value) (This)->lpVtbl->SetSaved(This,Value)
#define ITextDocument2_GetDefaultTabStop(This,pValue) (This)->lpVtbl->GetDefaultTabStop(This,pValue)
#define ITextDocument2_SetDefaultTabStop(This,Value) (This)->lpVtbl->SetDefaultTabStop(This,Value)
#define ITextDocument2_New(This) (This)->lpVtbl->New(This)
#define ITextDocument2_Open(This,pVar,Flags,CodePage) (This)->lpVtbl->Open(This,pVar,Flags,CodePage)
#define ITextDocument2_Save(This,pVar,Flags,CodePage) (This)->lpVtbl->Save(This,pVar,Flags,CodePage)
#define ITextDocument2_Freeze(This,pCount) (This)->lpVtbl->Freeze(This,pCount)
#define ITextDocument2_Unfreeze(This,pCount) (This)->lpVtbl->Unfreeze(This,pCount)
#define ITextDocument2_BeginEditCollection(This) (This)->lpVtbl->BeginEditCollection(This)
#define ITextDocument2_EndEditCollection(This) (This)->lpVtbl->EndEditCollection(This)
#define ITextDocument2_Undo(This,Count,prop) (This)->lpVtbl->Undo(This,Count,prop)
#define ITextDocument2_Redo(This,Count,prop) (This)->lpVtbl->Redo(This,Count,prop)
#define ITextDocument2_Range(This,cp1,cp2,ppRange) (This)->lpVtbl->Range(This,cp1,cp2,ppRange)
#define ITextDocument2_RangeFromPoint(This,x,y,ppRange) (This)->lpVtbl->RangeFromPoint(This,x,y,ppRange)
/*** ITextDocument2 methods ***/
#define ITextDocument2_GetCaretType(This,value) (This)->lpVtbl->GetCaretType(This,value)
#define ITextDocument2_SetCaretType(This,value) (This)->lpVtbl->SetCaretType(This,value)
#define ITextDocument2_GetDisplays(This,displays) (This)->lpVtbl->GetDisplays(This,displays)
#define ITextDocument2_GetDocumentFont(This,font) (This)->lpVtbl->GetDocumentFont(This,font)
#define ITextDocument2_SetDocumentFont(This,font) (This)->lpVtbl->SetDocumentFont(This,font)
#define ITextDocument2_GetDocumentPara(This,para) (This)->lpVtbl->GetDocumentPara(This,para)
#define ITextDocument2_SetDocumentPara(This,para) (This)->lpVtbl->SetDocumentPara(This,para)
#define ITextDocument2_GetEastAsianFlags(This,flags) (This)->lpVtbl->GetEastAsianFlags(This,flags)
#define ITextDocument2_GetGenerator(This,bstr) (This)->lpVtbl->GetGenerator(This,bstr)
#define ITextDocument2_SetIMEInProgress(This,value) (This)->lpVtbl->SetIMEInProgress(This,value)
#define ITextDocument2_GetNotificationMode(This,mode) (This)->lpVtbl->GetNotificationMode(This,mode)
#define ITextDocument2_SetNotificationMode(This,mode) (This)->lpVtbl->SetNotificationMode(This,mode)
#define ITextDocument2_GetSelection2(This,selection) (This)->lpVtbl->GetSelection2(This,selection)
#define ITextDocument2_GetStoryRanges2(This,stories) (This)->lpVtbl->GetStoryRanges2(This,stories)
#define ITextDocument2_GetTypographyOptions(This,options) (This)->lpVtbl->GetTypographyOptions(This,options)
#define ITextDocument2_GetVersion(This,value) (This)->lpVtbl->GetVersion(This,value)
#define ITextDocument2_GetWindow(This,hwnd) (This)->lpVtbl->GetWindow(This,hwnd)
#define ITextDocument2_AttachMsgFilter(This,filter) (This)->lpVtbl->AttachMsgFilter(This,filter)
#define ITextDocument2_CheckTextLimit(This,cch,exceed) (This)->lpVtbl->CheckTextLimit(This,cch,exceed)
#define ITextDocument2_GetCallManager(This,manager) (This)->lpVtbl->GetCallManager(This,manager)
#define ITextDocument2_GetClientRect(This,type,left,top,right,bottom) (This)->lpVtbl->GetClientRect(This,type,left,top,right,bottom)
#define ITextDocument2_GetEffectColor(This,index,cr) (This)->lpVtbl->GetEffectColor(This,index,cr)
#define ITextDocument2_GetImmContext(This,context) (This)->lpVtbl->GetImmContext(This,context)
#define ITextDocument2_GetPreferredFont(This,cp,codepage,option,current_codepage,current_fontsize,bstr,pitch_family,new_fontsize) (This)->lpVtbl->GetPreferredFont(This,cp,codepage,option,current_codepage,current_fontsize,bstr,pitch_family,new_fontsize)
#define ITextDocument2_GetProperty(This,type,value) (This)->lpVtbl->GetProperty(This,type,value)
#define ITextDocument2_GetStrings(This,strings) (This)->lpVtbl->GetStrings(This,strings)
#define ITextDocument2_Notify(This,notify) (This)->lpVtbl->Notify(This,notify)
#define ITextDocument2_Range2(This,cp_active,cp_anchor,range) (This)->lpVtbl->Range2(This,cp_active,cp_anchor,range)
#define ITextDocument2_RangeFromPoint2(This,x,y,type,range) (This)->lpVtbl->RangeFromPoint2(This,x,y,type,range)
#define ITextDocument2_ReleaseCallManager(This,manager) (This)->lpVtbl->ReleaseCallManager(This,manager)
#define ITextDocument2_ReleaseImmContext(This,context) (This)->lpVtbl->ReleaseImmContext(This,context)
#define ITextDocument2_SetEffectColor(This,index,value) (This)->lpVtbl->SetEffectColor(This,index,value)
#define ITextDocument2_SetProperty(This,type,value) (This)->lpVtbl->SetProperty(This,type,value)
#define ITextDocument2_SetTypographyOptions(This,options,mask) (This)->lpVtbl->SetTypographyOptions(This,options,mask)
#define ITextDocument2_SysBeep(This) (This)->lpVtbl->SysBeep(This)
#define ITextDocument2_Update(This,value) (This)->lpVtbl->Update(This,value)
#define ITextDocument2_UpdateWindow(This) (This)->lpVtbl->UpdateWindow(This)
#define ITextDocument2_GetMathProperties(This,options) (This)->lpVtbl->GetMathProperties(This,options)
#define ITextDocument2_SetMathProperties(This,options,mask) (This)->lpVtbl->SetMathProperties(This,options,mask)
#define ITextDocument2_GetActiveStory(This,story) (This)->lpVtbl->GetActiveStory(This,story)
#define ITextDocument2_SetActiveStory(This,story) (This)->lpVtbl->SetActiveStory(This,story)
#define ITextDocument2_GetMainStory(This,story) (This)->lpVtbl->GetMainStory(This,story)
#define ITextDocument2_GetNewStory(This,story) (This)->lpVtbl->GetNewStory(This,story)
#define ITextDocument2_GetStory(This,index,story) (This)->lpVtbl->GetStory(This,index,story)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextDocument2_QueryInterface(ITextDocument2* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextDocument2_AddRef(ITextDocument2* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextDocument2_Release(ITextDocument2* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextDocument2_GetTypeInfoCount(ITextDocument2* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextDocument2_GetTypeInfo(ITextDocument2* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextDocument2_GetIDsOfNames(ITextDocument2* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextDocument2_Invoke(ITextDocument2* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextDocument methods ***/
static FORCEINLINE HRESULT ITextDocument2_GetName(ITextDocument2* This,BSTR *pName) {
    return This->lpVtbl->GetName(This,pName);
}
static FORCEINLINE HRESULT ITextDocument2_GetSelection(ITextDocument2* This,ITextSelection **ppSel) {
    return This->lpVtbl->GetSelection(This,ppSel);
}
static FORCEINLINE HRESULT ITextDocument2_GetStoryCount(ITextDocument2* This,LONG *pCount) {
    return This->lpVtbl->GetStoryCount(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument2_GetStoryRanges(ITextDocument2* This,ITextStoryRanges **ppStories) {
    return This->lpVtbl->GetStoryRanges(This,ppStories);
}
static FORCEINLINE HRESULT ITextDocument2_GetSaved(ITextDocument2* This,LONG *pValue) {
    return This->lpVtbl->GetSaved(This,pValue);
}
static FORCEINLINE HRESULT ITextDocument2_SetSaved(ITextDocument2* This,LONG Value) {
    return This->lpVtbl->SetSaved(This,Value);
}
static FORCEINLINE HRESULT ITextDocument2_GetDefaultTabStop(ITextDocument2* This,float *pValue) {
    return This->lpVtbl->GetDefaultTabStop(This,pValue);
}
static FORCEINLINE HRESULT ITextDocument2_SetDefaultTabStop(ITextDocument2* This,float Value) {
    return This->lpVtbl->SetDefaultTabStop(This,Value);
}
static FORCEINLINE HRESULT ITextDocument2_New(ITextDocument2* This) {
    return This->lpVtbl->New(This);
}
static FORCEINLINE HRESULT ITextDocument2_Open(ITextDocument2* This,VARIANT *pVar,LONG Flags,LONG CodePage) {
    return This->lpVtbl->Open(This,pVar,Flags,CodePage);
}
static FORCEINLINE HRESULT ITextDocument2_Save(ITextDocument2* This,VARIANT *pVar,LONG Flags,LONG CodePage) {
    return This->lpVtbl->Save(This,pVar,Flags,CodePage);
}
static FORCEINLINE HRESULT ITextDocument2_Freeze(ITextDocument2* This,LONG *pCount) {
    return This->lpVtbl->Freeze(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument2_Unfreeze(ITextDocument2* This,LONG *pCount) {
    return This->lpVtbl->Unfreeze(This,pCount);
}
static FORCEINLINE HRESULT ITextDocument2_BeginEditCollection(ITextDocument2* This) {
    return This->lpVtbl->BeginEditCollection(This);
}
static FORCEINLINE HRESULT ITextDocument2_EndEditCollection(ITextDocument2* This) {
    return This->lpVtbl->EndEditCollection(This);
}
static FORCEINLINE HRESULT ITextDocument2_Undo(ITextDocument2* This,LONG Count,LONG *prop) {
    return This->lpVtbl->Undo(This,Count,prop);
}
static FORCEINLINE HRESULT ITextDocument2_Redo(ITextDocument2* This,LONG Count,LONG *prop) {
    return This->lpVtbl->Redo(This,Count,prop);
}
static FORCEINLINE HRESULT ITextDocument2_Range(ITextDocument2* This,LONG cp1,LONG cp2,ITextRange **ppRange) {
    return This->lpVtbl->Range(This,cp1,cp2,ppRange);
}
static FORCEINLINE HRESULT ITextDocument2_RangeFromPoint(ITextDocument2* This,LONG x,LONG y,ITextRange **ppRange) {
    return This->lpVtbl->RangeFromPoint(This,x,y,ppRange);
}
/*** ITextDocument2 methods ***/
static FORCEINLINE HRESULT ITextDocument2_GetCaretType(ITextDocument2* This,LONG *value) {
    return This->lpVtbl->GetCaretType(This,value);
}
static FORCEINLINE HRESULT ITextDocument2_SetCaretType(ITextDocument2* This,LONG value) {
    return This->lpVtbl->SetCaretType(This,value);
}
static FORCEINLINE HRESULT ITextDocument2_GetDisplays(ITextDocument2* This,ITextDisplays **displays) {
    return This->lpVtbl->GetDisplays(This,displays);
}
static FORCEINLINE HRESULT ITextDocument2_GetDocumentFont(ITextDocument2* This,ITextFont2 **font) {
    return This->lpVtbl->GetDocumentFont(This,font);
}
static FORCEINLINE HRESULT ITextDocument2_SetDocumentFont(ITextDocument2* This,ITextFont2 *font) {
    return This->lpVtbl->SetDocumentFont(This,font);
}
static FORCEINLINE HRESULT ITextDocument2_GetDocumentPara(ITextDocument2* This,ITextPara2 **para) {
    return This->lpVtbl->GetDocumentPara(This,para);
}
static FORCEINLINE HRESULT ITextDocument2_SetDocumentPara(ITextDocument2* This,ITextPara2 *para) {
    return This->lpVtbl->SetDocumentPara(This,para);
}
static FORCEINLINE HRESULT ITextDocument2_GetEastAsianFlags(ITextDocument2* This,LONG *flags) {
    return This->lpVtbl->GetEastAsianFlags(This,flags);
}
static FORCEINLINE HRESULT ITextDocument2_GetGenerator(ITextDocument2* This,BSTR *bstr) {
    return This->lpVtbl->GetGenerator(This,bstr);
}
static FORCEINLINE HRESULT ITextDocument2_SetIMEInProgress(ITextDocument2* This,LONG value) {
    return This->lpVtbl->SetIMEInProgress(This,value);
}
static FORCEINLINE HRESULT ITextDocument2_GetNotificationMode(ITextDocument2* This,LONG *mode) {
    return This->lpVtbl->GetNotificationMode(This,mode);
}
static FORCEINLINE HRESULT ITextDocument2_SetNotificationMode(ITextDocument2* This,LONG mode) {
    return This->lpVtbl->SetNotificationMode(This,mode);
}
static FORCEINLINE HRESULT ITextDocument2_GetSelection2(ITextDocument2* This,ITextSelection2 **selection) {
    return This->lpVtbl->GetSelection2(This,selection);
}
static FORCEINLINE HRESULT ITextDocument2_GetStoryRanges2(ITextDocument2* This,ITextStoryRanges2 **stories) {
    return This->lpVtbl->GetStoryRanges2(This,stories);
}
static FORCEINLINE HRESULT ITextDocument2_GetTypographyOptions(ITextDocument2* This,LONG *options) {
    return This->lpVtbl->GetTypographyOptions(This,options);
}
static FORCEINLINE HRESULT ITextDocument2_GetVersion(ITextDocument2* This,LONG *value) {
    return This->lpVtbl->GetVersion(This,value);
}
static FORCEINLINE HRESULT ITextDocument2_GetWindow(ITextDocument2* This,LONG *hwnd) {
    return This->lpVtbl->GetWindow(This,hwnd);
}
static FORCEINLINE HRESULT ITextDocument2_AttachMsgFilter(ITextDocument2* This,IUnknown *filter) {
    return This->lpVtbl->AttachMsgFilter(This,filter);
}
static FORCEINLINE HRESULT ITextDocument2_CheckTextLimit(ITextDocument2* This,LONG cch,LONG *exceed) {
    return This->lpVtbl->CheckTextLimit(This,cch,exceed);
}
static FORCEINLINE HRESULT ITextDocument2_GetCallManager(ITextDocument2* This,IUnknown **manager) {
    return This->lpVtbl->GetCallManager(This,manager);
}
static FORCEINLINE HRESULT ITextDocument2_GetClientRect(ITextDocument2* This,LONG type,LONG *left,LONG *top,LONG *right,LONG *bottom) {
    return This->lpVtbl->GetClientRect(This,type,left,top,right,bottom);
}
static FORCEINLINE HRESULT ITextDocument2_GetEffectColor(ITextDocument2* This,LONG index,COLORREF *cr) {
    return This->lpVtbl->GetEffectColor(This,index,cr);
}
static FORCEINLINE HRESULT ITextDocument2_GetImmContext(ITextDocument2* This,LONG *context) {
    return This->lpVtbl->GetImmContext(This,context);
}
static FORCEINLINE HRESULT ITextDocument2_GetPreferredFont(ITextDocument2* This,LONG cp,LONG codepage,LONG option,LONG current_codepage,LONG current_fontsize,BSTR *bstr,LONG *pitch_family,LONG *new_fontsize) {
    return This->lpVtbl->GetPreferredFont(This,cp,codepage,option,current_codepage,current_fontsize,bstr,pitch_family,new_fontsize);
}
static FORCEINLINE HRESULT ITextDocument2_GetProperty(ITextDocument2* This,LONG type,LONG *value) {
    return This->lpVtbl->GetProperty(This,type,value);
}
static FORCEINLINE HRESULT ITextDocument2_GetStrings(ITextDocument2* This,ITextStrings **strings) {
    return This->lpVtbl->GetStrings(This,strings);
}
static FORCEINLINE HRESULT ITextDocument2_Notify(ITextDocument2* This,LONG notify) {
    return This->lpVtbl->Notify(This,notify);
}
static FORCEINLINE HRESULT ITextDocument2_Range2(ITextDocument2* This,LONG cp_active,LONG cp_anchor,ITextRange2 **range) {
    return This->lpVtbl->Range2(This,cp_active,cp_anchor,range);
}
static FORCEINLINE HRESULT ITextDocument2_RangeFromPoint2(ITextDocument2* This,LONG x,LONG y,LONG type,ITextRange2 **range) {
    return This->lpVtbl->RangeFromPoint2(This,x,y,type,range);
}
static FORCEINLINE HRESULT ITextDocument2_ReleaseCallManager(ITextDocument2* This,IUnknown *manager) {
    return This->lpVtbl->ReleaseCallManager(This,manager);
}
static FORCEINLINE HRESULT ITextDocument2_ReleaseImmContext(ITextDocument2* This,LONG context) {
    return This->lpVtbl->ReleaseImmContext(This,context);
}
static FORCEINLINE HRESULT ITextDocument2_SetEffectColor(ITextDocument2* This,LONG index,LONG value) {
    return This->lpVtbl->SetEffectColor(This,index,value);
}
static FORCEINLINE HRESULT ITextDocument2_SetProperty(ITextDocument2* This,LONG type,LONG value) {
    return This->lpVtbl->SetProperty(This,type,value);
}
static FORCEINLINE HRESULT ITextDocument2_SetTypographyOptions(ITextDocument2* This,LONG options,LONG mask) {
    return This->lpVtbl->SetTypographyOptions(This,options,mask);
}
static FORCEINLINE HRESULT ITextDocument2_SysBeep(ITextDocument2* This) {
    return This->lpVtbl->SysBeep(This);
}
static FORCEINLINE HRESULT ITextDocument2_Update(ITextDocument2* This,LONG value) {
    return This->lpVtbl->Update(This,value);
}
static FORCEINLINE HRESULT ITextDocument2_UpdateWindow(ITextDocument2* This) {
    return This->lpVtbl->UpdateWindow(This);
}
static FORCEINLINE HRESULT ITextDocument2_GetMathProperties(ITextDocument2* This,LONG *options) {
    return This->lpVtbl->GetMathProperties(This,options);
}
static FORCEINLINE HRESULT ITextDocument2_SetMathProperties(ITextDocument2* This,LONG options,LONG mask) {
    return This->lpVtbl->SetMathProperties(This,options,mask);
}
static FORCEINLINE HRESULT ITextDocument2_GetActiveStory(ITextDocument2* This,ITextStory **story) {
    return This->lpVtbl->GetActiveStory(This,story);
}
static FORCEINLINE HRESULT ITextDocument2_SetActiveStory(ITextDocument2* This,ITextStory *story) {
    return This->lpVtbl->SetActiveStory(This,story);
}
static FORCEINLINE HRESULT ITextDocument2_GetMainStory(ITextDocument2* This,ITextStory **story) {
    return This->lpVtbl->GetMainStory(This,story);
}
static FORCEINLINE HRESULT ITextDocument2_GetNewStory(ITextDocument2* This,ITextStory **story) {
    return This->lpVtbl->GetNewStory(This,story);
}
static FORCEINLINE HRESULT ITextDocument2_GetStory(ITextDocument2* This,LONG index,ITextStory **story) {
    return This->lpVtbl->GetStory(This,index,story);
}
#endif
#endif

#endif


#endif  /* __ITextDocument2_INTERFACE_DEFINED__ */

#ifndef __ITextFont_FWD_DEFINED__
#define __ITextFont_FWD_DEFINED__
typedef interface ITextFont ITextFont;
#ifdef __cplusplus
interface ITextFont;
#endif /* __cplusplus */
#endif

#ifndef __ITextPara_FWD_DEFINED__
#define __ITextPara_FWD_DEFINED__
typedef interface ITextPara ITextPara;
#ifdef __cplusplus
interface ITextPara;
#endif /* __cplusplus */
#endif

/*****************************************************************************
 * ITextRange interface
 */
#ifndef __ITextRange_INTERFACE_DEFINED__
#define __ITextRange_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextRange, 0x8cc497c2, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("8cc497c2-a1df-11ce-8098-00aa0047be5d")
ITextRange : public IDispatch
{
    virtual HRESULT STDMETHODCALLTYPE GetText(
        BSTR *pbstr) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetText(
        BSTR bstr) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetChar(
        LONG *pch) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetChar(
        LONG ch) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetDuplicate(
        ITextRange **ppRange) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetFormattedText(
        ITextRange **ppRange) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetFormattedText(
        ITextRange *pRange) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStart(
        LONG *pcpFirst) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetStart(
        LONG cpFirst) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEnd(
        LONG *pcpLim) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetEnd(
        LONG cpLim) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetFont(
        ITextFont **pFont) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetFont(
        ITextFont *pFont) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetPara(
        ITextPara **ppPara) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetPara(
        ITextPara *pPara) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStoryLength(
        LONG *pcch) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStoryType(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE Collapse(
        LONG bStart) = 0;

    virtual HRESULT STDMETHODCALLTYPE Expand(
        LONG Unit,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetIndex(
        LONG Unit,
        LONG *pIndex) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetIndex(
        LONG Unit,
        LONG Index,
        LONG Extend) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetRange(
        LONG anchor,
        LONG active) = 0;

    virtual HRESULT STDMETHODCALLTYPE InRange(
        ITextRange *pRange,
        LONG *pb) = 0;

    virtual HRESULT STDMETHODCALLTYPE InStory(
        ITextRange *pRange,
        LONG *pb) = 0;

    virtual HRESULT STDMETHODCALLTYPE IsEqual(
        ITextRange *pRange,
        LONG *pb) = 0;

    virtual HRESULT STDMETHODCALLTYPE Select(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE StartOf(
        LONG Unit,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE EndOf(
        LONG Unit,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE Move(
        LONG Unit,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveStart(
        LONG Unit,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveEnd(
        LONG Unit,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveWhile(
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveStartWhile(
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveEndWhile(
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveUntil(
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveStartUntil(
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveEndUntil(
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE FindText(
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength) = 0;

    virtual HRESULT STDMETHODCALLTYPE FindTextStart(
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength) = 0;

    virtual HRESULT STDMETHODCALLTYPE FindTextEnd(
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength) = 0;

    virtual HRESULT STDMETHODCALLTYPE Delete(
        LONG Unit,
        LONG Count,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE Cut(
        VARIANT *pVar) = 0;

    virtual HRESULT STDMETHODCALLTYPE Copy(
        VARIANT *pVar) = 0;

    virtual HRESULT STDMETHODCALLTYPE Paste(
        VARIANT *pVar,
        LONG Format) = 0;

    virtual HRESULT STDMETHODCALLTYPE CanPaste(
        VARIANT *pVar,
        LONG Format,
        LONG *pb) = 0;

    virtual HRESULT STDMETHODCALLTYPE CanEdit(
        LONG *pb) = 0;

    virtual HRESULT STDMETHODCALLTYPE ChangeCase(
        LONG Type) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetPoint(
        LONG Type,
        LONG *cx,
        LONG *cy) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetPoint(
        LONG x,
        LONG y,
        LONG Type,
        LONG Extend) = 0;

    virtual HRESULT STDMETHODCALLTYPE ScrollIntoView(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEmbeddedObject(
        IUnknown **ppv) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextRange, 0x8cc497c2, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d)
#endif
#else
typedef struct ITextRangeVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextRange *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextRange *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextRange *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextRange *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextRange *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextRange *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextRange *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextRange methods ***/
    HRESULT (STDMETHODCALLTYPE *GetText)(
        ITextRange *This,
        BSTR *pbstr);

    HRESULT (STDMETHODCALLTYPE *SetText)(
        ITextRange *This,
        BSTR bstr);

    HRESULT (STDMETHODCALLTYPE *GetChar)(
        ITextRange *This,
        LONG *pch);

    HRESULT (STDMETHODCALLTYPE *SetChar)(
        ITextRange *This,
        LONG ch);

    HRESULT (STDMETHODCALLTYPE *GetDuplicate)(
        ITextRange *This,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *GetFormattedText)(
        ITextRange *This,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *SetFormattedText)(
        ITextRange *This,
        ITextRange *pRange);

    HRESULT (STDMETHODCALLTYPE *GetStart)(
        ITextRange *This,
        LONG *pcpFirst);

    HRESULT (STDMETHODCALLTYPE *SetStart)(
        ITextRange *This,
        LONG cpFirst);

    HRESULT (STDMETHODCALLTYPE *GetEnd)(
        ITextRange *This,
        LONG *pcpLim);

    HRESULT (STDMETHODCALLTYPE *SetEnd)(
        ITextRange *This,
        LONG cpLim);

    HRESULT (STDMETHODCALLTYPE *GetFont)(
        ITextRange *This,
        ITextFont **pFont);

    HRESULT (STDMETHODCALLTYPE *SetFont)(
        ITextRange *This,
        ITextFont *pFont);

    HRESULT (STDMETHODCALLTYPE *GetPara)(
        ITextRange *This,
        ITextPara **ppPara);

    HRESULT (STDMETHODCALLTYPE *SetPara)(
        ITextRange *This,
        ITextPara *pPara);

    HRESULT (STDMETHODCALLTYPE *GetStoryLength)(
        ITextRange *This,
        LONG *pcch);

    HRESULT (STDMETHODCALLTYPE *GetStoryType)(
        ITextRange *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *Collapse)(
        ITextRange *This,
        LONG bStart);

    HRESULT (STDMETHODCALLTYPE *Expand)(
        ITextRange *This,
        LONG Unit,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *GetIndex)(
        ITextRange *This,
        LONG Unit,
        LONG *pIndex);

    HRESULT (STDMETHODCALLTYPE *SetIndex)(
        ITextRange *This,
        LONG Unit,
        LONG Index,
        LONG Extend);

    HRESULT (STDMETHODCALLTYPE *SetRange)(
        ITextRange *This,
        LONG anchor,
        LONG active);

    HRESULT (STDMETHODCALLTYPE *InRange)(
        ITextRange *This,
        ITextRange *pRange,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *InStory)(
        ITextRange *This,
        ITextRange *pRange,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *IsEqual)(
        ITextRange *This,
        ITextRange *pRange,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *Select)(
        ITextRange *This);

    HRESULT (STDMETHODCALLTYPE *StartOf)(
        ITextRange *This,
        LONG Unit,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *EndOf)(
        ITextRange *This,
        LONG Unit,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *Move)(
        ITextRange *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveStart)(
        ITextRange *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveEnd)(
        ITextRange *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveWhile)(
        ITextRange *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveStartWhile)(
        ITextRange *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveEndWhile)(
        ITextRange *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveUntil)(
        ITextRange *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveStartUntil)(
        ITextRange *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveEndUntil)(
        ITextRange *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *FindText)(
        ITextRange *This,
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength);

    HRESULT (STDMETHODCALLTYPE *FindTextStart)(
        ITextRange *This,
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength);

    HRESULT (STDMETHODCALLTYPE *FindTextEnd)(
        ITextRange *This,
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength);

    HRESULT (STDMETHODCALLTYPE *Delete)(
        ITextRange *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *Cut)(
        ITextRange *This,
        VARIANT *pVar);

    HRESULT (STDMETHODCALLTYPE *Copy)(
        ITextRange *This,
        VARIANT *pVar);

    HRESULT (STDMETHODCALLTYPE *Paste)(
        ITextRange *This,
        VARIANT *pVar,
        LONG Format);

    HRESULT (STDMETHODCALLTYPE *CanPaste)(
        ITextRange *This,
        VARIANT *pVar,
        LONG Format,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *CanEdit)(
        ITextRange *This,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *ChangeCase)(
        ITextRange *This,
        LONG Type);

    HRESULT (STDMETHODCALLTYPE *GetPoint)(
        ITextRange *This,
        LONG Type,
        LONG *cx,
        LONG *cy);

    HRESULT (STDMETHODCALLTYPE *SetPoint)(
        ITextRange *This,
        LONG x,
        LONG y,
        LONG Type,
        LONG Extend);

    HRESULT (STDMETHODCALLTYPE *ScrollIntoView)(
        ITextRange *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetEmbeddedObject)(
        ITextRange *This,
        IUnknown **ppv);

    END_INTERFACE
} ITextRangeVtbl;

interface ITextRange {
    CONST_VTBL ITextRangeVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextRange_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextRange_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextRange_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextRange_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextRange_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextRange_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextRange_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextRange methods ***/
#define ITextRange_GetText(This,pbstr) (This)->lpVtbl->GetText(This,pbstr)
#define ITextRange_SetText(This,bstr) (This)->lpVtbl->SetText(This,bstr)
#define ITextRange_GetChar(This,pch) (This)->lpVtbl->GetChar(This,pch)
#define ITextRange_SetChar(This,ch) (This)->lpVtbl->SetChar(This,ch)
#define ITextRange_GetDuplicate(This,ppRange) (This)->lpVtbl->GetDuplicate(This,ppRange)
#define ITextRange_GetFormattedText(This,ppRange) (This)->lpVtbl->GetFormattedText(This,ppRange)
#define ITextRange_SetFormattedText(This,pRange) (This)->lpVtbl->SetFormattedText(This,pRange)
#define ITextRange_GetStart(This,pcpFirst) (This)->lpVtbl->GetStart(This,pcpFirst)
#define ITextRange_SetStart(This,cpFirst) (This)->lpVtbl->SetStart(This,cpFirst)
#define ITextRange_GetEnd(This,pcpLim) (This)->lpVtbl->GetEnd(This,pcpLim)
#define ITextRange_SetEnd(This,cpLim) (This)->lpVtbl->SetEnd(This,cpLim)
#define ITextRange_GetFont(This,pFont) (This)->lpVtbl->GetFont(This,pFont)
#define ITextRange_SetFont(This,pFont) (This)->lpVtbl->SetFont(This,pFont)
#define ITextRange_GetPara(This,ppPara) (This)->lpVtbl->GetPara(This,ppPara)
#define ITextRange_SetPara(This,pPara) (This)->lpVtbl->SetPara(This,pPara)
#define ITextRange_GetStoryLength(This,pcch) (This)->lpVtbl->GetStoryLength(This,pcch)
#define ITextRange_GetStoryType(This,pValue) (This)->lpVtbl->GetStoryType(This,pValue)
#define ITextRange_Collapse(This,bStart) (This)->lpVtbl->Collapse(This,bStart)
#define ITextRange_Expand(This,Unit,pDelta) (This)->lpVtbl->Expand(This,Unit,pDelta)
#define ITextRange_GetIndex(This,Unit,pIndex) (This)->lpVtbl->GetIndex(This,Unit,pIndex)
#define ITextRange_SetIndex(This,Unit,Index,Extend) (This)->lpVtbl->SetIndex(This,Unit,Index,Extend)
#define ITextRange_SetRange(This,anchor,active) (This)->lpVtbl->SetRange(This,anchor,active)
#define ITextRange_InRange(This,pRange,pb) (This)->lpVtbl->InRange(This,pRange,pb)
#define ITextRange_InStory(This,pRange,pb) (This)->lpVtbl->InStory(This,pRange,pb)
#define ITextRange_IsEqual(This,pRange,pb) (This)->lpVtbl->IsEqual(This,pRange,pb)
#define ITextRange_Select(This) (This)->lpVtbl->Select(This)
#define ITextRange_StartOf(This,Unit,Extend,pDelta) (This)->lpVtbl->StartOf(This,Unit,Extend,pDelta)
#define ITextRange_EndOf(This,Unit,Extend,pDelta) (This)->lpVtbl->EndOf(This,Unit,Extend,pDelta)
#define ITextRange_Move(This,Unit,Count,pDelta) (This)->lpVtbl->Move(This,Unit,Count,pDelta)
#define ITextRange_MoveStart(This,Unit,Count,pDelta) (This)->lpVtbl->MoveStart(This,Unit,Count,pDelta)
#define ITextRange_MoveEnd(This,Unit,Count,pDelta) (This)->lpVtbl->MoveEnd(This,Unit,Count,pDelta)
#define ITextRange_MoveWhile(This,Cset,Count,pDelta) (This)->lpVtbl->MoveWhile(This,Cset,Count,pDelta)
#define ITextRange_MoveStartWhile(This,Cset,Count,pDelta) (This)->lpVtbl->MoveStartWhile(This,Cset,Count,pDelta)
#define ITextRange_MoveEndWhile(This,Cset,Count,pDelta) (This)->lpVtbl->MoveEndWhile(This,Cset,Count,pDelta)
#define ITextRange_MoveUntil(This,Cset,Count,pDelta) (This)->lpVtbl->MoveUntil(This,Cset,Count,pDelta)
#define ITextRange_MoveStartUntil(This,Cset,Count,pDelta) (This)->lpVtbl->MoveStartUntil(This,Cset,Count,pDelta)
#define ITextRange_MoveEndUntil(This,Cset,Count,pDelta) (This)->lpVtbl->MoveEndUntil(This,Cset,Count,pDelta)
#define ITextRange_FindText(This,bstr,cch,Flags,pLength) (This)->lpVtbl->FindText(This,bstr,cch,Flags,pLength)
#define ITextRange_FindTextStart(This,bstr,cch,Flags,pLength) (This)->lpVtbl->FindTextStart(This,bstr,cch,Flags,pLength)
#define ITextRange_FindTextEnd(This,bstr,cch,Flags,pLength) (This)->lpVtbl->FindTextEnd(This,bstr,cch,Flags,pLength)
#define ITextRange_Delete(This,Unit,Count,pDelta) (This)->lpVtbl->Delete(This,Unit,Count,pDelta)
#define ITextRange_Cut(This,pVar) (This)->lpVtbl->Cut(This,pVar)
#define ITextRange_Copy(This,pVar) (This)->lpVtbl->Copy(This,pVar)
#define ITextRange_Paste(This,pVar,Format) (This)->lpVtbl->Paste(This,pVar,Format)
#define ITextRange_CanPaste(This,pVar,Format,pb) (This)->lpVtbl->CanPaste(This,pVar,Format,pb)
#define ITextRange_CanEdit(This,pb) (This)->lpVtbl->CanEdit(This,pb)
#define ITextRange_ChangeCase(This,Type) (This)->lpVtbl->ChangeCase(This,Type)
#define ITextRange_GetPoint(This,Type,cx,cy) (This)->lpVtbl->GetPoint(This,Type,cx,cy)
#define ITextRange_SetPoint(This,x,y,Type,Extend) (This)->lpVtbl->SetPoint(This,x,y,Type,Extend)
#define ITextRange_ScrollIntoView(This,Value) (This)->lpVtbl->ScrollIntoView(This,Value)
#define ITextRange_GetEmbeddedObject(This,ppv) (This)->lpVtbl->GetEmbeddedObject(This,ppv)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextRange_QueryInterface(ITextRange* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextRange_AddRef(ITextRange* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextRange_Release(ITextRange* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextRange_GetTypeInfoCount(ITextRange* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextRange_GetTypeInfo(ITextRange* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextRange_GetIDsOfNames(ITextRange* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextRange_Invoke(ITextRange* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextRange methods ***/
static FORCEINLINE HRESULT ITextRange_GetText(ITextRange* This,BSTR *pbstr) {
    return This->lpVtbl->GetText(This,pbstr);
}
static FORCEINLINE HRESULT ITextRange_SetText(ITextRange* This,BSTR bstr) {
    return This->lpVtbl->SetText(This,bstr);
}
static FORCEINLINE HRESULT ITextRange_GetChar(ITextRange* This,LONG *pch) {
    return This->lpVtbl->GetChar(This,pch);
}
static FORCEINLINE HRESULT ITextRange_SetChar(ITextRange* This,LONG ch) {
    return This->lpVtbl->SetChar(This,ch);
}
static FORCEINLINE HRESULT ITextRange_GetDuplicate(ITextRange* This,ITextRange **ppRange) {
    return This->lpVtbl->GetDuplicate(This,ppRange);
}
static FORCEINLINE HRESULT ITextRange_GetFormattedText(ITextRange* This,ITextRange **ppRange) {
    return This->lpVtbl->GetFormattedText(This,ppRange);
}
static FORCEINLINE HRESULT ITextRange_SetFormattedText(ITextRange* This,ITextRange *pRange) {
    return This->lpVtbl->SetFormattedText(This,pRange);
}
static FORCEINLINE HRESULT ITextRange_GetStart(ITextRange* This,LONG *pcpFirst) {
    return This->lpVtbl->GetStart(This,pcpFirst);
}
static FORCEINLINE HRESULT ITextRange_SetStart(ITextRange* This,LONG cpFirst) {
    return This->lpVtbl->SetStart(This,cpFirst);
}
static FORCEINLINE HRESULT ITextRange_GetEnd(ITextRange* This,LONG *pcpLim) {
    return This->lpVtbl->GetEnd(This,pcpLim);
}
static FORCEINLINE HRESULT ITextRange_SetEnd(ITextRange* This,LONG cpLim) {
    return This->lpVtbl->SetEnd(This,cpLim);
}
static FORCEINLINE HRESULT ITextRange_GetFont(ITextRange* This,ITextFont **pFont) {
    return This->lpVtbl->GetFont(This,pFont);
}
static FORCEINLINE HRESULT ITextRange_SetFont(ITextRange* This,ITextFont *pFont) {
    return This->lpVtbl->SetFont(This,pFont);
}
static FORCEINLINE HRESULT ITextRange_GetPara(ITextRange* This,ITextPara **ppPara) {
    return This->lpVtbl->GetPara(This,ppPara);
}
static FORCEINLINE HRESULT ITextRange_SetPara(ITextRange* This,ITextPara *pPara) {
    return This->lpVtbl->SetPara(This,pPara);
}
static FORCEINLINE HRESULT ITextRange_GetStoryLength(ITextRange* This,LONG *pcch) {
    return This->lpVtbl->GetStoryLength(This,pcch);
}
static FORCEINLINE HRESULT ITextRange_GetStoryType(ITextRange* This,LONG *pValue) {
    return This->lpVtbl->GetStoryType(This,pValue);
}
static FORCEINLINE HRESULT ITextRange_Collapse(ITextRange* This,LONG bStart) {
    return This->lpVtbl->Collapse(This,bStart);
}
static FORCEINLINE HRESULT ITextRange_Expand(ITextRange* This,LONG Unit,LONG *pDelta) {
    return This->lpVtbl->Expand(This,Unit,pDelta);
}
static FORCEINLINE HRESULT ITextRange_GetIndex(ITextRange* This,LONG Unit,LONG *pIndex) {
    return This->lpVtbl->GetIndex(This,Unit,pIndex);
}
static FORCEINLINE HRESULT ITextRange_SetIndex(ITextRange* This,LONG Unit,LONG Index,LONG Extend) {
    return This->lpVtbl->SetIndex(This,Unit,Index,Extend);
}
static FORCEINLINE HRESULT ITextRange_SetRange(ITextRange* This,LONG anchor,LONG active) {
    return This->lpVtbl->SetRange(This,anchor,active);
}
static FORCEINLINE HRESULT ITextRange_InRange(ITextRange* This,ITextRange *pRange,LONG *pb) {
    return This->lpVtbl->InRange(This,pRange,pb);
}
static FORCEINLINE HRESULT ITextRange_InStory(ITextRange* This,ITextRange *pRange,LONG *pb) {
    return This->lpVtbl->InStory(This,pRange,pb);
}
static FORCEINLINE HRESULT ITextRange_IsEqual(ITextRange* This,ITextRange *pRange,LONG *pb) {
    return This->lpVtbl->IsEqual(This,pRange,pb);
}
static FORCEINLINE HRESULT ITextRange_Select(ITextRange* This) {
    return This->lpVtbl->Select(This);
}
static FORCEINLINE HRESULT ITextRange_StartOf(ITextRange* This,LONG Unit,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->StartOf(This,Unit,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextRange_EndOf(ITextRange* This,LONG Unit,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->EndOf(This,Unit,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextRange_Move(ITextRange* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->Move(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveStart(ITextRange* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveStart(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveEnd(ITextRange* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveEnd(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveWhile(ITextRange* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveWhile(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveStartWhile(ITextRange* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveStartWhile(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveEndWhile(ITextRange* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveEndWhile(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveUntil(ITextRange* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveUntil(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveStartUntil(ITextRange* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveStartUntil(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_MoveEndUntil(ITextRange* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveEndUntil(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_FindText(ITextRange* This,BSTR bstr,LONG cch,LONG Flags,LONG *pLength) {
    return This->lpVtbl->FindText(This,bstr,cch,Flags,pLength);
}
static FORCEINLINE HRESULT ITextRange_FindTextStart(ITextRange* This,BSTR bstr,LONG cch,LONG Flags,LONG *pLength) {
    return This->lpVtbl->FindTextStart(This,bstr,cch,Flags,pLength);
}
static FORCEINLINE HRESULT ITextRange_FindTextEnd(ITextRange* This,BSTR bstr,LONG cch,LONG Flags,LONG *pLength) {
    return This->lpVtbl->FindTextEnd(This,bstr,cch,Flags,pLength);
}
static FORCEINLINE HRESULT ITextRange_Delete(ITextRange* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->Delete(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextRange_Cut(ITextRange* This,VARIANT *pVar) {
    return This->lpVtbl->Cut(This,pVar);
}
static FORCEINLINE HRESULT ITextRange_Copy(ITextRange* This,VARIANT *pVar) {
    return This->lpVtbl->Copy(This,pVar);
}
static FORCEINLINE HRESULT ITextRange_Paste(ITextRange* This,VARIANT *pVar,LONG Format) {
    return This->lpVtbl->Paste(This,pVar,Format);
}
static FORCEINLINE HRESULT ITextRange_CanPaste(ITextRange* This,VARIANT *pVar,LONG Format,LONG *pb) {
    return This->lpVtbl->CanPaste(This,pVar,Format,pb);
}
static FORCEINLINE HRESULT ITextRange_CanEdit(ITextRange* This,LONG *pb) {
    return This->lpVtbl->CanEdit(This,pb);
}
static FORCEINLINE HRESULT ITextRange_ChangeCase(ITextRange* This,LONG Type) {
    return This->lpVtbl->ChangeCase(This,Type);
}
static FORCEINLINE HRESULT ITextRange_GetPoint(ITextRange* This,LONG Type,LONG *cx,LONG *cy) {
    return This->lpVtbl->GetPoint(This,Type,cx,cy);
}
static FORCEINLINE HRESULT ITextRange_SetPoint(ITextRange* This,LONG x,LONG y,LONG Type,LONG Extend) {
    return This->lpVtbl->SetPoint(This,x,y,Type,Extend);
}
static FORCEINLINE HRESULT ITextRange_ScrollIntoView(ITextRange* This,LONG Value) {
    return This->lpVtbl->ScrollIntoView(This,Value);
}
static FORCEINLINE HRESULT ITextRange_GetEmbeddedObject(ITextRange* This,IUnknown **ppv) {
    return This->lpVtbl->GetEmbeddedObject(This,ppv);
}
#endif
#endif

#endif


#endif  /* __ITextRange_INTERFACE_DEFINED__ */

/*****************************************************************************
 * ITextSelection interface
 */
#ifndef __ITextSelection_INTERFACE_DEFINED__
#define __ITextSelection_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextSelection, 0x8cc497c1, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("8cc497c1-a1df-11ce-8098-00aa0047be5d")
ITextSelection : public ITextRange
{
    virtual HRESULT STDMETHODCALLTYPE GetFlags(
        LONG *pFlags) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetFlags(
        LONG Flags) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetType(
        LONG *pType) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveLeft(
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveRight(
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveUp(
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE MoveDown(
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE HomeKey(
        LONG Unit,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE EndKey(
        LONG Unit,
        LONG Extend,
        LONG *pDelta) = 0;

    virtual HRESULT STDMETHODCALLTYPE TypeText(
        BSTR bstr) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextSelection, 0x8cc497c1, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d)
#endif
#else
typedef struct ITextSelectionVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextSelection *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextSelection *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextSelection *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextSelection *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextSelection *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextSelection *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextSelection *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextRange methods ***/
    HRESULT (STDMETHODCALLTYPE *GetText)(
        ITextSelection *This,
        BSTR *pbstr);

    HRESULT (STDMETHODCALLTYPE *SetText)(
        ITextSelection *This,
        BSTR bstr);

    HRESULT (STDMETHODCALLTYPE *GetChar)(
        ITextSelection *This,
        LONG *pch);

    HRESULT (STDMETHODCALLTYPE *SetChar)(
        ITextSelection *This,
        LONG ch);

    HRESULT (STDMETHODCALLTYPE *GetDuplicate)(
        ITextSelection *This,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *GetFormattedText)(
        ITextSelection *This,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *SetFormattedText)(
        ITextSelection *This,
        ITextRange *pRange);

    HRESULT (STDMETHODCALLTYPE *GetStart)(
        ITextSelection *This,
        LONG *pcpFirst);

    HRESULT (STDMETHODCALLTYPE *SetStart)(
        ITextSelection *This,
        LONG cpFirst);

    HRESULT (STDMETHODCALLTYPE *GetEnd)(
        ITextSelection *This,
        LONG *pcpLim);

    HRESULT (STDMETHODCALLTYPE *SetEnd)(
        ITextSelection *This,
        LONG cpLim);

    HRESULT (STDMETHODCALLTYPE *GetFont)(
        ITextSelection *This,
        ITextFont **pFont);

    HRESULT (STDMETHODCALLTYPE *SetFont)(
        ITextSelection *This,
        ITextFont *pFont);

    HRESULT (STDMETHODCALLTYPE *GetPara)(
        ITextSelection *This,
        ITextPara **ppPara);

    HRESULT (STDMETHODCALLTYPE *SetPara)(
        ITextSelection *This,
        ITextPara *pPara);

    HRESULT (STDMETHODCALLTYPE *GetStoryLength)(
        ITextSelection *This,
        LONG *pcch);

    HRESULT (STDMETHODCALLTYPE *GetStoryType)(
        ITextSelection *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *Collapse)(
        ITextSelection *This,
        LONG bStart);

    HRESULT (STDMETHODCALLTYPE *Expand)(
        ITextSelection *This,
        LONG Unit,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *GetIndex)(
        ITextSelection *This,
        LONG Unit,
        LONG *pIndex);

    HRESULT (STDMETHODCALLTYPE *SetIndex)(
        ITextSelection *This,
        LONG Unit,
        LONG Index,
        LONG Extend);

    HRESULT (STDMETHODCALLTYPE *SetRange)(
        ITextSelection *This,
        LONG anchor,
        LONG active);

    HRESULT (STDMETHODCALLTYPE *InRange)(
        ITextSelection *This,
        ITextRange *pRange,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *InStory)(
        ITextSelection *This,
        ITextRange *pRange,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *IsEqual)(
        ITextSelection *This,
        ITextRange *pRange,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *Select)(
        ITextSelection *This);

    HRESULT (STDMETHODCALLTYPE *StartOf)(
        ITextSelection *This,
        LONG Unit,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *EndOf)(
        ITextSelection *This,
        LONG Unit,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *Move)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveStart)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveEnd)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveWhile)(
        ITextSelection *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveStartWhile)(
        ITextSelection *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveEndWhile)(
        ITextSelection *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveUntil)(
        ITextSelection *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveStartUntil)(
        ITextSelection *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveEndUntil)(
        ITextSelection *This,
        VARIANT *Cset,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *FindText)(
        ITextSelection *This,
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength);

    HRESULT (STDMETHODCALLTYPE *FindTextStart)(
        ITextSelection *This,
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength);

    HRESULT (STDMETHODCALLTYPE *FindTextEnd)(
        ITextSelection *This,
        BSTR bstr,
        LONG cch,
        LONG Flags,
        LONG *pLength);

    HRESULT (STDMETHODCALLTYPE *Delete)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *Cut)(
        ITextSelection *This,
        VARIANT *pVar);

    HRESULT (STDMETHODCALLTYPE *Copy)(
        ITextSelection *This,
        VARIANT *pVar);

    HRESULT (STDMETHODCALLTYPE *Paste)(
        ITextSelection *This,
        VARIANT *pVar,
        LONG Format);

    HRESULT (STDMETHODCALLTYPE *CanPaste)(
        ITextSelection *This,
        VARIANT *pVar,
        LONG Format,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *CanEdit)(
        ITextSelection *This,
        LONG *pb);

    HRESULT (STDMETHODCALLTYPE *ChangeCase)(
        ITextSelection *This,
        LONG Type);

    HRESULT (STDMETHODCALLTYPE *GetPoint)(
        ITextSelection *This,
        LONG Type,
        LONG *cx,
        LONG *cy);

    HRESULT (STDMETHODCALLTYPE *SetPoint)(
        ITextSelection *This,
        LONG x,
        LONG y,
        LONG Type,
        LONG Extend);

    HRESULT (STDMETHODCALLTYPE *ScrollIntoView)(
        ITextSelection *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetEmbeddedObject)(
        ITextSelection *This,
        IUnknown **ppv);

    /*** ITextSelection methods ***/
    HRESULT (STDMETHODCALLTYPE *GetFlags)(
        ITextSelection *This,
        LONG *pFlags);

    HRESULT (STDMETHODCALLTYPE *SetFlags)(
        ITextSelection *This,
        LONG Flags);

    HRESULT (STDMETHODCALLTYPE *GetType)(
        ITextSelection *This,
        LONG *pType);

    HRESULT (STDMETHODCALLTYPE *MoveLeft)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveRight)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveUp)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *MoveDown)(
        ITextSelection *This,
        LONG Unit,
        LONG Count,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *HomeKey)(
        ITextSelection *This,
        LONG Unit,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *EndKey)(
        ITextSelection *This,
        LONG Unit,
        LONG Extend,
        LONG *pDelta);

    HRESULT (STDMETHODCALLTYPE *TypeText)(
        ITextSelection *This,
        BSTR bstr);

    END_INTERFACE
} ITextSelectionVtbl;

interface ITextSelection {
    CONST_VTBL ITextSelectionVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextSelection_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextSelection_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextSelection_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextSelection_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextSelection_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextSelection_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextSelection_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextRange methods ***/
#define ITextSelection_GetText(This,pbstr) (This)->lpVtbl->GetText(This,pbstr)
#define ITextSelection_SetText(This,bstr) (This)->lpVtbl->SetText(This,bstr)
#define ITextSelection_GetChar(This,pch) (This)->lpVtbl->GetChar(This,pch)
#define ITextSelection_SetChar(This,ch) (This)->lpVtbl->SetChar(This,ch)
#define ITextSelection_GetDuplicate(This,ppRange) (This)->lpVtbl->GetDuplicate(This,ppRange)
#define ITextSelection_GetFormattedText(This,ppRange) (This)->lpVtbl->GetFormattedText(This,ppRange)
#define ITextSelection_SetFormattedText(This,pRange) (This)->lpVtbl->SetFormattedText(This,pRange)
#define ITextSelection_GetStart(This,pcpFirst) (This)->lpVtbl->GetStart(This,pcpFirst)
#define ITextSelection_SetStart(This,cpFirst) (This)->lpVtbl->SetStart(This,cpFirst)
#define ITextSelection_GetEnd(This,pcpLim) (This)->lpVtbl->GetEnd(This,pcpLim)
#define ITextSelection_SetEnd(This,cpLim) (This)->lpVtbl->SetEnd(This,cpLim)
#define ITextSelection_GetFont(This,pFont) (This)->lpVtbl->GetFont(This,pFont)
#define ITextSelection_SetFont(This,pFont) (This)->lpVtbl->SetFont(This,pFont)
#define ITextSelection_GetPara(This,ppPara) (This)->lpVtbl->GetPara(This,ppPara)
#define ITextSelection_SetPara(This,pPara) (This)->lpVtbl->SetPara(This,pPara)
#define ITextSelection_GetStoryLength(This,pcch) (This)->lpVtbl->GetStoryLength(This,pcch)
#define ITextSelection_GetStoryType(This,pValue) (This)->lpVtbl->GetStoryType(This,pValue)
#define ITextSelection_Collapse(This,bStart) (This)->lpVtbl->Collapse(This,bStart)
#define ITextSelection_Expand(This,Unit,pDelta) (This)->lpVtbl->Expand(This,Unit,pDelta)
#define ITextSelection_GetIndex(This,Unit,pIndex) (This)->lpVtbl->GetIndex(This,Unit,pIndex)
#define ITextSelection_SetIndex(This,Unit,Index,Extend) (This)->lpVtbl->SetIndex(This,Unit,Index,Extend)
#define ITextSelection_SetRange(This,anchor,active) (This)->lpVtbl->SetRange(This,anchor,active)
#define ITextSelection_InRange(This,pRange,pb) (This)->lpVtbl->InRange(This,pRange,pb)
#define ITextSelection_InStory(This,pRange,pb) (This)->lpVtbl->InStory(This,pRange,pb)
#define ITextSelection_IsEqual(This,pRange,pb) (This)->lpVtbl->IsEqual(This,pRange,pb)
#define ITextSelection_Select(This) (This)->lpVtbl->Select(This)
#define ITextSelection_StartOf(This,Unit,Extend,pDelta) (This)->lpVtbl->StartOf(This,Unit,Extend,pDelta)
#define ITextSelection_EndOf(This,Unit,Extend,pDelta) (This)->lpVtbl->EndOf(This,Unit,Extend,pDelta)
#define ITextSelection_Move(This,Unit,Count,pDelta) (This)->lpVtbl->Move(This,Unit,Count,pDelta)
#define ITextSelection_MoveStart(This,Unit,Count,pDelta) (This)->lpVtbl->MoveStart(This,Unit,Count,pDelta)
#define ITextSelection_MoveEnd(This,Unit,Count,pDelta) (This)->lpVtbl->MoveEnd(This,Unit,Count,pDelta)
#define ITextSelection_MoveWhile(This,Cset,Count,pDelta) (This)->lpVtbl->MoveWhile(This,Cset,Count,pDelta)
#define ITextSelection_MoveStartWhile(This,Cset,Count,pDelta) (This)->lpVtbl->MoveStartWhile(This,Cset,Count,pDelta)
#define ITextSelection_MoveEndWhile(This,Cset,Count,pDelta) (This)->lpVtbl->MoveEndWhile(This,Cset,Count,pDelta)
#define ITextSelection_MoveUntil(This,Cset,Count,pDelta) (This)->lpVtbl->MoveUntil(This,Cset,Count,pDelta)
#define ITextSelection_MoveStartUntil(This,Cset,Count,pDelta) (This)->lpVtbl->MoveStartUntil(This,Cset,Count,pDelta)
#define ITextSelection_MoveEndUntil(This,Cset,Count,pDelta) (This)->lpVtbl->MoveEndUntil(This,Cset,Count,pDelta)
#define ITextSelection_FindText(This,bstr,cch,Flags,pLength) (This)->lpVtbl->FindText(This,bstr,cch,Flags,pLength)
#define ITextSelection_FindTextStart(This,bstr,cch,Flags,pLength) (This)->lpVtbl->FindTextStart(This,bstr,cch,Flags,pLength)
#define ITextSelection_FindTextEnd(This,bstr,cch,Flags,pLength) (This)->lpVtbl->FindTextEnd(This,bstr,cch,Flags,pLength)
#define ITextSelection_Delete(This,Unit,Count,pDelta) (This)->lpVtbl->Delete(This,Unit,Count,pDelta)
#define ITextSelection_Cut(This,pVar) (This)->lpVtbl->Cut(This,pVar)
#define ITextSelection_Copy(This,pVar) (This)->lpVtbl->Copy(This,pVar)
#define ITextSelection_Paste(This,pVar,Format) (This)->lpVtbl->Paste(This,pVar,Format)
#define ITextSelection_CanPaste(This,pVar,Format,pb) (This)->lpVtbl->CanPaste(This,pVar,Format,pb)
#define ITextSelection_CanEdit(This,pb) (This)->lpVtbl->CanEdit(This,pb)
#define ITextSelection_ChangeCase(This,Type) (This)->lpVtbl->ChangeCase(This,Type)
#define ITextSelection_GetPoint(This,Type,cx,cy) (This)->lpVtbl->GetPoint(This,Type,cx,cy)
#define ITextSelection_SetPoint(This,x,y,Type,Extend) (This)->lpVtbl->SetPoint(This,x,y,Type,Extend)
#define ITextSelection_ScrollIntoView(This,Value) (This)->lpVtbl->ScrollIntoView(This,Value)
#define ITextSelection_GetEmbeddedObject(This,ppv) (This)->lpVtbl->GetEmbeddedObject(This,ppv)
/*** ITextSelection methods ***/
#define ITextSelection_GetFlags(This,pFlags) (This)->lpVtbl->GetFlags(This,pFlags)
#define ITextSelection_SetFlags(This,Flags) (This)->lpVtbl->SetFlags(This,Flags)
#define ITextSelection_GetType(This,pType) (This)->lpVtbl->GetType(This,pType)
#define ITextSelection_MoveLeft(This,Unit,Count,Extend,pDelta) (This)->lpVtbl->MoveLeft(This,Unit,Count,Extend,pDelta)
#define ITextSelection_MoveRight(This,Unit,Count,Extend,pDelta) (This)->lpVtbl->MoveRight(This,Unit,Count,Extend,pDelta)
#define ITextSelection_MoveUp(This,Unit,Count,Extend,pDelta) (This)->lpVtbl->MoveUp(This,Unit,Count,Extend,pDelta)
#define ITextSelection_MoveDown(This,Unit,Count,Extend,pDelta) (This)->lpVtbl->MoveDown(This,Unit,Count,Extend,pDelta)
#define ITextSelection_HomeKey(This,Unit,Extend,pDelta) (This)->lpVtbl->HomeKey(This,Unit,Extend,pDelta)
#define ITextSelection_EndKey(This,Unit,Extend,pDelta) (This)->lpVtbl->EndKey(This,Unit,Extend,pDelta)
#define ITextSelection_TypeText(This,bstr) (This)->lpVtbl->TypeText(This,bstr)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextSelection_QueryInterface(ITextSelection* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextSelection_AddRef(ITextSelection* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextSelection_Release(ITextSelection* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextSelection_GetTypeInfoCount(ITextSelection* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextSelection_GetTypeInfo(ITextSelection* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextSelection_GetIDsOfNames(ITextSelection* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextSelection_Invoke(ITextSelection* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextRange methods ***/
static FORCEINLINE HRESULT ITextSelection_GetText(ITextSelection* This,BSTR *pbstr) {
    return This->lpVtbl->GetText(This,pbstr);
}
static FORCEINLINE HRESULT ITextSelection_SetText(ITextSelection* This,BSTR bstr) {
    return This->lpVtbl->SetText(This,bstr);
}
static FORCEINLINE HRESULT ITextSelection_GetChar(ITextSelection* This,LONG *pch) {
    return This->lpVtbl->GetChar(This,pch);
}
static FORCEINLINE HRESULT ITextSelection_SetChar(ITextSelection* This,LONG ch) {
    return This->lpVtbl->SetChar(This,ch);
}
static FORCEINLINE HRESULT ITextSelection_GetDuplicate(ITextSelection* This,ITextRange **ppRange) {
    return This->lpVtbl->GetDuplicate(This,ppRange);
}
static FORCEINLINE HRESULT ITextSelection_GetFormattedText(ITextSelection* This,ITextRange **ppRange) {
    return This->lpVtbl->GetFormattedText(This,ppRange);
}
static FORCEINLINE HRESULT ITextSelection_SetFormattedText(ITextSelection* This,ITextRange *pRange) {
    return This->lpVtbl->SetFormattedText(This,pRange);
}
static FORCEINLINE HRESULT ITextSelection_GetStart(ITextSelection* This,LONG *pcpFirst) {
    return This->lpVtbl->GetStart(This,pcpFirst);
}
static FORCEINLINE HRESULT ITextSelection_SetStart(ITextSelection* This,LONG cpFirst) {
    return This->lpVtbl->SetStart(This,cpFirst);
}
static FORCEINLINE HRESULT ITextSelection_GetEnd(ITextSelection* This,LONG *pcpLim) {
    return This->lpVtbl->GetEnd(This,pcpLim);
}
static FORCEINLINE HRESULT ITextSelection_SetEnd(ITextSelection* This,LONG cpLim) {
    return This->lpVtbl->SetEnd(This,cpLim);
}
static FORCEINLINE HRESULT ITextSelection_GetFont(ITextSelection* This,ITextFont **pFont) {
    return This->lpVtbl->GetFont(This,pFont);
}
static FORCEINLINE HRESULT ITextSelection_SetFont(ITextSelection* This,ITextFont *pFont) {
    return This->lpVtbl->SetFont(This,pFont);
}
static FORCEINLINE HRESULT ITextSelection_GetPara(ITextSelection* This,ITextPara **ppPara) {
    return This->lpVtbl->GetPara(This,ppPara);
}
static FORCEINLINE HRESULT ITextSelection_SetPara(ITextSelection* This,ITextPara *pPara) {
    return This->lpVtbl->SetPara(This,pPara);
}
static FORCEINLINE HRESULT ITextSelection_GetStoryLength(ITextSelection* This,LONG *pcch) {
    return This->lpVtbl->GetStoryLength(This,pcch);
}
static FORCEINLINE HRESULT ITextSelection_GetStoryType(ITextSelection* This,LONG *pValue) {
    return This->lpVtbl->GetStoryType(This,pValue);
}
static FORCEINLINE HRESULT ITextSelection_Collapse(ITextSelection* This,LONG bStart) {
    return This->lpVtbl->Collapse(This,bStart);
}
static FORCEINLINE HRESULT ITextSelection_Expand(ITextSelection* This,LONG Unit,LONG *pDelta) {
    return This->lpVtbl->Expand(This,Unit,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_GetIndex(ITextSelection* This,LONG Unit,LONG *pIndex) {
    return This->lpVtbl->GetIndex(This,Unit,pIndex);
}
static FORCEINLINE HRESULT ITextSelection_SetIndex(ITextSelection* This,LONG Unit,LONG Index,LONG Extend) {
    return This->lpVtbl->SetIndex(This,Unit,Index,Extend);
}
static FORCEINLINE HRESULT ITextSelection_SetRange(ITextSelection* This,LONG anchor,LONG active) {
    return This->lpVtbl->SetRange(This,anchor,active);
}
static FORCEINLINE HRESULT ITextSelection_InRange(ITextSelection* This,ITextRange *pRange,LONG *pb) {
    return This->lpVtbl->InRange(This,pRange,pb);
}
static FORCEINLINE HRESULT ITextSelection_InStory(ITextSelection* This,ITextRange *pRange,LONG *pb) {
    return This->lpVtbl->InStory(This,pRange,pb);
}
static FORCEINLINE HRESULT ITextSelection_IsEqual(ITextSelection* This,ITextRange *pRange,LONG *pb) {
    return This->lpVtbl->IsEqual(This,pRange,pb);
}
static FORCEINLINE HRESULT ITextSelection_Select(ITextSelection* This) {
    return This->lpVtbl->Select(This);
}
static FORCEINLINE HRESULT ITextSelection_StartOf(ITextSelection* This,LONG Unit,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->StartOf(This,Unit,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_EndOf(ITextSelection* This,LONG Unit,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->EndOf(This,Unit,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_Move(ITextSelection* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->Move(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveStart(ITextSelection* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveStart(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveEnd(ITextSelection* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveEnd(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveWhile(ITextSelection* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveWhile(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveStartWhile(ITextSelection* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveStartWhile(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveEndWhile(ITextSelection* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveEndWhile(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveUntil(ITextSelection* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveUntil(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveStartUntil(ITextSelection* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveStartUntil(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveEndUntil(ITextSelection* This,VARIANT *Cset,LONG Count,LONG *pDelta) {
    return This->lpVtbl->MoveEndUntil(This,Cset,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_FindText(ITextSelection* This,BSTR bstr,LONG cch,LONG Flags,LONG *pLength) {
    return This->lpVtbl->FindText(This,bstr,cch,Flags,pLength);
}
static FORCEINLINE HRESULT ITextSelection_FindTextStart(ITextSelection* This,BSTR bstr,LONG cch,LONG Flags,LONG *pLength) {
    return This->lpVtbl->FindTextStart(This,bstr,cch,Flags,pLength);
}
static FORCEINLINE HRESULT ITextSelection_FindTextEnd(ITextSelection* This,BSTR bstr,LONG cch,LONG Flags,LONG *pLength) {
    return This->lpVtbl->FindTextEnd(This,bstr,cch,Flags,pLength);
}
static FORCEINLINE HRESULT ITextSelection_Delete(ITextSelection* This,LONG Unit,LONG Count,LONG *pDelta) {
    return This->lpVtbl->Delete(This,Unit,Count,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_Cut(ITextSelection* This,VARIANT *pVar) {
    return This->lpVtbl->Cut(This,pVar);
}
static FORCEINLINE HRESULT ITextSelection_Copy(ITextSelection* This,VARIANT *pVar) {
    return This->lpVtbl->Copy(This,pVar);
}
static FORCEINLINE HRESULT ITextSelection_Paste(ITextSelection* This,VARIANT *pVar,LONG Format) {
    return This->lpVtbl->Paste(This,pVar,Format);
}
static FORCEINLINE HRESULT ITextSelection_CanPaste(ITextSelection* This,VARIANT *pVar,LONG Format,LONG *pb) {
    return This->lpVtbl->CanPaste(This,pVar,Format,pb);
}
static FORCEINLINE HRESULT ITextSelection_CanEdit(ITextSelection* This,LONG *pb) {
    return This->lpVtbl->CanEdit(This,pb);
}
static FORCEINLINE HRESULT ITextSelection_ChangeCase(ITextSelection* This,LONG Type) {
    return This->lpVtbl->ChangeCase(This,Type);
}
static FORCEINLINE HRESULT ITextSelection_GetPoint(ITextSelection* This,LONG Type,LONG *cx,LONG *cy) {
    return This->lpVtbl->GetPoint(This,Type,cx,cy);
}
static FORCEINLINE HRESULT ITextSelection_SetPoint(ITextSelection* This,LONG x,LONG y,LONG Type,LONG Extend) {
    return This->lpVtbl->SetPoint(This,x,y,Type,Extend);
}
static FORCEINLINE HRESULT ITextSelection_ScrollIntoView(ITextSelection* This,LONG Value) {
    return This->lpVtbl->ScrollIntoView(This,Value);
}
static FORCEINLINE HRESULT ITextSelection_GetEmbeddedObject(ITextSelection* This,IUnknown **ppv) {
    return This->lpVtbl->GetEmbeddedObject(This,ppv);
}
/*** ITextSelection methods ***/
static FORCEINLINE HRESULT ITextSelection_GetFlags(ITextSelection* This,LONG *pFlags) {
    return This->lpVtbl->GetFlags(This,pFlags);
}
static FORCEINLINE HRESULT ITextSelection_SetFlags(ITextSelection* This,LONG Flags) {
    return This->lpVtbl->SetFlags(This,Flags);
}
static FORCEINLINE HRESULT ITextSelection_GetType(ITextSelection* This,LONG *pType) {
    return This->lpVtbl->GetType(This,pType);
}
static FORCEINLINE HRESULT ITextSelection_MoveLeft(ITextSelection* This,LONG Unit,LONG Count,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->MoveLeft(This,Unit,Count,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveRight(ITextSelection* This,LONG Unit,LONG Count,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->MoveRight(This,Unit,Count,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveUp(ITextSelection* This,LONG Unit,LONG Count,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->MoveUp(This,Unit,Count,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_MoveDown(ITextSelection* This,LONG Unit,LONG Count,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->MoveDown(This,Unit,Count,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_HomeKey(ITextSelection* This,LONG Unit,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->HomeKey(This,Unit,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_EndKey(ITextSelection* This,LONG Unit,LONG Extend,LONG *pDelta) {
    return This->lpVtbl->EndKey(This,Unit,Extend,pDelta);
}
static FORCEINLINE HRESULT ITextSelection_TypeText(ITextSelection* This,BSTR bstr) {
    return This->lpVtbl->TypeText(This,bstr);
}
#endif
#endif

#endif


#endif  /* __ITextSelection_INTERFACE_DEFINED__ */

/*****************************************************************************
 * ITextFont interface
 */
#ifndef __ITextFont_INTERFACE_DEFINED__
#define __ITextFont_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextFont, 0x8cc497c3, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("8cc497c3-a1df-11ce-8098-00aa0047be5d")
ITextFont : public IDispatch
{
    virtual HRESULT STDMETHODCALLTYPE GetDuplicate(
        ITextFont **ppFont) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetDuplicate(
        ITextFont *pFont) = 0;

    virtual HRESULT STDMETHODCALLTYPE CanChange(
        LONG *pB) = 0;

    virtual HRESULT STDMETHODCALLTYPE IsEqual(
        ITextFont *pFont,
        LONG *pB) = 0;

    virtual HRESULT STDMETHODCALLTYPE Reset(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStyle(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetStyle(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetAllCaps(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetAllCaps(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetAnimation(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetAnimation(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetBackColor(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetBackColor(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetBold(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetBold(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEmboss(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetEmboss(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetForeColor(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetForeColor(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetHidden(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetHidden(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetEngrave(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetEngrave(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetItalic(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetItalic(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetKerning(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetKerning(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetLanguageID(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetLanguageID(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetName(
        BSTR *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetName(
        BSTR Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetOutline(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetOutline(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetPosition(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetPosition(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetProtected(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetProtected(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetShadow(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetShadow(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSize(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSize(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSmallCaps(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSmallCaps(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSpacing(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSpacing(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStrikeThrough(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetStrikeThrough(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSubscript(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSubscript(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSuperscript(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSuperscript(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetUnderline(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetUnderline(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetWeight(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetWeight(
        LONG Value) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextFont, 0x8cc497c3, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d)
#endif
#else
typedef struct ITextFontVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextFont *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextFont *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextFont *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextFont *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextFont *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextFont *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextFont *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextFont methods ***/
    HRESULT (STDMETHODCALLTYPE *GetDuplicate)(
        ITextFont *This,
        ITextFont **ppFont);

    HRESULT (STDMETHODCALLTYPE *SetDuplicate)(
        ITextFont *This,
        ITextFont *pFont);

    HRESULT (STDMETHODCALLTYPE *CanChange)(
        ITextFont *This,
        LONG *pB);

    HRESULT (STDMETHODCALLTYPE *IsEqual)(
        ITextFont *This,
        ITextFont *pFont,
        LONG *pB);

    HRESULT (STDMETHODCALLTYPE *Reset)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetStyle)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetStyle)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetAllCaps)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetAllCaps)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetAnimation)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetAnimation)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetBackColor)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetBackColor)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetBold)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetBold)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetEmboss)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetEmboss)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetForeColor)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetForeColor)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetHidden)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetHidden)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetEngrave)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetEngrave)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetItalic)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetItalic)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetKerning)(
        ITextFont *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetKerning)(
        ITextFont *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetLanguageID)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetLanguageID)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetName)(
        ITextFont *This,
        BSTR *pValue);

    HRESULT (STDMETHODCALLTYPE *SetName)(
        ITextFont *This,
        BSTR Value);

    HRESULT (STDMETHODCALLTYPE *GetOutline)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetOutline)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetPosition)(
        ITextFont *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetPosition)(
        ITextFont *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetProtected)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetProtected)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetShadow)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetShadow)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetSize)(
        ITextFont *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSize)(
        ITextFont *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetSmallCaps)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSmallCaps)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetSpacing)(
        ITextFont *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSpacing)(
        ITextFont *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetStrikeThrough)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetStrikeThrough)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetSubscript)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSubscript)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetSuperscript)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSuperscript)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetUnderline)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetUnderline)(
        ITextFont *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetWeight)(
        ITextFont *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetWeight)(
        ITextFont *This,
        LONG Value);

    END_INTERFACE
} ITextFontVtbl;

interface ITextFont {
    CONST_VTBL ITextFontVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextFont_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextFont_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextFont_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextFont_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextFont_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextFont_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextFont_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextFont methods ***/
#define ITextFont_GetDuplicate(This,ppFont) (This)->lpVtbl->GetDuplicate(This,ppFont)
#define ITextFont_SetDuplicate(This,pFont) (This)->lpVtbl->SetDuplicate(This,pFont)
#define ITextFont_CanChange(This,pB) (This)->lpVtbl->CanChange(This,pB)
#define ITextFont_IsEqual(This,pFont,pB) (This)->lpVtbl->IsEqual(This,pFont,pB)
#define ITextFont_Reset(This,Value) (This)->lpVtbl->Reset(This,Value)
#define ITextFont_GetStyle(This,pValue) (This)->lpVtbl->GetStyle(This,pValue)
#define ITextFont_SetStyle(This,Value) (This)->lpVtbl->SetStyle(This,Value)
#define ITextFont_GetAllCaps(This,pValue) (This)->lpVtbl->GetAllCaps(This,pValue)
#define ITextFont_SetAllCaps(This,Value) (This)->lpVtbl->SetAllCaps(This,Value)
#define ITextFont_GetAnimation(This,pValue) (This)->lpVtbl->GetAnimation(This,pValue)
#define ITextFont_SetAnimation(This,Value) (This)->lpVtbl->SetAnimation(This,Value)
#define ITextFont_GetBackColor(This,pValue) (This)->lpVtbl->GetBackColor(This,pValue)
#define ITextFont_SetBackColor(This,Value) (This)->lpVtbl->SetBackColor(This,Value)
#define ITextFont_GetBold(This,pValue) (This)->lpVtbl->GetBold(This,pValue)
#define ITextFont_SetBold(This,Value) (This)->lpVtbl->SetBold(This,Value)
#define ITextFont_GetEmboss(This,pValue) (This)->lpVtbl->GetEmboss(This,pValue)
#define ITextFont_SetEmboss(This,Value) (This)->lpVtbl->SetEmboss(This,Value)
#define ITextFont_GetForeColor(This,pValue) (This)->lpVtbl->GetForeColor(This,pValue)
#define ITextFont_SetForeColor(This,Value) (This)->lpVtbl->SetForeColor(This,Value)
#define ITextFont_GetHidden(This,pValue) (This)->lpVtbl->GetHidden(This,pValue)
#define ITextFont_SetHidden(This,Value) (This)->lpVtbl->SetHidden(This,Value)
#define ITextFont_GetEngrave(This,pValue) (This)->lpVtbl->GetEngrave(This,pValue)
#define ITextFont_SetEngrave(This,Value) (This)->lpVtbl->SetEngrave(This,Value)
#define ITextFont_GetItalic(This,pValue) (This)->lpVtbl->GetItalic(This,pValue)
#define ITextFont_SetItalic(This,Value) (This)->lpVtbl->SetItalic(This,Value)
#define ITextFont_GetKerning(This,pValue) (This)->lpVtbl->GetKerning(This,pValue)
#define ITextFont_SetKerning(This,Value) (This)->lpVtbl->SetKerning(This,Value)
#define ITextFont_GetLanguageID(This,pValue) (This)->lpVtbl->GetLanguageID(This,pValue)
#define ITextFont_SetLanguageID(This,Value) (This)->lpVtbl->SetLanguageID(This,Value)
#define ITextFont_GetName(This,pValue) (This)->lpVtbl->GetName(This,pValue)
#define ITextFont_SetName(This,Value) (This)->lpVtbl->SetName(This,Value)
#define ITextFont_GetOutline(This,pValue) (This)->lpVtbl->GetOutline(This,pValue)
#define ITextFont_SetOutline(This,Value) (This)->lpVtbl->SetOutline(This,Value)
#define ITextFont_GetPosition(This,pValue) (This)->lpVtbl->GetPosition(This,pValue)
#define ITextFont_SetPosition(This,Value) (This)->lpVtbl->SetPosition(This,Value)
#define ITextFont_GetProtected(This,pValue) (This)->lpVtbl->GetProtected(This,pValue)
#define ITextFont_SetProtected(This,Value) (This)->lpVtbl->SetProtected(This,Value)
#define ITextFont_GetShadow(This,pValue) (This)->lpVtbl->GetShadow(This,pValue)
#define ITextFont_SetShadow(This,Value) (This)->lpVtbl->SetShadow(This,Value)
#define ITextFont_GetSize(This,pValue) (This)->lpVtbl->GetSize(This,pValue)
#define ITextFont_SetSize(This,Value) (This)->lpVtbl->SetSize(This,Value)
#define ITextFont_GetSmallCaps(This,pValue) (This)->lpVtbl->GetSmallCaps(This,pValue)
#define ITextFont_SetSmallCaps(This,Value) (This)->lpVtbl->SetSmallCaps(This,Value)
#define ITextFont_GetSpacing(This,pValue) (This)->lpVtbl->GetSpacing(This,pValue)
#define ITextFont_SetSpacing(This,Value) (This)->lpVtbl->SetSpacing(This,Value)
#define ITextFont_GetStrikeThrough(This,pValue) (This)->lpVtbl->GetStrikeThrough(This,pValue)
#define ITextFont_SetStrikeThrough(This,Value) (This)->lpVtbl->SetStrikeThrough(This,Value)
#define ITextFont_GetSubscript(This,pValue) (This)->lpVtbl->GetSubscript(This,pValue)
#define ITextFont_SetSubscript(This,Value) (This)->lpVtbl->SetSubscript(This,Value)
#define ITextFont_GetSuperscript(This,pValue) (This)->lpVtbl->GetSuperscript(This,pValue)
#define ITextFont_SetSuperscript(This,Value) (This)->lpVtbl->SetSuperscript(This,Value)
#define ITextFont_GetUnderline(This,pValue) (This)->lpVtbl->GetUnderline(This,pValue)
#define ITextFont_SetUnderline(This,Value) (This)->lpVtbl->SetUnderline(This,Value)
#define ITextFont_GetWeight(This,pValue) (This)->lpVtbl->GetWeight(This,pValue)
#define ITextFont_SetWeight(This,Value) (This)->lpVtbl->SetWeight(This,Value)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextFont_QueryInterface(ITextFont* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextFont_AddRef(ITextFont* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextFont_Release(ITextFont* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextFont_GetTypeInfoCount(ITextFont* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextFont_GetTypeInfo(ITextFont* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextFont_GetIDsOfNames(ITextFont* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextFont_Invoke(ITextFont* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextFont methods ***/
static FORCEINLINE HRESULT ITextFont_GetDuplicate(ITextFont* This,ITextFont **ppFont) {
    return This->lpVtbl->GetDuplicate(This,ppFont);
}
static FORCEINLINE HRESULT ITextFont_SetDuplicate(ITextFont* This,ITextFont *pFont) {
    return This->lpVtbl->SetDuplicate(This,pFont);
}
static FORCEINLINE HRESULT ITextFont_CanChange(ITextFont* This,LONG *pB) {
    return This->lpVtbl->CanChange(This,pB);
}
static FORCEINLINE HRESULT ITextFont_IsEqual(ITextFont* This,ITextFont *pFont,LONG *pB) {
    return This->lpVtbl->IsEqual(This,pFont,pB);
}
static FORCEINLINE HRESULT ITextFont_Reset(ITextFont* This,LONG Value) {
    return This->lpVtbl->Reset(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetStyle(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetStyle(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetStyle(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetStyle(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetAllCaps(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetAllCaps(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetAllCaps(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetAllCaps(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetAnimation(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetAnimation(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetAnimation(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetAnimation(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetBackColor(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetBackColor(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetBackColor(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetBackColor(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetBold(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetBold(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetBold(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetBold(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetEmboss(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetEmboss(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetEmboss(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetEmboss(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetForeColor(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetForeColor(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetForeColor(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetForeColor(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetHidden(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetHidden(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetHidden(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetHidden(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetEngrave(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetEngrave(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetEngrave(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetEngrave(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetItalic(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetItalic(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetItalic(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetItalic(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetKerning(ITextFont* This,float *pValue) {
    return This->lpVtbl->GetKerning(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetKerning(ITextFont* This,float Value) {
    return This->lpVtbl->SetKerning(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetLanguageID(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetLanguageID(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetLanguageID(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetLanguageID(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetName(ITextFont* This,BSTR *pValue) {
    return This->lpVtbl->GetName(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetName(ITextFont* This,BSTR Value) {
    return This->lpVtbl->SetName(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetOutline(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetOutline(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetOutline(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetOutline(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetPosition(ITextFont* This,float *pValue) {
    return This->lpVtbl->GetPosition(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetPosition(ITextFont* This,float Value) {
    return This->lpVtbl->SetPosition(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetProtected(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetProtected(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetProtected(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetProtected(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetShadow(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetShadow(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetShadow(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetShadow(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetSize(ITextFont* This,float *pValue) {
    return This->lpVtbl->GetSize(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetSize(ITextFont* This,float Value) {
    return This->lpVtbl->SetSize(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetSmallCaps(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetSmallCaps(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetSmallCaps(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetSmallCaps(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetSpacing(ITextFont* This,float *pValue) {
    return This->lpVtbl->GetSpacing(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetSpacing(ITextFont* This,float Value) {
    return This->lpVtbl->SetSpacing(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetStrikeThrough(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetStrikeThrough(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetStrikeThrough(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetStrikeThrough(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetSubscript(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetSubscript(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetSubscript(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetSubscript(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetSuperscript(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetSuperscript(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetSuperscript(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetSuperscript(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetUnderline(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetUnderline(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetUnderline(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetUnderline(This,Value);
}
static FORCEINLINE HRESULT ITextFont_GetWeight(ITextFont* This,LONG *pValue) {
    return This->lpVtbl->GetWeight(This,pValue);
}
static FORCEINLINE HRESULT ITextFont_SetWeight(ITextFont* This,LONG Value) {
    return This->lpVtbl->SetWeight(This,Value);
}
#endif
#endif

#endif


#endif  /* __ITextFont_INTERFACE_DEFINED__ */

/*****************************************************************************
 * ITextPara interface
 */
#ifndef __ITextPara_INTERFACE_DEFINED__
#define __ITextPara_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextPara, 0x8cc497c4, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("8cc497c4-a1df-11ce-8098-00aa0047be5d")
ITextPara : public IDispatch
{
    virtual HRESULT STDMETHODCALLTYPE GetDuplicate(
        ITextPara **ppPara) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetDuplicate(
        ITextPara *pPara) = 0;

    virtual HRESULT STDMETHODCALLTYPE CanChange(
        LONG *pB) = 0;

    virtual HRESULT STDMETHODCALLTYPE IsEqual(
        ITextPara *pPara,
        LONG *pB) = 0;

    virtual HRESULT STDMETHODCALLTYPE Reset(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetStyle(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetStyle(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetAlignment(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetAlignment(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetHyphenation(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetHyphenation(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetFirstLineIndent(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetKeepTogether(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetKeepTogether(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetKeepWithNext(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetKeepWithNext(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetLeftIndent(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetLineSpacing(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetLineSpacingRule(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetListAlignment(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetListAlignment(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetListLevelIndex(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetListLevelIndex(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetListStart(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetListStart(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetListTab(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetListTab(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetListType(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetListType(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetNoLineNumber(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetNoLineNumber(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetPageBreakBefore(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetPageBreakBefore(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetRightIndent(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetRightIndent(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetIndents(
        float StartIndent,
        float LeftIndent,
        float RightIndent) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetLineSpacing(
        LONG LineSpacingRule,
        float LineSpacing) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSpaceAfter(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSpaceAfter(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetSpaceBefore(
        float *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetSpaceBefore(
        float Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetWidowControl(
        LONG *pValue) = 0;

    virtual HRESULT STDMETHODCALLTYPE SetWidowControl(
        LONG Value) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetTabCount(
        LONG *pCount) = 0;

    virtual HRESULT STDMETHODCALLTYPE AddTab(
        float tbPos,
        LONG tbAlign,
        LONG tbLeader) = 0;

    virtual HRESULT STDMETHODCALLTYPE ClearAllTabs(
        ) = 0;

    virtual HRESULT STDMETHODCALLTYPE DeleteTab(
        float tbPos) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetTab(
        LONG iTab,
        float *ptbPos,
        LONG *ptbAlign,
        LONG *ptbLeader) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextPara, 0x8cc497c4, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d)
#endif
#else
typedef struct ITextParaVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextPara *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextPara *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextPara *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextPara *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextPara *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextPara *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextPara *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextPara methods ***/
    HRESULT (STDMETHODCALLTYPE *GetDuplicate)(
        ITextPara *This,
        ITextPara **ppPara);

    HRESULT (STDMETHODCALLTYPE *SetDuplicate)(
        ITextPara *This,
        ITextPara *pPara);

    HRESULT (STDMETHODCALLTYPE *CanChange)(
        ITextPara *This,
        LONG *pB);

    HRESULT (STDMETHODCALLTYPE *IsEqual)(
        ITextPara *This,
        ITextPara *pPara,
        LONG *pB);

    HRESULT (STDMETHODCALLTYPE *Reset)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetStyle)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetStyle)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetAlignment)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetAlignment)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetHyphenation)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetHyphenation)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetFirstLineIndent)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *GetKeepTogether)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetKeepTogether)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetKeepWithNext)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetKeepWithNext)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetLeftIndent)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *GetLineSpacing)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *GetLineSpacingRule)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *GetListAlignment)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetListAlignment)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetListLevelIndex)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetListLevelIndex)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetListStart)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetListStart)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetListTab)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetListTab)(
        ITextPara *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetListType)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetListType)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetNoLineNumber)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetNoLineNumber)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetPageBreakBefore)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetPageBreakBefore)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetRightIndent)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetRightIndent)(
        ITextPara *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *SetIndents)(
        ITextPara *This,
        float StartIndent,
        float LeftIndent,
        float RightIndent);

    HRESULT (STDMETHODCALLTYPE *SetLineSpacing)(
        ITextPara *This,
        LONG LineSpacingRule,
        float LineSpacing);

    HRESULT (STDMETHODCALLTYPE *GetSpaceAfter)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSpaceAfter)(
        ITextPara *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetSpaceBefore)(
        ITextPara *This,
        float *pValue);

    HRESULT (STDMETHODCALLTYPE *SetSpaceBefore)(
        ITextPara *This,
        float Value);

    HRESULT (STDMETHODCALLTYPE *GetWidowControl)(
        ITextPara *This,
        LONG *pValue);

    HRESULT (STDMETHODCALLTYPE *SetWidowControl)(
        ITextPara *This,
        LONG Value);

    HRESULT (STDMETHODCALLTYPE *GetTabCount)(
        ITextPara *This,
        LONG *pCount);

    HRESULT (STDMETHODCALLTYPE *AddTab)(
        ITextPara *This,
        float tbPos,
        LONG tbAlign,
        LONG tbLeader);

    HRESULT (STDMETHODCALLTYPE *ClearAllTabs)(
        ITextPara *This);

    HRESULT (STDMETHODCALLTYPE *DeleteTab)(
        ITextPara *This,
        float tbPos);

    HRESULT (STDMETHODCALLTYPE *GetTab)(
        ITextPara *This,
        LONG iTab,
        float *ptbPos,
        LONG *ptbAlign,
        LONG *ptbLeader);

    END_INTERFACE
} ITextParaVtbl;

interface ITextPara {
    CONST_VTBL ITextParaVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextPara_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextPara_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextPara_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextPara_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextPara_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextPara_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextPara_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextPara methods ***/
#define ITextPara_GetDuplicate(This,ppPara) (This)->lpVtbl->GetDuplicate(This,ppPara)
#define ITextPara_SetDuplicate(This,pPara) (This)->lpVtbl->SetDuplicate(This,pPara)
#define ITextPara_CanChange(This,pB) (This)->lpVtbl->CanChange(This,pB)
#define ITextPara_IsEqual(This,pPara,pB) (This)->lpVtbl->IsEqual(This,pPara,pB)
#define ITextPara_Reset(This,Value) (This)->lpVtbl->Reset(This,Value)
#define ITextPara_GetStyle(This,pValue) (This)->lpVtbl->GetStyle(This,pValue)
#define ITextPara_SetStyle(This,Value) (This)->lpVtbl->SetStyle(This,Value)
#define ITextPara_GetAlignment(This,pValue) (This)->lpVtbl->GetAlignment(This,pValue)
#define ITextPara_SetAlignment(This,Value) (This)->lpVtbl->SetAlignment(This,Value)
#define ITextPara_GetHyphenation(This,pValue) (This)->lpVtbl->GetHyphenation(This,pValue)
#define ITextPara_SetHyphenation(This,Value) (This)->lpVtbl->SetHyphenation(This,Value)
#define ITextPara_GetFirstLineIndent(This,pValue) (This)->lpVtbl->GetFirstLineIndent(This,pValue)
#define ITextPara_GetKeepTogether(This,pValue) (This)->lpVtbl->GetKeepTogether(This,pValue)
#define ITextPara_SetKeepTogether(This,Value) (This)->lpVtbl->SetKeepTogether(This,Value)
#define ITextPara_GetKeepWithNext(This,pValue) (This)->lpVtbl->GetKeepWithNext(This,pValue)
#define ITextPara_SetKeepWithNext(This,Value) (This)->lpVtbl->SetKeepWithNext(This,Value)
#define ITextPara_GetLeftIndent(This,pValue) (This)->lpVtbl->GetLeftIndent(This,pValue)
#define ITextPara_GetLineSpacing(This,pValue) (This)->lpVtbl->GetLineSpacing(This,pValue)
#define ITextPara_GetLineSpacingRule(This,pValue) (This)->lpVtbl->GetLineSpacingRule(This,pValue)
#define ITextPara_GetListAlignment(This,pValue) (This)->lpVtbl->GetListAlignment(This,pValue)
#define ITextPara_SetListAlignment(This,Value) (This)->lpVtbl->SetListAlignment(This,Value)
#define ITextPara_GetListLevelIndex(This,pValue) (This)->lpVtbl->GetListLevelIndex(This,pValue)
#define ITextPara_SetListLevelIndex(This,Value) (This)->lpVtbl->SetListLevelIndex(This,Value)
#define ITextPara_GetListStart(This,pValue) (This)->lpVtbl->GetListStart(This,pValue)
#define ITextPara_SetListStart(This,Value) (This)->lpVtbl->SetListStart(This,Value)
#define ITextPara_GetListTab(This,pValue) (This)->lpVtbl->GetListTab(This,pValue)
#define ITextPara_SetListTab(This,Value) (This)->lpVtbl->SetListTab(This,Value)
#define ITextPara_GetListType(This,pValue) (This)->lpVtbl->GetListType(This,pValue)
#define ITextPara_SetListType(This,Value) (This)->lpVtbl->SetListType(This,Value)
#define ITextPara_GetNoLineNumber(This,pValue) (This)->lpVtbl->GetNoLineNumber(This,pValue)
#define ITextPara_SetNoLineNumber(This,Value) (This)->lpVtbl->SetNoLineNumber(This,Value)
#define ITextPara_GetPageBreakBefore(This,pValue) (This)->lpVtbl->GetPageBreakBefore(This,pValue)
#define ITextPara_SetPageBreakBefore(This,Value) (This)->lpVtbl->SetPageBreakBefore(This,Value)
#define ITextPara_GetRightIndent(This,pValue) (This)->lpVtbl->GetRightIndent(This,pValue)
#define ITextPara_SetRightIndent(This,Value) (This)->lpVtbl->SetRightIndent(This,Value)
#define ITextPara_SetIndents(This,StartIndent,LeftIndent,RightIndent) (This)->lpVtbl->SetIndents(This,StartIndent,LeftIndent,RightIndent)
#define ITextPara_SetLineSpacing(This,LineSpacingRule,LineSpacing) (This)->lpVtbl->SetLineSpacing(This,LineSpacingRule,LineSpacing)
#define ITextPara_GetSpaceAfter(This,pValue) (This)->lpVtbl->GetSpaceAfter(This,pValue)
#define ITextPara_SetSpaceAfter(This,Value) (This)->lpVtbl->SetSpaceAfter(This,Value)
#define ITextPara_GetSpaceBefore(This,pValue) (This)->lpVtbl->GetSpaceBefore(This,pValue)
#define ITextPara_SetSpaceBefore(This,Value) (This)->lpVtbl->SetSpaceBefore(This,Value)
#define ITextPara_GetWidowControl(This,pValue) (This)->lpVtbl->GetWidowControl(This,pValue)
#define ITextPara_SetWidowControl(This,Value) (This)->lpVtbl->SetWidowControl(This,Value)
#define ITextPara_GetTabCount(This,pCount) (This)->lpVtbl->GetTabCount(This,pCount)
#define ITextPara_AddTab(This,tbPos,tbAlign,tbLeader) (This)->lpVtbl->AddTab(This,tbPos,tbAlign,tbLeader)
#define ITextPara_ClearAllTabs(This) (This)->lpVtbl->ClearAllTabs(This)
#define ITextPara_DeleteTab(This,tbPos) (This)->lpVtbl->DeleteTab(This,tbPos)
#define ITextPara_GetTab(This,iTab,ptbPos,ptbAlign,ptbLeader) (This)->lpVtbl->GetTab(This,iTab,ptbPos,ptbAlign,ptbLeader)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextPara_QueryInterface(ITextPara* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextPara_AddRef(ITextPara* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextPara_Release(ITextPara* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextPara_GetTypeInfoCount(ITextPara* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextPara_GetTypeInfo(ITextPara* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextPara_GetIDsOfNames(ITextPara* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextPara_Invoke(ITextPara* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextPara methods ***/
static FORCEINLINE HRESULT ITextPara_GetDuplicate(ITextPara* This,ITextPara **ppPara) {
    return This->lpVtbl->GetDuplicate(This,ppPara);
}
static FORCEINLINE HRESULT ITextPara_SetDuplicate(ITextPara* This,ITextPara *pPara) {
    return This->lpVtbl->SetDuplicate(This,pPara);
}
static FORCEINLINE HRESULT ITextPara_CanChange(ITextPara* This,LONG *pB) {
    return This->lpVtbl->CanChange(This,pB);
}
static FORCEINLINE HRESULT ITextPara_IsEqual(ITextPara* This,ITextPara *pPara,LONG *pB) {
    return This->lpVtbl->IsEqual(This,pPara,pB);
}
static FORCEINLINE HRESULT ITextPara_Reset(ITextPara* This,LONG Value) {
    return This->lpVtbl->Reset(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetStyle(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetStyle(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetStyle(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetStyle(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetAlignment(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetAlignment(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetAlignment(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetAlignment(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetHyphenation(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetHyphenation(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetHyphenation(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetHyphenation(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetFirstLineIndent(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetFirstLineIndent(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_GetKeepTogether(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetKeepTogether(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetKeepTogether(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetKeepTogether(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetKeepWithNext(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetKeepWithNext(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetKeepWithNext(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetKeepWithNext(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetLeftIndent(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetLeftIndent(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_GetLineSpacing(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetLineSpacing(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_GetLineSpacingRule(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetLineSpacingRule(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_GetListAlignment(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetListAlignment(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetListAlignment(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetListAlignment(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetListLevelIndex(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetListLevelIndex(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetListLevelIndex(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetListLevelIndex(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetListStart(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetListStart(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetListStart(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetListStart(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetListTab(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetListTab(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetListTab(ITextPara* This,float Value) {
    return This->lpVtbl->SetListTab(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetListType(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetListType(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetListType(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetListType(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetNoLineNumber(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetNoLineNumber(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetNoLineNumber(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetNoLineNumber(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetPageBreakBefore(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetPageBreakBefore(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetPageBreakBefore(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetPageBreakBefore(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetRightIndent(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetRightIndent(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetRightIndent(ITextPara* This,float Value) {
    return This->lpVtbl->SetRightIndent(This,Value);
}
static FORCEINLINE HRESULT ITextPara_SetIndents(ITextPara* This,float StartIndent,float LeftIndent,float RightIndent) {
    return This->lpVtbl->SetIndents(This,StartIndent,LeftIndent,RightIndent);
}
static FORCEINLINE HRESULT ITextPara_SetLineSpacing(ITextPara* This,LONG LineSpacingRule,float LineSpacing) {
    return This->lpVtbl->SetLineSpacing(This,LineSpacingRule,LineSpacing);
}
static FORCEINLINE HRESULT ITextPara_GetSpaceAfter(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetSpaceAfter(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetSpaceAfter(ITextPara* This,float Value) {
    return This->lpVtbl->SetSpaceAfter(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetSpaceBefore(ITextPara* This,float *pValue) {
    return This->lpVtbl->GetSpaceBefore(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetSpaceBefore(ITextPara* This,float Value) {
    return This->lpVtbl->SetSpaceBefore(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetWidowControl(ITextPara* This,LONG *pValue) {
    return This->lpVtbl->GetWidowControl(This,pValue);
}
static FORCEINLINE HRESULT ITextPara_SetWidowControl(ITextPara* This,LONG Value) {
    return This->lpVtbl->SetWidowControl(This,Value);
}
static FORCEINLINE HRESULT ITextPara_GetTabCount(ITextPara* This,LONG *pCount) {
    return This->lpVtbl->GetTabCount(This,pCount);
}
static FORCEINLINE HRESULT ITextPara_AddTab(ITextPara* This,float tbPos,LONG tbAlign,LONG tbLeader) {
    return This->lpVtbl->AddTab(This,tbPos,tbAlign,tbLeader);
}
static FORCEINLINE HRESULT ITextPara_ClearAllTabs(ITextPara* This) {
    return This->lpVtbl->ClearAllTabs(This);
}
static FORCEINLINE HRESULT ITextPara_DeleteTab(ITextPara* This,float tbPos) {
    return This->lpVtbl->DeleteTab(This,tbPos);
}
static FORCEINLINE HRESULT ITextPara_GetTab(ITextPara* This,LONG iTab,float *ptbPos,LONG *ptbAlign,LONG *ptbLeader) {
    return This->lpVtbl->GetTab(This,iTab,ptbPos,ptbAlign,ptbLeader);
}
#endif
#endif

#endif


#endif  /* __ITextPara_INTERFACE_DEFINED__ */

/*****************************************************************************
 * ITextStoryRanges interface
 */
#ifndef __ITextStoryRanges_INTERFACE_DEFINED__
#define __ITextStoryRanges_INTERFACE_DEFINED__

DEFINE_GUID(IID_ITextStoryRanges, 0x8cc497c5, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d);
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("8cc497c5-a1df-11ce-8098-00aa0047be5d")
ITextStoryRanges : public IDispatch
{
    virtual HRESULT STDMETHODCALLTYPE _NewEnum(
        IUnknown **ppUnkEnum) = 0;

    virtual HRESULT STDMETHODCALLTYPE Item(
        LONG Index,
        ITextRange **ppRange) = 0;

    virtual HRESULT STDMETHODCALLTYPE GetCount(
        LONG *pCount) = 0;

};
#ifdef __CRT_UUID_DECL
__CRT_UUID_DECL(ITextStoryRanges, 0x8cc497c5, 0xa1df, 0x11ce, 0x80,0x98, 0x00,0xaa,0x00,0x47,0xbe,0x5d)
#endif
#else
typedef struct ITextStoryRangesVtbl {
    BEGIN_INTERFACE

    /*** IUnknown methods ***/
    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
        ITextStoryRanges *This,
        REFIID riid,
        void **ppvObject);

    ULONG (STDMETHODCALLTYPE *AddRef)(
        ITextStoryRanges *This);

    ULONG (STDMETHODCALLTYPE *Release)(
        ITextStoryRanges *This);

    /*** IDispatch methods ***/
    HRESULT (STDMETHODCALLTYPE *GetTypeInfoCount)(
        ITextStoryRanges *This,
        UINT *pctinfo);

    HRESULT (STDMETHODCALLTYPE *GetTypeInfo)(
        ITextStoryRanges *This,
        UINT iTInfo,
        LCID lcid,
        ITypeInfo **ppTInfo);

    HRESULT (STDMETHODCALLTYPE *GetIDsOfNames)(
        ITextStoryRanges *This,
        REFIID riid,
        LPOLESTR *rgszNames,
        UINT cNames,
        LCID lcid,
        DISPID *rgDispId);

    HRESULT (STDMETHODCALLTYPE *Invoke)(
        ITextStoryRanges *This,
        DISPID dispIdMember,
        REFIID riid,
        LCID lcid,
        WORD wFlags,
        DISPPARAMS *pDispParams,
        VARIANT *pVarResult,
        EXCEPINFO *pExcepInfo,
        UINT *puArgErr);

    /*** ITextStoryRanges methods ***/
    HRESULT (STDMETHODCALLTYPE *_NewEnum)(
        ITextStoryRanges *This,
        IUnknown **ppUnkEnum);

    HRESULT (STDMETHODCALLTYPE *Item)(
        ITextStoryRanges *This,
        LONG Index,
        ITextRange **ppRange);

    HRESULT (STDMETHODCALLTYPE *GetCount)(
        ITextStoryRanges *This,
        LONG *pCount);

    END_INTERFACE
} ITextStoryRangesVtbl;

interface ITextStoryRanges {
    CONST_VTBL ITextStoryRangesVtbl* lpVtbl;
};

#ifdef COBJMACROS
#ifndef WIDL_C_INLINE_WRAPPERS
/*** IUnknown methods ***/
#define ITextStoryRanges_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
#define ITextStoryRanges_AddRef(This) (This)->lpVtbl->AddRef(This)
#define ITextStoryRanges_Release(This) (This)->lpVtbl->Release(This)
/*** IDispatch methods ***/
#define ITextStoryRanges_GetTypeInfoCount(This,pctinfo) (This)->lpVtbl->GetTypeInfoCount(This,pctinfo)
#define ITextStoryRanges_GetTypeInfo(This,iTInfo,lcid,ppTInfo) (This)->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo)
#define ITextStoryRanges_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId) (This)->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)
#define ITextStoryRanges_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr) (This)->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)
/*** ITextStoryRanges methods ***/
#define ITextStoryRanges__NewEnum(This,ppUnkEnum) (This)->lpVtbl->_NewEnum(This,ppUnkEnum)
#define ITextStoryRanges_Item(This,Index,ppRange) (This)->lpVtbl->Item(This,Index,ppRange)
#define ITextStoryRanges_GetCount(This,pCount) (This)->lpVtbl->GetCount(This,pCount)
#else
/*** IUnknown methods ***/
static FORCEINLINE HRESULT ITextStoryRanges_QueryInterface(ITextStoryRanges* This,REFIID riid,void **ppvObject) {
    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
}
static FORCEINLINE ULONG ITextStoryRanges_AddRef(ITextStoryRanges* This) {
    return This->lpVtbl->AddRef(This);
}
static FORCEINLINE ULONG ITextStoryRanges_Release(ITextStoryRanges* This) {
    return This->lpVtbl->Release(This);
}
/*** IDispatch methods ***/
static FORCEINLINE HRESULT ITextStoryRanges_GetTypeInfoCount(ITextStoryRanges* This,UINT *pctinfo) {
    return This->lpVtbl->GetTypeInfoCount(This,pctinfo);
}
static FORCEINLINE HRESULT ITextStoryRanges_GetTypeInfo(ITextStoryRanges* This,UINT iTInfo,LCID lcid,ITypeInfo **ppTInfo) {
    return This->lpVtbl->GetTypeInfo(This,iTInfo,lcid,ppTInfo);
}
static FORCEINLINE HRESULT ITextStoryRanges_GetIDsOfNames(ITextStoryRanges* This,REFIID riid,LPOLESTR *rgszNames,UINT cNames,LCID lcid,DISPID *rgDispId) {
    return This->lpVtbl->GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId);
}
static FORCEINLINE HRESULT ITextStoryRanges_Invoke(ITextStoryRanges* This,DISPID dispIdMember,REFIID riid,LCID lcid,WORD wFlags,DISPPARAMS *pDispParams,VARIANT *pVarResult,EXCEPINFO *pExcepInfo,UINT *puArgErr) {
    return This->lpVtbl->Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
}
/*** ITextStoryRanges methods ***/
static FORCEINLINE HRESULT ITextStoryRanges__NewEnum(ITextStoryRanges* This,IUnknown **ppUnkEnum) {
    return This->lpVtbl->_NewEnum(This,ppUnkEnum);
}
static FORCEINLINE HRESULT ITextStoryRanges_Item(ITextStoryRanges* This,LONG Index,ITextRange **ppRange) {
    return This->lpVtbl->Item(This,Index,ppRange);
}
static FORCEINLINE HRESULT ITextStoryRanges_GetCount(ITextStoryRanges* This,LONG *pCount) {
    return This->lpVtbl->GetCount(This,pCount);
}
#endif
#endif

#endif


#endif  /* __ITextStoryRanges_INTERFACE_DEFINED__ */

/* Begin additional prototypes for all interfaces */

ULONG           __RPC_USER BSTR_UserSize     (ULONG *, ULONG, BSTR *);
unsigned char * __RPC_USER BSTR_UserMarshal  (ULONG *, unsigned char *, BSTR *);
unsigned char * __RPC_USER BSTR_UserUnmarshal(ULONG *, unsigned char *, BSTR *);
void            __RPC_USER BSTR_UserFree     (ULONG *, BSTR *);
ULONG           __RPC_USER VARIANT_UserSize     (ULONG *, ULONG, VARIANT *);
unsigned char * __RPC_USER VARIANT_UserMarshal  (ULONG *, unsigned char *, VARIANT *);
unsigned char * __RPC_USER VARIANT_UserUnmarshal(ULONG *, unsigned char *, VARIANT *);
void            __RPC_USER VARIANT_UserFree     (ULONG *, VARIANT *);

/* End additional prototypes */

#ifdef __cplusplus
}
#endif

#endif /* __tom_h__ */
