ReactOS 0.4.16-dev-889-g9563c07
richole.c File Reference
#include <stdarg.h>
#include "windef.h"
#include "winbase.h"
#include "wingdi.h"
#include "winuser.h"
#include "ole2.h"
#include "richole.h"
#include "editor.h"
#include "richedit.h"
#include "tom.h"
#include "wine/debug.h"
#include "initguid.h"
Include dependency graph for richole.c:

Go to the source code of this file.

Classes

union  textfont_prop_val
 
struct  reole_child
 
struct  ITextRangeImpl
 
struct  ITextFontImpl
 
struct  ITextParaImpl
 
struct  IOleClientSiteImpl
 

Macros

#define NONAMELESSUNION
 
#define COBJMACROS
 
#define CHARFORMAT_SET_B_FIELD(mask, value)
 

Typedefs

typedef struct IOleClientSiteImpl IOleClientSiteImpl
 
typedef struct ITextRangeImpl ITextRangeImpl
 
typedef struct ITextFontImpl ITextFontImpl
 
typedef struct ITextParaImpl ITextParaImpl
 

Enumerations

enum  tid_t {
  LAST_tid , LAST_tid , Database_tid , Installer_tid ,
  Record_tid , Session_tid , StringList_tid , SummaryInfo_tid ,
  View_tid , LAST_tid , NULL_tid , IXMLDOMAttribute_tid ,
  IXMLDOMCDATASection_tid , IXMLDOMComment_tid , IXMLDOMDocument_tid , IXMLDOMDocument2_tid ,
  IXMLDOMDocument3_tid , IXMLDOMDocumentFragment_tid , IXMLDOMDocumentType_tid , IXMLDOMElement_tid ,
  IXMLDOMEntityReference_tid , IXMLDOMImplementation_tid , IXMLDOMNamedNodeMap_tid , IXMLDOMNode_tid ,
  IXMLDOMNodeList_tid , IXMLDOMParseError2_tid , IXMLDOMProcessingInstruction_tid , IXMLDOMSchemaCollection_tid ,
  IXMLDOMSchemaCollection2_tid , IXMLDOMSelection_tid , IXMLDOMText_tid , IXMLElement_tid ,
  IXMLDocument_tid , IXMLHTTPRequest_tid , IXSLProcessor_tid , IXSLTemplate_tid ,
  IVBSAXAttributes_tid , IVBSAXContentHandler_tid , IVBSAXDeclHandler_tid , IVBSAXDTDHandler_tid ,
  IVBSAXEntityResolver_tid , IVBSAXErrorHandler_tid , IVBSAXLexicalHandler_tid , IVBSAXLocator_tid ,
  IVBSAXXMLFilter_tid , IVBSAXXMLReader_tid , IMXAttributes_tid , IMXReaderControl_tid ,
  IMXWriter_tid , IVBMXNamespaceManager_tid , IServerXMLHTTPRequest_tid , LAST_tid ,
  NULL_tid , ITextDocument_tid , ITextRange_tid , ITextSelection_tid ,
  ITextFont_tid , ITextPara_tid , LAST_tid , NULL_tid ,
  IDictionary_tid , IDrive_tid , IDriveCollection_tid , IFile_tid ,
  IFileCollection_tid , IFileSystem3_tid , IFolder_tid , IFolderCollection_tid ,
  ITextStream_tid , LAST_tid , NULL_tid , IWshCollection_tid ,
  IWshEnvironment_tid , IWshExec_tid , IWshShell3_tid , IWshShortcut_tid ,
  LAST_tid
}
 
enum  textfont_prop_id {
  FONT_ALLCAPS = 0 , FONT_ANIMATION , FONT_BACKCOLOR , FONT_BOLD ,
  FONT_EMBOSS , FONT_FORECOLOR , FONT_HIDDEN , FONT_ENGRAVE ,
  FONT_ITALIC , FONT_KERNING , FONT_LANGID , FONT_NAME ,
  FONT_OUTLINE , FONT_POSITION , FONT_PROTECTED , FONT_SHADOW ,
  FONT_SIZE , FONT_SMALLCAPS , FONT_SPACING , FONT_STRIKETHROUGH ,
  FONT_SUBSCRIPT , FONT_SUPERSCRIPT , FONT_UNDERLINE , FONT_WEIGHT ,
  FONT_PROPID_LAST , FONT_PROPID_FIRST = FONT_ALLCAPS
}
 
enum  range_update_op { RANGE_UPDATE_DELETE }
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (richedit)
 
 DEFINE_GUID (LIBID_tom, 0x8cc497c9, 0xa1df, 0x11ce, 0x80, 0x98, 0x00, 0xaa, 0x00, 0x47, 0xbe, 0x5d)
 
 DEFINE_GUID (IID_ITextServices, 0x8d33f740, 0xcf58, 0x11ce, 0xa8, 0x9d, 0x00, 0xaa, 0x00, 0x6c, 0xad, 0xc5)
 
 DEFINE_GUID (IID_ITextHost, 0x13e670f4, 0x1a5a, 0x11cf, 0xab, 0xeb, 0x00, 0xaa, 0x00, 0xb6, 0x5e, 0xa1)
 
 DEFINE_GUID (IID_ITextHost2, 0x13e670f5, 0x1a5a, 0x11cf, 0xab, 0xeb, 0x00, 0xaa, 0x00, 0xb6, 0x5e, 0xa1)
 
 DEFINE_GUID (IID_ITextDocument, 0x8cc497c0, 0xa1df, 0x11ce, 0x80, 0x98, 0x00, 0xaa, 0x00, 0x47, 0xbe, 0x5d)
 
 DEFINE_GUID (IID_ITextDocument2Old, 0x01c25500, 0x4268, 0x11d1, 0x88, 0x3a, 0x3c, 0x8b, 0x00, 0xc1, 0x00, 0x00)
 
 DEFINE_GUID (IID_ITextRange, 0x8cc497c2, 0xa1df, 0x11ce, 0x80, 0x98, 0x00, 0xaa, 0x00, 0x47, 0xbe, 0x5d)
 
 DEFINE_GUID (IID_ITextSelection, 0x8cc497c1, 0xa1df, 0x11ce, 0x80, 0x98, 0x00, 0xaa, 0x00, 0x47, 0xbe, 0x5d)
 
 DEFINE_GUID (IID_ITextFont, 0x8cc497c3, 0xa1df, 0x11ce, 0x80, 0x98, 0x00, 0xaa, 0x00, 0x47, 0xbe, 0x5d)
 
 DEFINE_GUID (IID_ITextPara, 0x8cc497c4, 0xa1df, 0x11ce, 0x80, 0x98, 0x00, 0xaa, 0x00, 0x47, 0xbe, 0x5d)
 
static HRESULT load_typelib (void)
 
void release_typelib (void)
 
static HRESULT get_typeinfo (enum tid_t tid, ITypeInfo **typeinfo)
 
 DEFINE_GUID (IID_Igetrichole, 0xe3ce5c7a, 0x8247, 0x4622, 0x81, 0xad, 0x11, 0x81, 0x02, 0xaa, 0x01, 0x30)
 
static struct text_servicesimpl_from_IRichEditOle (IRichEditOle *iface)
 
static struct text_servicesimpl_from_ITextDocument2Old (ITextDocument2Old *iface)
 
static IOleClientSiteImplimpl_from_IOleInPlaceSite (IOleInPlaceSite *iface)
 
static ITextRangeImplimpl_from_ITextRange (ITextRange *iface)
 
static struct text_selectionimpl_from_ITextSelection (ITextSelection *iface)
 
static ITextFontImplimpl_from_ITextFont (ITextFont *iface)
 
static ITextParaImplimpl_from_ITextPara (ITextPara *iface)
 
static HRESULT create_textfont (ITextRange *, const ITextFontImpl *, ITextFont **)
 
static HRESULT create_textpara (ITextRange *, ITextPara **)
 
static struct text_selectiontext_selection_create (struct text_services *)
 
static HRESULT textrange_get_storylength (ME_TextEditor *editor, LONG *length)
 
static void textranges_update_ranges (struct text_services *services, LONG start, LONG end, enum range_update_op op)
 
static BOOL is_equal_textfont_prop_value (enum textfont_prop_id propid, textfont_prop_val *left, textfont_prop_val *right)
 
static void init_textfont_prop_value (enum textfont_prop_id propid, textfont_prop_val *v)
 
static FLOAT twips_to_points (LONG value)
 
static FLOAT points_to_twips (FLOAT value)
 
static HRESULT get_textfont_prop_for_pos (const struct text_services *services, int pos, enum textfont_prop_id propid, textfont_prop_val *value)
 
static const struct text_servicesget_range_reole (ITextRange *range)
 
static void textrange_set_font (ITextRange *range, ITextFont *font)
 
static HRESULT get_textfont_prop (const ITextFontImpl *font, enum textfont_prop_id propid, textfont_prop_val *value)
 
static HRESULT get_textfont_propf (const ITextFontImpl *font, enum textfont_prop_id propid, FLOAT *value)
 
static HRESULT get_textfont_propl (const ITextFontImpl *font, enum textfont_prop_id propid, LONG *value)
 
static HRESULT set_textfont_prop (ITextFontImpl *font, enum textfont_prop_id propid, const textfont_prop_val *value)
 
static HRESULT set_textfont_propl (ITextFontImpl *font, enum textfont_prop_id propid, LONG value)
 
static HRESULT set_textfont_propf (ITextFontImpl *font, enum textfont_prop_id propid, FLOAT value)
 
static HRESULT set_textfont_propd (ITextFontImpl *font, enum textfont_prop_id propid, LONG value)
 
static HRESULT textfont_getname_from_range (ITextRange *range, BSTR *ret)
 
static void textfont_cache_range_props (ITextFontImpl *font)
 
static HRESULT textrange_expand (ITextRange *range, LONG unit, LONG *delta)
 
static HRESULT WINAPI IRichEditOle_fnQueryInterface (IRichEditOle *iface, REFIID riid, LPVOID *ppvObj)
 
static ULONG WINAPI IRichEditOle_fnAddRef (IRichEditOle *iface)
 
static ULONG WINAPI IRichEditOle_fnRelease (IRichEditOle *iface)
 
static HRESULT WINAPI IRichEditOle_fnActivateAs (IRichEditOle *iface, REFCLSID rclsid, REFCLSID rclsidAs)
 
static HRESULT WINAPI IRichEditOle_fnContextSensitiveHelp (IRichEditOle *iface, BOOL fEnterMode)
 
static HRESULT WINAPI IRichEditOle_fnConvertObject (IRichEditOle *iface, LONG iob, REFCLSID class, LPCSTR user_type)
 
static IOleClientSiteImplimpl_from_IOleClientSite (IOleClientSite *iface)
 
static HRESULT WINAPI IOleClientSite_fnQueryInterface (IOleClientSite *me, REFIID riid, LPVOID *ppvObj)
 
static ULONG WINAPI IOleClientSite_fnAddRef (IOleClientSite *iface)
 
static ULONG WINAPI IOleClientSite_fnRelease (IOleClientSite *iface)
 
static HRESULT WINAPI IOleClientSite_fnSaveObject (IOleClientSite *iface)
 
static HRESULT WINAPI IOleClientSite_fnGetMoniker (IOleClientSite *iface, DWORD dwAssign, DWORD dwWhichMoniker, IMoniker **ppmk)
 
static HRESULT WINAPI IOleClientSite_fnGetContainer (IOleClientSite *iface, IOleContainer **ppContainer)
 
static HRESULT WINAPI IOleClientSite_fnShowObject (IOleClientSite *iface)
 
static HRESULT WINAPI IOleClientSite_fnOnShowWindow (IOleClientSite *iface, BOOL fShow)
 
static HRESULT WINAPI IOleClientSite_fnRequestNewObjectLayout (IOleClientSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnQueryInterface (IOleInPlaceSite *iface, REFIID riid, void **ppvObj)
 
static ULONG STDMETHODCALLTYPE IOleInPlaceSite_fnAddRef (IOleInPlaceSite *iface)
 
static ULONG STDMETHODCALLTYPE IOleInPlaceSite_fnRelease (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnGetWindow (IOleInPlaceSite *iface, HWND *window)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnContextSensitiveHelp (IOleInPlaceSite *iface, BOOL fEnterMode)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnCanInPlaceActivate (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnInPlaceActivate (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnUIActivate (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnGetWindowContext (IOleInPlaceSite *iface, IOleInPlaceFrame **ppFrame, IOleInPlaceUIWindow **ppDoc, LPRECT lprcPosRect, LPRECT lprcClipRect, LPOLEINPLACEFRAMEINFO lpFrameInfo)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnScroll (IOleInPlaceSite *iface, SIZE scrollExtent)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnUIDeactivate (IOleInPlaceSite *iface, BOOL fUndoable)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnInPlaceDeactivate (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnDiscardUndoState (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnDeactivateAndUndo (IOleInPlaceSite *iface)
 
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnPosRectChange (IOleInPlaceSite *iface, LPCRECT lprcPosRect)
 
static HRESULT CreateOleClientSite (struct text_services *services, IOleClientSite **ret)
 
static HRESULT WINAPI IRichEditOle_fnGetClientSite (IRichEditOle *iface, IOleClientSite **clientsite)
 
static HRESULT WINAPI IRichEditOle_fnGetClipboardData (IRichEditOle *iface, CHARRANGE *lpchrg, DWORD reco, LPDATAOBJECT *lplpdataobj)
 
static LONG WINAPI IRichEditOle_fnGetLinkCount (IRichEditOle *iface)
 
static HRESULT WINAPI IRichEditOle_fnGetObject (IRichEditOle *iface, LONG iob, REOBJECT *lpreobject, DWORD dwFlags)
 
static LONG WINAPI IRichEditOle_fnGetObjectCount (IRichEditOle *iface)
 
static HRESULT WINAPI IRichEditOle_fnHandsOffStorage (IRichEditOle *iface, LONG iob)
 
static HRESULT WINAPI IRichEditOle_fnImportDataObject (IRichEditOle *iface, LPDATAOBJECT lpdataobj, CLIPFORMAT cf, HGLOBAL hMetaPict)
 
static HRESULT WINAPI IRichEditOle_fnInPlaceDeactivate (IRichEditOle *iface)
 
static HRESULT WINAPI IRichEditOle_fnInsertObject (IRichEditOle *iface, REOBJECT *reo)
 
static HRESULT WINAPI IRichEditOle_fnSaveCompleted (IRichEditOle *iface, LONG iob, LPSTORAGE lpstg)
 
static HRESULT WINAPI IRichEditOle_fnSetDvaspect (IRichEditOle *iface, LONG iob, DWORD dvaspect)
 
static HRESULT WINAPI IRichEditOle_fnSetHostNames (IRichEditOle *iface, LPCSTR lpstrContainerApp, LPCSTR lpstrContainerObj)
 
static HRESULT WINAPI IRichEditOle_fnSetLinkAvailable (IRichEditOle *iface, LONG iob, BOOL fAvailable)
 
static HRESULT WINAPI ITextRange_fnQueryInterface (ITextRange *me, REFIID riid, void **ppvObj)
 
static ULONG WINAPI ITextRange_fnAddRef (ITextRange *me)
 
static ULONG WINAPI ITextRange_fnRelease (ITextRange *me)
 
static HRESULT WINAPI ITextRange_fnGetTypeInfoCount (ITextRange *me, UINT *pctinfo)
 
static HRESULT WINAPI ITextRange_fnGetTypeInfo (ITextRange *me, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
 
static HRESULT WINAPI ITextRange_fnGetIDsOfNames (ITextRange *me, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
 
static HRESULT WINAPI ITextRange_fnInvoke (ITextRange *me, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
 
static HRESULT WINAPI ITextRange_fnGetText (ITextRange *me, BSTR *str)
 
static HRESULT WINAPI ITextRange_fnSetText (ITextRange *me, BSTR str)
 
static HRESULT range_GetChar (ME_TextEditor *editor, ME_Cursor *cursor, LONG *pch)
 
static HRESULT WINAPI ITextRange_fnGetChar (ITextRange *me, LONG *pch)
 
static HRESULT WINAPI ITextRange_fnSetChar (ITextRange *me, LONG ch)
 
static HRESULT CreateITextRange (struct text_services *services, LONG start, LONG end, ITextRange **ppRange)
 
static HRESULT WINAPI ITextRange_fnGetDuplicate (ITextRange *me, ITextRange **ppRange)
 
static HRESULT WINAPI ITextRange_fnGetFormattedText (ITextRange *me, ITextRange **range)
 
static HRESULT WINAPI ITextRange_fnSetFormattedText (ITextRange *me, ITextRange *range)
 
static HRESULT WINAPI ITextRange_fnGetStart (ITextRange *me, LONG *start)
 
static HRESULT textrange_setstart (const struct text_services *services, LONG value, LONG *start, LONG *end)
 
static HRESULT WINAPI ITextRange_fnSetStart (ITextRange *me, LONG value)
 
static HRESULT WINAPI ITextRange_fnGetEnd (ITextRange *me, LONG *end)
 
static HRESULT textrange_setend (const struct text_services *services, LONG value, LONG *start, LONG *end)
 
static HRESULT WINAPI ITextRange_fnSetEnd (ITextRange *me, LONG value)
 
static HRESULT WINAPI ITextRange_fnGetFont (ITextRange *me, ITextFont **font)
 
static HRESULT WINAPI ITextRange_fnSetFont (ITextRange *me, ITextFont *font)
 
static HRESULT WINAPI ITextRange_fnGetPara (ITextRange *me, ITextPara **para)
 
static HRESULT WINAPI ITextRange_fnSetPara (ITextRange *me, ITextPara *para)
 
static HRESULT WINAPI ITextRange_fnGetStoryLength (ITextRange *me, LONG *length)
 
static HRESULT WINAPI ITextRange_fnGetStoryType (ITextRange *me, LONG *value)
 
static HRESULT range_Collapse (LONG bStart, LONG *start, LONG *end)
 
static HRESULT WINAPI ITextRange_fnCollapse (ITextRange *me, LONG bStart)
 
static HRESULT WINAPI ITextRange_fnExpand (ITextRange *me, LONG unit, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnGetIndex (ITextRange *me, LONG unit, LONG *index)
 
static HRESULT WINAPI ITextRange_fnSetIndex (ITextRange *me, LONG unit, LONG index, LONG extend)
 
static void cp2range (ME_TextEditor *editor, LONG *cp1, LONG *cp2)
 
static HRESULT WINAPI ITextRange_fnSetRange (ITextRange *me, LONG anchor, LONG active)
 
static HRESULT textrange_inrange (LONG start, LONG end, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextRange_fnInRange (ITextRange *me, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextRange_fnInStory (ITextRange *me, ITextRange *pRange, LONG *ret)
 
static HRESULT textrange_isequal (LONG start, LONG end, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextRange_fnIsEqual (ITextRange *me, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextRange_fnSelect (ITextRange *me)
 
static HRESULT textrange_startof (ITextRange *range, LONG unit, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnStartOf (ITextRange *me, LONG unit, LONG extend, LONG *delta)
 
static HRESULT textrange_endof (ITextRange *range, ME_TextEditor *editor, LONG unit, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnEndOf (ITextRange *me, LONG unit, LONG extend, LONG *delta)
 
static HRESULT textrange_move (ITextRange *range, ME_TextEditor *editor, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMove (ITextRange *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT textrange_movestart (ITextRange *range, ME_TextEditor *editor, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveStart (ITextRange *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT textrange_moveend (ITextRange *range, ME_TextEditor *editor, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveEnd (ITextRange *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveWhile (ITextRange *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveStartWhile (ITextRange *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveEndWhile (ITextRange *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveUntil (ITextRange *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveStartUntil (ITextRange *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnMoveEndUntil (ITextRange *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextRange_fnFindText (ITextRange *me, BSTR text, LONG count, LONG flags, LONG *length)
 
static HRESULT WINAPI ITextRange_fnFindTextStart (ITextRange *me, BSTR text, LONG count, LONG flags, LONG *length)
 
static HRESULT WINAPI ITextRange_fnFindTextEnd (ITextRange *me, BSTR text, LONG count, LONG flags, LONG *length)
 
static HRESULT WINAPI ITextRange_fnDelete (ITextRange *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT textrange_copy_or_cut (ITextRange *range, ME_TextEditor *editor, BOOL cut, VARIANT *v)
 
static HRESULT WINAPI ITextRange_fnCut (ITextRange *me, VARIANT *v)
 
static HRESULT WINAPI ITextRange_fnCopy (ITextRange *me, VARIANT *v)
 
static HRESULT WINAPI ITextRange_fnPaste (ITextRange *me, VARIANT *v, LONG format)
 
static HRESULT WINAPI ITextRange_fnCanPaste (ITextRange *me, VARIANT *v, LONG format, LONG *ret)
 
static HRESULT WINAPI ITextRange_fnCanEdit (ITextRange *me, LONG *ret)
 
static HRESULT WINAPI ITextRange_fnChangeCase (ITextRange *me, LONG type)
 
static HRESULT WINAPI ITextRange_fnGetPoint (ITextRange *me, LONG type, LONG *cx, LONG *cy)
 
static HRESULT WINAPI ITextRange_fnSetPoint (ITextRange *me, LONG x, LONG y, LONG type, LONG extend)
 
static HRESULT WINAPI ITextRange_fnScrollIntoView (ITextRange *me, LONG value)
 
static HRESULT WINAPI ITextRange_fnGetEmbeddedObject (ITextRange *me, IUnknown **ppv)
 
static HRESULT WINAPI TextFont_QueryInterface (ITextFont *iface, REFIID riid, void **ppv)
 
static ULONG WINAPI TextFont_AddRef (ITextFont *iface)
 
static ULONG WINAPI TextFont_Release (ITextFont *iface)
 
static HRESULT WINAPI TextFont_GetTypeInfoCount (ITextFont *iface, UINT *pctinfo)
 
static HRESULT WINAPI TextFont_GetTypeInfo (ITextFont *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
 
static HRESULT WINAPI TextFont_GetIDsOfNames (ITextFont *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
 
static HRESULT WINAPI TextFont_Invoke (ITextFont *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
 
static HRESULT WINAPI TextFont_GetDuplicate (ITextFont *iface, ITextFont **ret)
 
static HRESULT WINAPI TextFont_SetDuplicate (ITextFont *iface, ITextFont *pFont)
 
static HRESULT WINAPI TextFont_CanChange (ITextFont *iface, LONG *ret)
 
static HRESULT WINAPI TextFont_IsEqual (ITextFont *iface, ITextFont *font, LONG *ret)
 
static void textfont_reset_to_default (ITextFontImpl *font)
 
static void textfont_reset_to_undefined (ITextFontImpl *font)
 
static void textfont_apply_range_props (ITextFontImpl *font)
 
static HRESULT WINAPI TextFont_Reset (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetStyle (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetStyle (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetAllCaps (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetAllCaps (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetAnimation (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetAnimation (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetBackColor (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetBackColor (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetBold (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetBold (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetEmboss (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetEmboss (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetForeColor (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetForeColor (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetHidden (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetHidden (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetEngrave (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetEngrave (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetItalic (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetItalic (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetKerning (ITextFont *iface, FLOAT *value)
 
static HRESULT WINAPI TextFont_SetKerning (ITextFont *iface, FLOAT value)
 
static HRESULT WINAPI TextFont_GetLanguageID (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetLanguageID (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetName (ITextFont *iface, BSTR *value)
 
static HRESULT WINAPI TextFont_SetName (ITextFont *iface, BSTR value)
 
static HRESULT WINAPI TextFont_GetOutline (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetOutline (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetPosition (ITextFont *iface, FLOAT *value)
 
static HRESULT WINAPI TextFont_SetPosition (ITextFont *iface, FLOAT value)
 
static HRESULT WINAPI TextFont_GetProtected (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetProtected (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetShadow (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetShadow (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetSize (ITextFont *iface, FLOAT *value)
 
static HRESULT WINAPI TextFont_SetSize (ITextFont *iface, FLOAT value)
 
static HRESULT WINAPI TextFont_GetSmallCaps (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetSmallCaps (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetSpacing (ITextFont *iface, FLOAT *value)
 
static HRESULT WINAPI TextFont_SetSpacing (ITextFont *iface, FLOAT value)
 
static HRESULT WINAPI TextFont_GetStrikeThrough (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetStrikeThrough (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetSubscript (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetSubscript (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetSuperscript (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetSuperscript (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetUnderline (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetUnderline (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextFont_GetWeight (ITextFont *iface, LONG *value)
 
static HRESULT WINAPI TextFont_SetWeight (ITextFont *iface, LONG value)
 
static HRESULT WINAPI TextPara_QueryInterface (ITextPara *iface, REFIID riid, void **ppv)
 
static ULONG WINAPI TextPara_AddRef (ITextPara *iface)
 
static ULONG WINAPI TextPara_Release (ITextPara *iface)
 
static HRESULT WINAPI TextPara_GetTypeInfoCount (ITextPara *iface, UINT *pctinfo)
 
static HRESULT WINAPI TextPara_GetTypeInfo (ITextPara *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
 
static HRESULT WINAPI TextPara_GetIDsOfNames (ITextPara *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
 
static HRESULT WINAPI TextPara_Invoke (ITextPara *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
 
static HRESULT WINAPI TextPara_GetDuplicate (ITextPara *iface, ITextPara **ret)
 
static HRESULT WINAPI TextPara_SetDuplicate (ITextPara *iface, ITextPara *para)
 
static HRESULT WINAPI TextPara_CanChange (ITextPara *iface, LONG *ret)
 
static HRESULT WINAPI TextPara_IsEqual (ITextPara *iface, ITextPara *para, LONG *ret)
 
static HRESULT WINAPI TextPara_Reset (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetStyle (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetStyle (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetAlignment (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetAlignment (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetHyphenation (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetHyphenation (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetFirstLineIndent (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_GetKeepTogether (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetKeepTogether (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetKeepWithNext (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetKeepWithNext (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetLeftIndent (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_GetLineSpacing (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_GetLineSpacingRule (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_GetListAlignment (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetListAlignment (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetListLevelIndex (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetListLevelIndex (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetListStart (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetListStart (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetListTab (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_SetListTab (ITextPara *iface, FLOAT value)
 
static HRESULT WINAPI TextPara_GetListType (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetListType (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetNoLineNumber (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetNoLineNumber (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetPageBreakBefore (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetPageBreakBefore (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetRightIndent (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_SetRightIndent (ITextPara *iface, FLOAT value)
 
static HRESULT WINAPI TextPara_SetIndents (ITextPara *iface, FLOAT StartIndent, FLOAT LeftIndent, FLOAT RightIndent)
 
static HRESULT WINAPI TextPara_SetLineSpacing (ITextPara *iface, LONG LineSpacingRule, FLOAT LineSpacing)
 
static HRESULT WINAPI TextPara_GetSpaceAfter (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_SetSpaceAfter (ITextPara *iface, FLOAT value)
 
static HRESULT WINAPI TextPara_GetSpaceBefore (ITextPara *iface, FLOAT *value)
 
static HRESULT WINAPI TextPara_SetSpaceBefore (ITextPara *iface, FLOAT value)
 
static HRESULT WINAPI TextPara_GetWidowControl (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_SetWidowControl (ITextPara *iface, LONG value)
 
static HRESULT WINAPI TextPara_GetTabCount (ITextPara *iface, LONG *value)
 
static HRESULT WINAPI TextPara_AddTab (ITextPara *iface, FLOAT tbPos, LONG tbAlign, LONG tbLeader)
 
static HRESULT WINAPI TextPara_ClearAllTabs (ITextPara *iface)
 
static HRESULT WINAPI TextPara_DeleteTab (ITextPara *iface, FLOAT pos)
 
static HRESULT WINAPI TextPara_GetTab (ITextPara *iface, LONG iTab, FLOAT *ptbPos, LONG *ptbAlign, LONG *ptbLeader)
 
static HRESULT WINAPI ITextDocument2Old_fnQueryInterface (ITextDocument2Old *iface, REFIID riid, void **ppvObject)
 
static ULONG WINAPI ITextDocument2Old_fnAddRef (ITextDocument2Old *iface)
 
static ULONG WINAPI ITextDocument2Old_fnRelease (ITextDocument2Old *iface)
 
static HRESULT WINAPI ITextDocument2Old_fnGetTypeInfoCount (ITextDocument2Old *iface, UINT *pctinfo)
 
static HRESULT WINAPI ITextDocument2Old_fnGetTypeInfo (ITextDocument2Old *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
 
static HRESULT WINAPI ITextDocument2Old_fnGetIDsOfNames (ITextDocument2Old *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
 
static HRESULT WINAPI ITextDocument2Old_fnInvoke (ITextDocument2Old *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
 
static HRESULT WINAPI ITextDocument2Old_fnGetName (ITextDocument2Old *iface, BSTR *pName)
 
static HRESULT WINAPI ITextDocument2Old_fnGetSelection (ITextDocument2Old *iface, ITextSelection **selection)
 
static HRESULT WINAPI ITextDocument2Old_fnGetStoryCount (ITextDocument2Old *iface, LONG *pCount)
 
static HRESULT WINAPI ITextDocument2Old_fnGetStoryRanges (ITextDocument2Old *iface, ITextStoryRanges **ppStories)
 
static HRESULT WINAPI ITextDocument2Old_fnGetSaved (ITextDocument2Old *iface, LONG *pValue)
 
static HRESULT WINAPI ITextDocument2Old_fnSetSaved (ITextDocument2Old *iface, LONG Value)
 
static HRESULT WINAPI ITextDocument2Old_fnGetDefaultTabStop (ITextDocument2Old *iface, float *pValue)
 
static HRESULT WINAPI ITextDocument2Old_fnSetDefaultTabStop (ITextDocument2Old *iface, float Value)
 
static HRESULT WINAPI ITextDocument2Old_fnNew (ITextDocument2Old *iface)
 
static HRESULT WINAPI ITextDocument2Old_fnOpen (ITextDocument2Old *iface, VARIANT *pVar, LONG Flags, LONG CodePage)
 
static HRESULT WINAPI ITextDocument2Old_fnSave (ITextDocument2Old *iface, VARIANT *pVar, LONG Flags, LONG CodePage)
 
static HRESULT WINAPI ITextDocument2Old_fnFreeze (ITextDocument2Old *iface, LONG *pCount)
 
static HRESULT WINAPI ITextDocument2Old_fnUnfreeze (ITextDocument2Old *iface, LONG *pCount)
 
static HRESULT WINAPI ITextDocument2Old_fnBeginEditCollection (ITextDocument2Old *iface)
 
static HRESULT WINAPI ITextDocument2Old_fnEndEditCollection (ITextDocument2Old *iface)
 
static HRESULT WINAPI ITextDocument2Old_fnUndo (ITextDocument2Old *iface, LONG Count, LONG *prop)
 
static HRESULT WINAPI ITextDocument2Old_fnRedo (ITextDocument2Old *iface, LONG Count, LONG *prop)
 
static HRESULT WINAPI ITextDocument2Old_fnRange (ITextDocument2Old *iface, LONG cp1, LONG cp2, ITextRange **ppRange)
 
static HRESULT WINAPI ITextDocument2Old_fnRangeFromPoint (ITextDocument2Old *iface, LONG x, LONG y, ITextRange **ppRange)
 
static HRESULT WINAPI ITextDocument2Old_fnAttachMsgFilter (ITextDocument2Old *iface, IUnknown *filter)
 
static HRESULT WINAPI ITextDocument2Old_fnSetEffectColor (ITextDocument2Old *iface, LONG index, COLORREF cr)
 
static HRESULT WINAPI ITextDocument2Old_fnGetEffectColor (ITextDocument2Old *iface, LONG index, COLORREF *cr)
 
static HRESULT WINAPI ITextDocument2Old_fnGetCaretType (ITextDocument2Old *iface, LONG *type)
 
static HRESULT WINAPI ITextDocument2Old_fnSetCaretType (ITextDocument2Old *iface, LONG type)
 
static HRESULT WINAPI ITextDocument2Old_fnGetImmContext (ITextDocument2Old *iface, LONG *context)
 
static HRESULT WINAPI ITextDocument2Old_fnReleaseImmContext (ITextDocument2Old *iface, LONG context)
 
static HRESULT WINAPI ITextDocument2Old_fnGetPreferredFont (ITextDocument2Old *iface, LONG cp, LONG charrep, LONG options, LONG current_charrep, LONG current_fontsize, BSTR *bstr, LONG *pitch_family, LONG *new_fontsize)
 
static HRESULT WINAPI ITextDocument2Old_fnGetNotificationMode (ITextDocument2Old *iface, LONG *mode)
 
static HRESULT WINAPI ITextDocument2Old_fnSetNotificationMode (ITextDocument2Old *iface, LONG mode)
 
static HRESULT WINAPI ITextDocument2Old_fnGetClientRect (ITextDocument2Old *iface, LONG type, LONG *left, LONG *top, LONG *right, LONG *bottom)
 
static HRESULT WINAPI ITextDocument2Old_fnGetSelectionEx (ITextDocument2Old *iface, ITextSelection **selection)
 
static HRESULT WINAPI ITextDocument2Old_fnGetWindow (ITextDocument2Old *iface, LONG *hwnd)
 
static HRESULT WINAPI ITextDocument2Old_fnGetFEFlags (ITextDocument2Old *iface, LONG *flags)
 
static HRESULT WINAPI ITextDocument2Old_fnUpdateWindow (ITextDocument2Old *iface)
 
static HRESULT WINAPI ITextDocument2Old_fnCheckTextLimit (ITextDocument2Old *iface, LONG cch, LONG *exceed)
 
static HRESULT WINAPI ITextDocument2Old_fnIMEInProgress (ITextDocument2Old *iface, LONG mode)
 
static HRESULT WINAPI ITextDocument2Old_fnSysBeep (ITextDocument2Old *iface)
 
static HRESULT WINAPI ITextDocument2Old_fnUpdate (ITextDocument2Old *iface, LONG mode)
 
static HRESULT WINAPI ITextDocument2Old_fnNotify (ITextDocument2Old *iface, LONG notify)
 
static HRESULT WINAPI ITextSelection_fnQueryInterface (ITextSelection *me, REFIID riid, void **ppvObj)
 
static ULONG WINAPI ITextSelection_fnAddRef (ITextSelection *me)
 
static ULONG WINAPI ITextSelection_fnRelease (ITextSelection *me)
 
static HRESULT WINAPI ITextSelection_fnGetTypeInfoCount (ITextSelection *me, UINT *pctinfo)
 
static HRESULT WINAPI ITextSelection_fnGetTypeInfo (ITextSelection *me, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
 
static HRESULT WINAPI ITextSelection_fnGetIDsOfNames (ITextSelection *me, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
 
static HRESULT WINAPI ITextSelection_fnInvoke (ITextSelection *me, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
 
static HRESULT WINAPI ITextSelection_fnGetText (ITextSelection *me, BSTR *pbstr)
 
static HRESULT WINAPI ITextSelection_fnSetText (ITextSelection *me, BSTR str)
 
static HRESULT WINAPI ITextSelection_fnGetChar (ITextSelection *me, LONG *pch)
 
static HRESULT WINAPI ITextSelection_fnSetChar (ITextSelection *me, LONG ch)
 
static HRESULT WINAPI ITextSelection_fnGetDuplicate (ITextSelection *me, ITextRange **range)
 
static HRESULT WINAPI ITextSelection_fnGetFormattedText (ITextSelection *me, ITextRange **range)
 
static HRESULT WINAPI ITextSelection_fnSetFormattedText (ITextSelection *me, ITextRange *range)
 
static HRESULT WINAPI ITextSelection_fnGetStart (ITextSelection *me, LONG *pcpFirst)
 
static HRESULT WINAPI ITextSelection_fnSetStart (ITextSelection *me, LONG value)
 
static HRESULT WINAPI ITextSelection_fnGetEnd (ITextSelection *me, LONG *pcpLim)
 
static HRESULT WINAPI ITextSelection_fnSetEnd (ITextSelection *me, LONG value)
 
static HRESULT WINAPI ITextSelection_fnGetFont (ITextSelection *me, ITextFont **font)
 
static HRESULT WINAPI ITextSelection_fnSetFont (ITextSelection *me, ITextFont *font)
 
static HRESULT WINAPI ITextSelection_fnGetPara (ITextSelection *me, ITextPara **para)
 
static HRESULT WINAPI ITextSelection_fnSetPara (ITextSelection *me, ITextPara *para)
 
static HRESULT WINAPI ITextSelection_fnGetStoryLength (ITextSelection *me, LONG *length)
 
static HRESULT WINAPI ITextSelection_fnGetStoryType (ITextSelection *me, LONG *value)
 
static HRESULT WINAPI ITextSelection_fnCollapse (ITextSelection *me, LONG bStart)
 
static HRESULT WINAPI ITextSelection_fnExpand (ITextSelection *me, LONG unit, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnGetIndex (ITextSelection *me, LONG unit, LONG *index)
 
static HRESULT WINAPI ITextSelection_fnSetIndex (ITextSelection *me, LONG unit, LONG index, LONG extend)
 
static HRESULT WINAPI ITextSelection_fnSetRange (ITextSelection *me, LONG anchor, LONG active)
 
static HRESULT WINAPI ITextSelection_fnInRange (ITextSelection *me, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextSelection_fnInStory (ITextSelection *me, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextSelection_fnIsEqual (ITextSelection *me, ITextRange *range, LONG *ret)
 
static HRESULT WINAPI ITextSelection_fnSelect (ITextSelection *me)
 
static HRESULT WINAPI ITextSelection_fnStartOf (ITextSelection *me, LONG unit, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnEndOf (ITextSelection *me, LONG unit, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMove (ITextSelection *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveStart (ITextSelection *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveEnd (ITextSelection *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveWhile (ITextSelection *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveStartWhile (ITextSelection *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveEndWhile (ITextSelection *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveUntil (ITextSelection *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveStartUntil (ITextSelection *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveEndUntil (ITextSelection *me, VARIANT *charset, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnFindText (ITextSelection *me, BSTR text, LONG count, LONG flags, LONG *length)
 
static HRESULT WINAPI ITextSelection_fnFindTextStart (ITextSelection *me, BSTR text, LONG count, LONG flags, LONG *length)
 
static HRESULT WINAPI ITextSelection_fnFindTextEnd (ITextSelection *me, BSTR text, LONG count, LONG flags, LONG *length)
 
static HRESULT WINAPI ITextSelection_fnDelete (ITextSelection *me, LONG unit, LONG count, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnCut (ITextSelection *me, VARIANT *v)
 
static HRESULT WINAPI ITextSelection_fnCopy (ITextSelection *me, VARIANT *v)
 
static HRESULT WINAPI ITextSelection_fnPaste (ITextSelection *me, VARIANT *v, LONG format)
 
static HRESULT WINAPI ITextSelection_fnCanPaste (ITextSelection *me, VARIANT *v, LONG format, LONG *ret)
 
static HRESULT WINAPI ITextSelection_fnCanEdit (ITextSelection *me, LONG *ret)
 
static HRESULT WINAPI ITextSelection_fnChangeCase (ITextSelection *me, LONG type)
 
static HRESULT WINAPI ITextSelection_fnGetPoint (ITextSelection *me, LONG type, LONG *cx, LONG *cy)
 
static HRESULT WINAPI ITextSelection_fnSetPoint (ITextSelection *me, LONG x, LONG y, LONG type, LONG extend)
 
static HRESULT WINAPI ITextSelection_fnScrollIntoView (ITextSelection *me, LONG value)
 
static HRESULT WINAPI ITextSelection_fnGetEmbeddedObject (ITextSelection *me, IUnknown **ppv)
 
static HRESULT WINAPI ITextSelection_fnGetFlags (ITextSelection *me, LONG *flags)
 
static HRESULT WINAPI ITextSelection_fnSetFlags (ITextSelection *me, LONG flags)
 
static HRESULT WINAPI ITextSelection_fnGetType (ITextSelection *me, LONG *type)
 
static HRESULT WINAPI ITextSelection_fnMoveLeft (ITextSelection *me, LONG unit, LONG count, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveRight (ITextSelection *me, LONG unit, LONG count, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveUp (ITextSelection *me, LONG unit, LONG count, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnMoveDown (ITextSelection *me, LONG unit, LONG count, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnHomeKey (ITextSelection *me, LONG unit, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnEndKey (ITextSelection *me, LONG unit, LONG extend, LONG *delta)
 
static HRESULT WINAPI ITextSelection_fnTypeText (ITextSelection *me, BSTR text)
 
static void convert_sizel (const ME_Context *c, const SIZEL *szl, SIZE *sz)
 
void ME_GetOLEObjectSize (const ME_Context *c, ME_Run *run, SIZE *pSize)
 
void draw_ole (ME_Context *c, int x, int y, ME_Run *run, BOOL selected)
 
void ME_DeleteReObject (struct re_object *reobj)
 
void ME_CopyReObject (REOBJECT *dst, const REOBJECT *src, DWORD flags)
 
void richole_release_children (struct text_services *services)
 

Variables

static ITypeLibtypelib
 
static const IID *const tid_ids []
 
static ITypeInfotypeinfos [LAST_tid]
 
static const DWORD textfont_prop_masks [][2]
 
static const IOleClientSiteVtbl ocst
 
static const IOleInPlaceSiteVtbl olestvt
 
const IRichEditOleVtbl re_ole_vtbl
 
static const ITextRangeVtbl trvt
 
static ITextFontVtbl textfontvtbl
 
static ITextParaVtbl textparavtbl
 
const ITextDocument2OldVtbl text_doc2old_vtbl
 
static const ITextSelectionVtbl tsvt
 

Macro Definition Documentation

◆ CHARFORMAT_SET_B_FIELD

#define CHARFORMAT_SET_B_FIELD (   mask,
  value 
)
Value:
if (hr == S_OK && value != tomUndefined) { \
fmt.dwMask |= CFM_##mask; \
if (value == tomTrue) fmt.dwEffects |= CFE_##mask; \
} \
GLenum GLint GLuint mask
Definition: glext.h:6028
#define S_OK
Definition: intsafe.h:52
HRESULT hr
Definition: shlfolder.c:183
Definition: dsound.c:943
@ tomTrue
Definition: tom.idl:29
@ tomUndefined
Definition: tom.idl:30
Definition: pdh_main.c:96

◆ COBJMACROS

#define COBJMACROS

Definition at line 25 of file richole.c.

◆ NONAMELESSUNION

#define NONAMELESSUNION

Definition at line 24 of file richole.c.

Typedef Documentation

◆ IOleClientSiteImpl

Definition at line 139 of file richole.c.

◆ ITextFontImpl

◆ ITextParaImpl

◆ ITextRangeImpl

Definition at line 140 of file richole.c.

Enumeration Type Documentation

◆ range_update_op

Enumerator
RANGE_UPDATE_DELETE 

Definition at line 204 of file richole.c.

204 {
206};
@ RANGE_UPDATE_DELETE
Definition: richole.c:205

◆ textfont_prop_id

Enumerator
FONT_ALLCAPS 
FONT_ANIMATION 
FONT_BACKCOLOR 
FONT_BOLD 
FONT_EMBOSS 
FONT_FORECOLOR 
FONT_HIDDEN 
FONT_ENGRAVE 
FONT_ITALIC 
FONT_KERNING 
FONT_LANGID 
FONT_NAME 
FONT_OUTLINE 
FONT_POSITION 
FONT_PROTECTED 
FONT_SHADOW 
FONT_SIZE 
FONT_SMALLCAPS 
FONT_SPACING 
FONT_STRIKETHROUGH 
FONT_SUBSCRIPT 
FONT_SUPERSCRIPT 
FONT_UNDERLINE 
FONT_WEIGHT 
FONT_PROPID_LAST 
FONT_PROPID_FIRST 

Definition at line 142 of file richole.c.

142 {
143 FONT_ALLCAPS = 0,
146 FONT_BOLD,
154 FONT_NAME,
159 FONT_SIZE,
169};
@ FONT_SPACING
Definition: richole.c:161
@ FONT_UNDERLINE
Definition: richole.c:165
@ FONT_OUTLINE
Definition: richole.c:155
@ FONT_SIZE
Definition: richole.c:159
@ FONT_PROPID_LAST
Definition: richole.c:167
@ FONT_BACKCOLOR
Definition: richole.c:145
@ FONT_HIDDEN
Definition: richole.c:149
@ FONT_STRIKETHROUGH
Definition: richole.c:162
@ FONT_SUPERSCRIPT
Definition: richole.c:164
@ FONT_SMALLCAPS
Definition: richole.c:160
@ FONT_PROTECTED
Definition: richole.c:157
@ FONT_EMBOSS
Definition: richole.c:147
@ FONT_ALLCAPS
Definition: richole.c:143
@ FONT_ENGRAVE
Definition: richole.c:150
@ FONT_SUBSCRIPT
Definition: richole.c:163
@ FONT_BOLD
Definition: richole.c:146
@ FONT_LANGID
Definition: richole.c:153
@ FONT_PROPID_FIRST
Definition: richole.c:168
@ FONT_FORECOLOR
Definition: richole.c:148
@ FONT_POSITION
Definition: richole.c:156
@ FONT_NAME
Definition: richole.c:154
@ FONT_ANIMATION
Definition: richole.c:144
@ FONT_KERNING
Definition: richole.c:152
@ FONT_SHADOW
Definition: richole.c:158
@ FONT_WEIGHT
Definition: richole.c:166
@ FONT_ITALIC
Definition: richole.c:151

◆ tid_t

Enumerator
LAST_tid 
LAST_tid 
Database_tid 
Installer_tid 
Record_tid 
Session_tid 
StringList_tid 
SummaryInfo_tid 
View_tid 
LAST_tid 
NULL_tid 
IXMLDOMAttribute_tid 
IXMLDOMCDATASection_tid 
IXMLDOMComment_tid 
IXMLDOMDocument_tid 
IXMLDOMDocument2_tid 
IXMLDOMDocument3_tid 
IXMLDOMDocumentFragment_tid 
IXMLDOMDocumentType_tid 
IXMLDOMElement_tid 
IXMLDOMEntityReference_tid 
IXMLDOMImplementation_tid 
IXMLDOMNamedNodeMap_tid 
IXMLDOMNode_tid 
IXMLDOMNodeList_tid 
IXMLDOMParseError2_tid 
IXMLDOMProcessingInstruction_tid 
IXMLDOMSchemaCollection_tid 
IXMLDOMSchemaCollection2_tid 
IXMLDOMSelection_tid 
IXMLDOMText_tid 
IXMLElement_tid 
IXMLDocument_tid 
IXMLHTTPRequest_tid 
IXSLProcessor_tid 
IXSLTemplate_tid 
IVBSAXAttributes_tid 
IVBSAXContentHandler_tid 
IVBSAXDeclHandler_tid 
IVBSAXDTDHandler_tid 
IVBSAXEntityResolver_tid 
IVBSAXErrorHandler_tid 
IVBSAXLexicalHandler_tid 
IVBSAXLocator_tid 
IVBSAXXMLFilter_tid 
IVBSAXXMLReader_tid 
IMXAttributes_tid 
IMXReaderControl_tid 
IMXWriter_tid 
IVBMXNamespaceManager_tid 
IServerXMLHTTPRequest_tid 
LAST_tid 
NULL_tid 
ITextDocument_tid 
ITextRange_tid 
ITextSelection_tid 
ITextFont_tid 
ITextPara_tid 
LAST_tid 
NULL_tid 
IDictionary_tid 
IDrive_tid 
IDriveCollection_tid 
IFile_tid 
IFileCollection_tid 
IFileSystem3_tid 
IFolder_tid 
IFolderCollection_tid 
ITextStream_tid 
LAST_tid 
NULL_tid 
IWshCollection_tid 
IWshEnvironment_tid 
IWshExec_tid 
IWshShell3_tid 
IWshShortcut_tid 
LAST_tid 

Definition at line 57 of file richole.c.

57 {
65};
@ ITextSelection_tid
Definition: richole.c:61
@ LAST_tid
Definition: richole.c:64
@ ITextPara_tid
Definition: richole.c:63
@ NULL_tid
Definition: richole.c:58
@ ITextRange_tid
Definition: richole.c:60
@ ITextDocument_tid
Definition: richole.c:59
@ ITextFont_tid
Definition: richole.c:62

Function Documentation

◆ convert_sizel()

static void convert_sizel ( const ME_Context c,
const SIZEL szl,
SIZE sz 
)
static

Definition at line 5637 of file richole.c.

5638{
5639 /* sizel is in .01 millimeters, sz in pixels */
5640 sz->cx = MulDiv(szl->cx, c->dpi.cx, 2540);
5641 sz->cy = MulDiv(szl->cy, c->dpi.cy, 2540);
5642}
const GLubyte * c
Definition: glext.h:8905
INT WINAPI MulDiv(INT nNumber, INT nNumerator, INT nDenominator)
Definition: muldiv.c:25
LONG cx
Definition: kdterminal.h:27
LONG cy
Definition: kdterminal.h:28

Referenced by draw_ole(), and ME_GetOLEObjectSize().

◆ cp2range()

static void cp2range ( ME_TextEditor editor,
LONG cp1,
LONG cp2 
)
static

Definition at line 1938 of file richole.c.

1939{
1940 int len = ME_GetTextLength(editor) + 1;
1941
1942 *cp1 = max(*cp1, 0);
1943 *cp2 = max(*cp2, 0);
1944 *cp1 = min(*cp1, len);
1945 *cp2 = min(*cp2, len);
1946 if (*cp1 > *cp2)
1947 {
1948 int tmp = *cp1;
1949 *cp1 = *cp2;
1950 *cp2 = tmp;
1951 }
1952 if (*cp1 == len)
1953 *cp1 = *cp2 = len - 1;
1954}
int ME_GetTextLength(ME_TextEditor *editor)
Definition: caret.c:83
GLenum GLsizei len
Definition: glext.h:6722
#define min(a, b)
Definition: monoChain.cc:55
#define max(a, b)
Definition: svc.c:63

Referenced by ITextDocument2Old_fnRange(), and ITextRange_fnSetRange().

◆ create_textfont()

static HRESULT create_textfont ( ITextRange range,
const ITextFontImpl src,
ITextFont **  ret 
)
static

Definition at line 3476 of file richole.c.

3477{
3479
3480 *ret = NULL;
3481 font = heap_alloc(sizeof(*font));
3482 if (!font)
3483 return E_OUTOFMEMORY;
3484
3485 font->ITextFont_iface.lpVtbl = &textfontvtbl;
3486 font->ref = 1;
3487
3488 if (src) {
3489 font->range = NULL;
3490 font->get_cache_enabled = TRUE;
3491 font->set_cache_enabled = TRUE;
3492 memcpy(&font->props, &src->props, sizeof(font->props));
3493 if (font->props[FONT_NAME].str)
3494 font->props[FONT_NAME].str = SysAllocString(font->props[FONT_NAME].str);
3495 }
3496 else {
3497 font->range = range;
3498 ITextRange_AddRef(range);
3499
3500 /* cache current properties */
3501 font->get_cache_enabled = FALSE;
3502 font->set_cache_enabled = FALSE;
3504 }
3505
3506 *ret = &font->ITextFont_iface;
3507 return S_OK;
3508}
static void * heap_alloc(size_t len)
Definition: appwiz.h:66
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
static ITextFontVtbl textfontvtbl
Definition: richole.c:3411
static void textfont_cache_range_props(ITextFontImpl *font)
Definition: richole.c:870
GLenum src
Definition: glext.h:6340
GLenum GLint * range
Definition: glext.h:7539
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
Definition: mk_font.cpp:20
BSTR WINAPI SysAllocString(LPCOLESTR str)
Definition: oleaut.c:238
int ret

Referenced by ITextRange_fnGetFont(), ITextSelection_fnGetFont(), and TextFont_GetDuplicate().

◆ create_textpara()

static HRESULT create_textpara ( ITextRange range,
ITextPara **  ret 
)
static

Definition at line 4011 of file richole.c.

4012{
4013 ITextParaImpl *para;
4014
4015 *ret = NULL;
4016 para = heap_alloc(sizeof(*para));
4017 if (!para)
4018 return E_OUTOFMEMORY;
4019
4020 para->ITextPara_iface.lpVtbl = &textparavtbl;
4021 para->ref = 1;
4022 para->range = range;
4023 ITextRange_AddRef(range);
4024
4025 *ret = &para->ITextPara_iface;
4026 return S_OK;
4027}
static ITextParaVtbl textparavtbl
Definition: richole.c:3953
ITextPara ITextPara_iface
Definition: richole.c:231
ITextRange * range
Definition: richole.c:234

Referenced by ITextRange_fnGetPara(), and ITextSelection_fnGetPara().

◆ CreateITextRange()

static HRESULT CreateITextRange ( struct text_services services,
LONG  start,
LONG  end,
ITextRange **  ppRange 
)
static

Definition at line 4247 of file richole.c.

4248{
4249 ITextRangeImpl *txtRge = heap_alloc(sizeof(ITextRangeImpl));
4250
4251 if (!txtRge)
4252 return E_OUTOFMEMORY;
4253 txtRge->ITextRange_iface.lpVtbl = &trvt;
4254 txtRge->ref = 1;
4255 txtRge->child.reole = services;
4256 txtRge->start = start;
4257 txtRge->end = end;
4258 list_add_head( &services->rangelist, &txtRge->child.entry );
4259 *ppRange = &txtRge->ITextRange_iface;
4260 return S_OK;
4261}
static void list_add_head(struct list_entry *head, struct list_entry *entry)
Definition: list.h:76
static const ITextRangeVtbl trvt
Definition: richole.c:2666
GLuint start
Definition: gl.h:1545
GLuint GLuint end
Definition: gl.h:1545
ITextRange ITextRange_iface
Definition: richole.c:215
struct reole_child child
Definition: richole.c:214

Referenced by ITextDocument2Old_fnRange(), ITextRange_fnGetDuplicate(), and ITextSelection_fnGetDuplicate().

◆ CreateOleClientSite()

static HRESULT CreateOleClientSite ( struct text_services services,
IOleClientSite **  ret 
)
static

Definition at line 1214 of file richole.c.

1215{
1216 IOleClientSiteImpl *clientSite = heap_alloc(sizeof *clientSite);
1217
1218 if (!clientSite)
1219 return E_OUTOFMEMORY;
1220
1221 clientSite->IOleClientSite_iface.lpVtbl = &ocst;
1222 clientSite->IOleInPlaceSite_iface.lpVtbl = &olestvt;
1223 clientSite->ref = 1;
1224 clientSite->child.reole = services;
1225 list_add_head( &services->clientsites, &clientSite->child.entry );
1226
1227 *ret = &clientSite->IOleClientSite_iface;
1228 return S_OK;
1229}
static const IOleInPlaceSiteVtbl olestvt
Definition: richole.c:1195
static const IOleClientSiteVtbl ocst
Definition: richole.c:1070
struct reole_child child
Definition: richole.c:238
IOleClientSite IOleClientSite_iface
Definition: richole.c:239
IOleInPlaceSite IOleInPlaceSite_iface
Definition: richole.c:240

Referenced by IRichEditOle_fnGetClientSite().

◆ DEFINE_GUID() [1/11]

DEFINE_GUID ( IID_Igetrichole  ,
0xe3ce5c7a  ,
0x8247  ,
0x4622  ,
0x81  ,
0xad  ,
0x11  ,
0x81  ,
0x02  ,
0xaa  ,
0x01  ,
0x30   
)

◆ DEFINE_GUID() [2/11]

DEFINE_GUID ( IID_ITextDocument  ,
0x8cc497c0  ,
0xa1df  ,
0x11ce  ,
0x80  ,
0x98  ,
0x00  ,
0xaa  ,
0x00  ,
0x47  ,
0xbe  ,
0x5d   
)

◆ DEFINE_GUID() [3/11]

DEFINE_GUID ( IID_ITextDocument2Old  ,
0x01c25500  ,
0x4268  ,
0x11d1  ,
0x88  ,
0x3a  ,
0x3c  ,
0x8b  ,
0x00  ,
0xc1  ,
0x00  ,
0x00   
)

◆ DEFINE_GUID() [4/11]

DEFINE_GUID ( IID_ITextFont  ,
0x8cc497c3  ,
0xa1df  ,
0x11ce  ,
0x80  ,
0x98  ,
0x00  ,
0xaa  ,
0x00  ,
0x47  ,
0xbe  ,
0x5d   
)

◆ DEFINE_GUID() [5/11]

DEFINE_GUID ( IID_ITextHost  ,
0x13e670f4  ,
0x1a5a  ,
0x11cf  ,
0xab  ,
0xeb  ,
0x00  ,
0xaa  ,
0x00  ,
0xb6  ,
0x5e  ,
0xa1   
)

◆ DEFINE_GUID() [6/11]

DEFINE_GUID ( IID_ITextHost2  ,
0x13e670f5  ,
0x1a5a  ,
0x11cf  ,
0xab  ,
0xeb  ,
0x00  ,
0xaa  ,
0x00  ,
0xb6  ,
0x5e  ,
0xa1   
)

◆ DEFINE_GUID() [7/11]

DEFINE_GUID ( IID_ITextPara  ,
0x8cc497c4  ,
0xa1df  ,
0x11ce  ,
0x80  ,
0x98  ,
0x00  ,
0xaa  ,
0x00  ,
0x47  ,
0xbe  ,
0x5d   
)

◆ DEFINE_GUID() [8/11]

DEFINE_GUID ( IID_ITextRange  ,
0x8cc497c2  ,
0xa1df  ,
0x11ce  ,
0x80  ,
0x98  ,
0x00  ,
0xaa  ,
0x00  ,
0x47  ,
0xbe  ,
0x5d   
)

◆ DEFINE_GUID() [9/11]

DEFINE_GUID ( IID_ITextSelection  ,
0x8cc497c1  ,
0xa1df  ,
0x11ce  ,
0x80  ,
0x98  ,
0x00  ,
0xaa  ,
0x00  ,
0x47  ,
0xbe  ,
0x5d   
)

◆ DEFINE_GUID() [10/11]

DEFINE_GUID ( IID_ITextServices  ,
0x8d33f740  ,
0xcf58  ,
0x11ce  ,
0xa8  ,
0x9d  ,
0x00  ,
0xaa  ,
0x00  ,
0x6c  ,
0xad  ,
0xc5   
)

◆ DEFINE_GUID() [11/11]

DEFINE_GUID ( LIBID_tom  ,
0x8cc497c9  ,
0xa1df  ,
0x11ce  ,
0x80  ,
0x98  ,
0x00  ,
0xaa  ,
0x00  ,
0x47  ,
0xbe  ,
0x5d   
)

◆ draw_ole()

void draw_ole ( ME_Context c,
int  x,
int  y,
ME_Run run,
BOOL  selected 
)

Definition at line 5726 of file richole.c.

5727{
5728 IDataObject* ido;
5729 FORMATETC fmt;
5730 STGMEDIUM stgm;
5731 DIBSECTION dibsect;
5732 ENHMETAHEADER emh;
5733 HDC hMemDC;
5734 SIZE sz;
5735 BOOL has_size;
5736 HBITMAP old_bm;
5737 RECT rc;
5738
5739 assert(run->nFlags & MERF_GRAPHICS);
5740 assert(run->reobj);
5741 if (IOleObject_QueryInterface(run->reobj->obj.poleobj, &IID_IDataObject, (void**)&ido) != S_OK)
5742 {
5743 FIXME("Couldn't get interface\n");
5744 return;
5745 }
5746 has_size = run->reobj->obj.sizel.cx != 0 || run->reobj->obj.sizel.cy != 0;
5747 fmt.cfFormat = CF_BITMAP;
5748 fmt.ptd = NULL;
5749 fmt.dwAspect = DVASPECT_CONTENT;
5750 fmt.lindex = -1;
5751 fmt.tymed = TYMED_GDI;
5752 if (IDataObject_GetData(ido, &fmt, &stgm) != S_OK)
5753 {
5754 fmt.cfFormat = CF_ENHMETAFILE;
5755 fmt.tymed = TYMED_ENHMF;
5756 if (IDataObject_GetData(ido, &fmt, &stgm) != S_OK)
5757 {
5758 FIXME("Couldn't get storage medium\n");
5759 IDataObject_Release(ido);
5760 return;
5761 }
5762 }
5763 IDataObject_Release(ido);
5764
5765 switch (stgm.tymed)
5766 {
5767 case TYMED_GDI:
5768 GetObjectW(stgm.u.hBitmap, sizeof(dibsect), &dibsect);
5769 hMemDC = CreateCompatibleDC(c->hDC);
5770 old_bm = SelectObject(hMemDC, stgm.u.hBitmap);
5771 if (has_size)
5772 {
5773 convert_sizel(c, &run->reobj->obj.sizel, &sz);
5774 } else {
5775 sz.cx = dibsect.dsBm.bmWidth;
5776 sz.cy = dibsect.dsBm.bmHeight;
5777 }
5778 if (c->editor->nZoomNumerator != 0)
5779 {
5780 sz.cx = MulDiv(sz.cx, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5781 sz.cy = MulDiv(sz.cy, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5782 }
5783 StretchBlt(c->hDC, x, y - sz.cy, sz.cx, sz.cy,
5784 hMemDC, 0, 0, dibsect.dsBm.bmWidth, dibsect.dsBm.bmHeight, SRCCOPY);
5785
5786 SelectObject(hMemDC, old_bm);
5787 DeleteDC(hMemDC);
5788 break;
5789 case TYMED_ENHMF:
5790 GetEnhMetaFileHeader(stgm.u.hEnhMetaFile, sizeof(emh), &emh);
5791 if (has_size)
5792 {
5793 convert_sizel(c, &run->reobj->obj.sizel, &sz);
5794 } else {
5795 sz.cx = emh.rclBounds.right - emh.rclBounds.left;
5796 sz.cy = emh.rclBounds.bottom - emh.rclBounds.top;
5797 }
5798 if (c->editor->nZoomNumerator != 0)
5799 {
5800 sz.cx = MulDiv(sz.cx, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5801 sz.cy = MulDiv(sz.cy, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5802 }
5803
5804 rc.left = x;
5805 rc.top = y - sz.cy;
5806 rc.right = x + sz.cx;
5807 rc.bottom = y;
5808 PlayEnhMetaFile(c->hDC, stgm.u.hEnhMetaFile, &rc);
5809 break;
5810 default:
5811 FIXME("Unsupported tymed %d\n", stgm.tymed);
5812 selected = FALSE;
5813 break;
5814 }
5815 ReleaseStgMedium(&stgm);
5816
5817 if (selected && !c->editor->bHideSelection)
5818 PatBlt(c->hDC, x, y - sz.cy, sz.cx, sz.cy, DSTINVERT);
5819}
#define CF_BITMAP
Definition: constants.h:397
#define CF_ENHMETAFILE
Definition: constants.h:409
#define FIXME(fmt,...)
Definition: precomp.h:53
static char selected[MAX_PATH+1]
Definition: dirdlg.c:7
void WINAPI ReleaseStgMedium(STGMEDIUM *pmedium)
Definition: ole2.c:2033
static void convert_sizel(const ME_Context *c, const SIZEL *szl, SIZE *sz)
Definition: richole.c:5637
#define assert(x)
Definition: debug.h:53
#define MERF_GRAPHICS
Definition: editstr.h:104
unsigned int BOOL
Definition: ntddk_ex.h:94
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
static HBITMAP
Definition: button.c:44
static HDC
Definition: imagelist.c:88
const GUID IID_IDataObject
long bottom
Definition: polytest.cpp:53
long right
Definition: polytest.cpp:53
long top
Definition: polytest.cpp:53
long left
Definition: polytest.cpp:53
LONG bmHeight
Definition: wingdi.h:1423
LONG bmWidth
Definition: wingdi.h:1422
BITMAP dsBm
Definition: wingdi.h:1669
RECTL rclBounds
Definition: wingdi.h:2322
struct re_object * reobj
Definition: editstr.h:167
int nFlags
Definition: editstr.h:164
LONG right
Definition: windef.h:308
LONG bottom
Definition: windef.h:309
LONG top
Definition: windef.h:307
LONG left
Definition: windef.h:306
int WINAPI GetObjectW(_In_ HANDLE h, _In_ int c, _Out_writes_bytes_opt_(c) LPVOID pv)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
Definition: dc.c:1546
HDC WINAPI CreateCompatibleDC(_In_opt_ HDC hdc)
BOOL WINAPI StretchBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_opt_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
#define SRCCOPY
Definition: wingdi.h:333
#define DSTINVERT
Definition: wingdi.h:327
BOOL WINAPI PatBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
UINT WINAPI GetEnhMetaFileHeader(_In_ HENHMETAFILE hemf, _In_ UINT nSize, _Out_writes_bytes_opt_(nSize) LPENHMETAHEADER lpEnhMetaHeader)
BOOL WINAPI DeleteDC(_In_ HDC)
BOOL WINAPI PlayEnhMetaFile(_In_ HDC, _In_ HENHMETAFILE, _In_ LPCRECT)

Referenced by draw_run().

◆ get_range_reole()

static const struct text_services * get_range_reole ( ITextRange range)
inlinestatic

Definition at line 484 of file richole.c.

485{
486 struct text_services *services = NULL;
487 ITextRange_QueryInterface(range, &IID_Igetrichole, (void**)&services);
488 return services;
489}

Referenced by get_textfont_prop(), set_textfont_prop(), TextFont_GetDuplicate(), textfont_getname_from_range(), TextFont_Reset(), and textrange_set_font().

◆ get_textfont_prop()

static HRESULT get_textfont_prop ( const ITextFontImpl font,
enum textfont_prop_id  propid,
textfont_prop_val value 
)
static

Definition at line 653 of file richole.c.

654{
655 const struct text_services *services;
657 LONG start, end, i;
658 HRESULT hr;
659
660 /* when font is not attached to any range use cached values */
661 if (!font->range || font->get_cache_enabled) {
662 *value = font->props[propid];
663 return S_OK;
664 }
665
666 if (!(services = get_range_reole(font->range)))
667 return CO_E_RELEASED;
668
670
671 ITextRange_GetStart(font->range, &start);
672 ITextRange_GetEnd(font->range, &end);
673
674 /* iterate trough a range to see if property value is consistent */
676 if (FAILED(hr))
677 return hr;
678
679 for (i = start + 1; i < end; i++) {
681
682 hr = get_textfont_prop_for_pos( services, i, propid, &cur );
683 if (FAILED(hr))
684 return hr;
685
686 if (!is_equal_textfont_prop_value(propid, &v, &cur))
687 return S_OK;
688 }
689
690 *value = v;
691 return S_OK;
692}
static HRESULT get_textfont_prop_for_pos(const struct text_services *services, int pos, enum textfont_prop_id propid, textfont_prop_val *value)
Definition: richole.c:410
static BOOL is_equal_textfont_prop_value(enum textfont_prop_id propid, textfont_prop_val *left, textfont_prop_val *right)
Definition: richole.c:321
static void init_textfont_prop_value(enum textfont_prop_id propid, textfont_prop_val *v)
Definition: richole.c:359
static const struct text_services * get_range_reole(ITextRange *range)
Definition: richole.c:484
FxCollectionEntry * cur
const GLdouble * v
Definition: gl.h:2040
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define FAILED(hr)
Definition: intsafe.h:51
long LONG
Definition: pedump.c:60
#define CO_E_RELEASED
Definition: winerror.h:2818

Referenced by get_textfont_propf(), get_textfont_propl(), and textfont_cache_range_props().

◆ get_textfont_prop_for_pos()

static HRESULT get_textfont_prop_for_pos ( const struct text_services services,
int  pos,
enum textfont_prop_id  propid,
textfont_prop_val value 
)
static

Definition at line 410 of file richole.c.

412{
413 ME_Cursor from, to;
415
416 memset(&fmt, 0, sizeof(fmt));
417 fmt.cbSize = sizeof(fmt);
418 fmt.dwMask = textfont_prop_masks[propid][0];
419
421 to = from;
422 ME_MoveCursorChars( services->editor, &to, 1, FALSE );
423 ME_GetCharFormat( services->editor, &from, &to, &fmt );
424
425 switch (propid)
426 {
427 case FONT_ALLCAPS:
428 case FONT_BOLD:
429 case FONT_EMBOSS:
430 case FONT_HIDDEN:
431 case FONT_ENGRAVE:
432 case FONT_ITALIC:
433 case FONT_OUTLINE:
434 case FONT_PROTECTED:
435 case FONT_SHADOW:
436 case FONT_SMALLCAPS:
438 case FONT_SUBSCRIPT:
439 case FONT_SUPERSCRIPT:
440 case FONT_UNDERLINE:
441 value->l = fmt.dwEffects & textfont_prop_masks[propid][1] ? tomTrue : tomFalse;
442 break;
443 case FONT_ANIMATION:
444 value->l = fmt.bAnimation;
445 break;
446 case FONT_BACKCOLOR:
447 value->l = fmt.dwEffects & CFE_AUTOBACKCOLOR ? GetSysColor(COLOR_WINDOW) : fmt.crBackColor;
448 break;
449 case FONT_FORECOLOR:
450 value->l = fmt.dwEffects & CFE_AUTOCOLOR ? GetSysColor(COLOR_WINDOWTEXT) : fmt.crTextColor;
451 break;
452 case FONT_KERNING:
453 value->f = twips_to_points(fmt.wKerning);
454 break;
455 case FONT_LANGID:
456 value->l = fmt.lcid;
457 break;
458 case FONT_NAME:
459 /* this case is used exclusively by GetName() */
460 value->str = SysAllocString(fmt.szFaceName);
461 if (!value->str)
462 return E_OUTOFMEMORY;
463 break;
464 case FONT_POSITION:
465 value->f = twips_to_points(fmt.yOffset);
466 break;
467 case FONT_SIZE:
468 value->f = twips_to_points(fmt.yHeight);
469 break;
470 case FONT_SPACING:
471 value->f = fmt.sSpacing;
472 break;
473 case FONT_WEIGHT:
474 value->l = fmt.wWeight;
475 break;
476 default:
477 FIXME("unhandled font property %d\n", propid);
478 return E_FAIL;
479 }
480
481 return S_OK;
482}
#define E_FAIL
Definition: ddrawi.h:102
int ME_MoveCursorChars(ME_TextEditor *editor, ME_Cursor *cursor, int nRelOfs, BOOL final_eop)
Definition: caret.c:678
static const DWORD textfont_prop_masks[][2]
Definition: richole.c:171
static FLOAT twips_to_points(LONG value)
Definition: richole.c:400
void cursor_from_char_ofs(ME_TextEditor *editor, int char_ofs, ME_Cursor *cursor) DECLSPEC_HIDDEN
Definition: run.c:240
void ME_GetCharFormat(ME_TextEditor *editor, const ME_Cursor *from, const ME_Cursor *to, CHARFORMAT2W *pFmt) DECLSPEC_HIDDEN
Definition: run.c:871
#define CFE_AUTOCOLOR
Definition: richedit.h:414
#define CFE_AUTOBACKCOLOR
Definition: richedit.h:425
#define memset(x, y, z)
Definition: compat.h:39
CardRegion * from
Definition: spigame.cpp:19
@ tomFalse
Definition: tom.idl:28
DWORD WINAPI GetSysColor(_In_ int)
#define COLOR_WINDOW
Definition: winuser.h:921
#define COLOR_WINDOWTEXT
Definition: winuser.h:924

Referenced by get_textfont_prop(), and textfont_getname_from_range().

◆ get_textfont_propf()

static HRESULT get_textfont_propf ( const ITextFontImpl font,
enum textfont_prop_id  propid,
FLOAT value 
)
static

Definition at line 694 of file richole.c.

695{
697 HRESULT hr;
698
699 if (!value)
700 return E_INVALIDARG;
701
702 hr = get_textfont_prop(font, propid, &v);
703 *value = v.f;
704 return hr;
705}
#define E_INVALIDARG
Definition: ddrawi.h:101
static HRESULT get_textfont_prop(const ITextFontImpl *font, enum textfont_prop_id propid, textfont_prop_val *value)
Definition: richole.c:653

Referenced by TextFont_GetKerning(), TextFont_GetPosition(), TextFont_GetSize(), and TextFont_GetSpacing().

◆ get_textfont_propl()

◆ get_typeinfo()

static HRESULT get_typeinfo ( enum tid_t  tid,
ITypeInfo **  typeinfo 
)
static

Definition at line 108 of file richole.c.

109{
110 HRESULT hr;
111
112 if (!typelib)
113 hr = load_typelib();
114 if (!typelib)
115 return hr;
116
117 if (!typeinfos[tid])
118 {
119 ITypeInfo *ti;
120
121 hr = ITypeLib_GetTypeInfoOfGuid(typelib, tid_ids[tid], &ti);
122 if (FAILED(hr))
123 {
124 ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_guid(tid_ids[tid]), hr);
125 return hr;
126 }
127
129 ITypeInfo_Release(ti);
130 }
131
133 return S_OK;
134}
#define ERR(fmt,...)
Definition: precomp.h:57
static HRESULT load_typelib(void)
Definition: richole.c:78
static const IID *const tid_ids[]
Definition: richole.c:67
static ITypeInfo * typeinfos[LAST_tid]
Definition: richole.c:76
#define InterlockedCompareExchangePointer
Definition: interlocked.h:129
#define debugstr_guid
Definition: kernel32.h:35
static TfClientId tid

Referenced by ITextDocument2Old_fnGetIDsOfNames(), ITextDocument2Old_fnGetTypeInfo(), ITextDocument2Old_fnInvoke(), ITextRange_fnGetIDsOfNames(), ITextRange_fnGetTypeInfo(), ITextRange_fnInvoke(), ITextSelection_fnGetIDsOfNames(), ITextSelection_fnGetTypeInfo(), ITextSelection_fnInvoke(), TextFont_GetIDsOfNames(), TextFont_GetTypeInfo(), TextFont_Invoke(), TextPara_GetIDsOfNames(), TextPara_GetTypeInfo(), and TextPara_Invoke().

◆ impl_from_IOleClientSite()

◆ impl_from_IOleInPlaceSite()

◆ impl_from_IRichEditOle()

◆ impl_from_ITextDocument2Old()

static struct text_services * impl_from_ITextDocument2Old ( ITextDocument2Old iface)
inlinestatic

Definition at line 249 of file richole.c.

250{
251 return CONTAINING_RECORD( iface, struct text_services, ITextDocument2Old_iface );
252}

Referenced by ITextDocument2Old_fnAddRef(), ITextDocument2Old_fnAttachMsgFilter(), ITextDocument2Old_fnBeginEditCollection(), ITextDocument2Old_fnCheckTextLimit(), ITextDocument2Old_fnEndEditCollection(), ITextDocument2Old_fnFreeze(), ITextDocument2Old_fnGetCaretType(), ITextDocument2Old_fnGetClientRect(), ITextDocument2Old_fnGetDefaultTabStop(), ITextDocument2Old_fnGetEffectColor(), ITextDocument2Old_fnGetFEFlags(), ITextDocument2Old_fnGetIDsOfNames(), ITextDocument2Old_fnGetImmContext(), ITextDocument2Old_fnGetName(), ITextDocument2Old_fnGetNotificationMode(), ITextDocument2Old_fnGetPreferredFont(), ITextDocument2Old_fnGetSaved(), ITextDocument2Old_fnGetSelection(), ITextDocument2Old_fnGetSelectionEx(), ITextDocument2Old_fnGetStoryCount(), ITextDocument2Old_fnGetStoryRanges(), ITextDocument2Old_fnGetTypeInfo(), ITextDocument2Old_fnGetTypeInfoCount(), ITextDocument2Old_fnGetWindow(), ITextDocument2Old_fnIMEInProgress(), ITextDocument2Old_fnInvoke(), ITextDocument2Old_fnNew(), ITextDocument2Old_fnNotify(), ITextDocument2Old_fnOpen(), ITextDocument2Old_fnQueryInterface(), ITextDocument2Old_fnRange(), ITextDocument2Old_fnRangeFromPoint(), ITextDocument2Old_fnRedo(), ITextDocument2Old_fnRelease(), ITextDocument2Old_fnReleaseImmContext(), ITextDocument2Old_fnSave(), ITextDocument2Old_fnSetCaretType(), ITextDocument2Old_fnSetDefaultTabStop(), ITextDocument2Old_fnSetEffectColor(), ITextDocument2Old_fnSetNotificationMode(), ITextDocument2Old_fnSetSaved(), ITextDocument2Old_fnSysBeep(), ITextDocument2Old_fnUndo(), ITextDocument2Old_fnUnfreeze(), ITextDocument2Old_fnUpdate(), and ITextDocument2Old_fnUpdateWindow().

◆ impl_from_ITextFont()

static ITextFontImpl * impl_from_ITextFont ( ITextFont iface)
inlinestatic

Definition at line 269 of file richole.c.

270{
271 return CONTAINING_RECORD(iface, ITextFontImpl, ITextFont_iface);
272}

Referenced by TextFont_AddRef(), TextFont_CanChange(), TextFont_GetAllCaps(), TextFont_GetAnimation(), TextFont_GetBackColor(), TextFont_GetBold(), TextFont_GetDuplicate(), TextFont_GetEmboss(), TextFont_GetEngrave(), TextFont_GetForeColor(), TextFont_GetHidden(), TextFont_GetIDsOfNames(), TextFont_GetItalic(), TextFont_GetKerning(), TextFont_GetLanguageID(), TextFont_GetName(), TextFont_GetOutline(), TextFont_GetPosition(), TextFont_GetProtected(), TextFont_GetShadow(), TextFont_GetSize(), TextFont_GetSmallCaps(), TextFont_GetSpacing(), TextFont_GetStrikeThrough(), TextFont_GetStyle(), TextFont_GetSubscript(), TextFont_GetSuperscript(), TextFont_GetTypeInfo(), TextFont_GetTypeInfoCount(), TextFont_GetUnderline(), TextFont_GetWeight(), TextFont_Invoke(), TextFont_IsEqual(), TextFont_QueryInterface(), TextFont_Release(), TextFont_Reset(), TextFont_SetAllCaps(), TextFont_SetAnimation(), TextFont_SetBackColor(), TextFont_SetBold(), TextFont_SetDuplicate(), TextFont_SetEmboss(), TextFont_SetEngrave(), TextFont_SetForeColor(), TextFont_SetHidden(), TextFont_SetItalic(), TextFont_SetKerning(), TextFont_SetLanguageID(), TextFont_SetName(), TextFont_SetOutline(), TextFont_SetPosition(), TextFont_SetProtected(), TextFont_SetShadow(), TextFont_SetSize(), TextFont_SetSmallCaps(), TextFont_SetSpacing(), TextFont_SetStrikeThrough(), TextFont_SetStyle(), TextFont_SetSubscript(), TextFont_SetSuperscript(), TextFont_SetUnderline(), and TextFont_SetWeight().

◆ impl_from_ITextPara()

static ITextParaImpl * impl_from_ITextPara ( ITextPara iface)
inlinestatic

Definition at line 274 of file richole.c.

275{
276 return CONTAINING_RECORD(iface, ITextParaImpl, ITextPara_iface);
277}

Referenced by TextPara_AddRef(), TextPara_AddTab(), TextPara_CanChange(), TextPara_ClearAllTabs(), TextPara_DeleteTab(), TextPara_GetAlignment(), TextPara_GetDuplicate(), TextPara_GetFirstLineIndent(), TextPara_GetHyphenation(), TextPara_GetIDsOfNames(), TextPara_GetKeepTogether(), TextPara_GetKeepWithNext(), TextPara_GetLeftIndent(), TextPara_GetLineSpacing(), TextPara_GetLineSpacingRule(), TextPara_GetListAlignment(), TextPara_GetListLevelIndex(), TextPara_GetListStart(), TextPara_GetListTab(), TextPara_GetListType(), TextPara_GetNoLineNumber(), TextPara_GetPageBreakBefore(), TextPara_GetRightIndent(), TextPara_GetSpaceAfter(), TextPara_GetSpaceBefore(), TextPara_GetStyle(), TextPara_GetTab(), TextPara_GetTabCount(), TextPara_GetTypeInfo(), TextPara_GetTypeInfoCount(), TextPara_GetWidowControl(), TextPara_Invoke(), TextPara_IsEqual(), TextPara_QueryInterface(), TextPara_Release(), TextPara_Reset(), TextPara_SetAlignment(), TextPara_SetDuplicate(), TextPara_SetHyphenation(), TextPara_SetIndents(), TextPara_SetKeepTogether(), TextPara_SetKeepWithNext(), TextPara_SetLineSpacing(), TextPara_SetListAlignment(), TextPara_SetListLevelIndex(), TextPara_SetListStart(), TextPara_SetListTab(), TextPara_SetListType(), TextPara_SetNoLineNumber(), TextPara_SetPageBreakBefore(), TextPara_SetRightIndent(), TextPara_SetSpaceAfter(), TextPara_SetSpaceBefore(), TextPara_SetStyle(), and TextPara_SetWidowControl().

◆ impl_from_ITextRange()

static ITextRangeImpl * impl_from_ITextRange ( ITextRange iface)
inlinestatic

Definition at line 259 of file richole.c.

260{
261 return CONTAINING_RECORD(iface, ITextRangeImpl, ITextRange_iface);
262}

Referenced by ITextRange_fnAddRef(), ITextRange_fnCanEdit(), ITextRange_fnCanPaste(), ITextRange_fnChangeCase(), ITextRange_fnCollapse(), ITextRange_fnCopy(), ITextRange_fnCut(), ITextRange_fnDelete(), ITextRange_fnEndOf(), ITextRange_fnExpand(), ITextRange_fnFindText(), ITextRange_fnFindTextEnd(), ITextRange_fnFindTextStart(), ITextRange_fnGetChar(), ITextRange_fnGetDuplicate(), ITextRange_fnGetEmbeddedObject(), ITextRange_fnGetEnd(), ITextRange_fnGetFont(), ITextRange_fnGetFormattedText(), ITextRange_fnGetIDsOfNames(), ITextRange_fnGetIndex(), ITextRange_fnGetPara(), ITextRange_fnGetPoint(), ITextRange_fnGetStart(), ITextRange_fnGetStoryLength(), ITextRange_fnGetStoryType(), ITextRange_fnGetText(), ITextRange_fnGetTypeInfo(), ITextRange_fnGetTypeInfoCount(), ITextRange_fnInRange(), ITextRange_fnInStory(), ITextRange_fnInvoke(), ITextRange_fnIsEqual(), ITextRange_fnMove(), ITextRange_fnMoveEnd(), ITextRange_fnMoveEndUntil(), ITextRange_fnMoveEndWhile(), ITextRange_fnMoveStart(), ITextRange_fnMoveStartUntil(), ITextRange_fnMoveStartWhile(), ITextRange_fnMoveUntil(), ITextRange_fnMoveWhile(), ITextRange_fnPaste(), ITextRange_fnQueryInterface(), ITextRange_fnRelease(), ITextRange_fnScrollIntoView(), ITextRange_fnSelect(), ITextRange_fnSetChar(), ITextRange_fnSetEnd(), ITextRange_fnSetFont(), ITextRange_fnSetFormattedText(), ITextRange_fnSetIndex(), ITextRange_fnSetPara(), ITextRange_fnSetPoint(), ITextRange_fnSetRange(), ITextRange_fnSetStart(), ITextRange_fnSetText(), and ITextRange_fnStartOf().

◆ impl_from_ITextSelection()

static struct text_selection * impl_from_ITextSelection ( ITextSelection iface)
inlinestatic

Definition at line 264 of file richole.c.

265{
266 return CONTAINING_RECORD(iface, struct text_selection, ITextSelection_iface);
267}

Referenced by ITextSelection_fnAddRef(), ITextSelection_fnCanEdit(), ITextSelection_fnCanPaste(), ITextSelection_fnChangeCase(), ITextSelection_fnCollapse(), ITextSelection_fnCopy(), ITextSelection_fnCut(), ITextSelection_fnDelete(), ITextSelection_fnEndKey(), ITextSelection_fnEndOf(), ITextSelection_fnExpand(), ITextSelection_fnFindText(), ITextSelection_fnFindTextEnd(), ITextSelection_fnFindTextStart(), ITextSelection_fnGetChar(), ITextSelection_fnGetDuplicate(), ITextSelection_fnGetEmbeddedObject(), ITextSelection_fnGetEnd(), ITextSelection_fnGetFlags(), ITextSelection_fnGetFont(), ITextSelection_fnGetFormattedText(), ITextSelection_fnGetIDsOfNames(), ITextSelection_fnGetIndex(), ITextSelection_fnGetPara(), ITextSelection_fnGetPoint(), ITextSelection_fnGetStart(), ITextSelection_fnGetStoryLength(), ITextSelection_fnGetStoryType(), ITextSelection_fnGetText(), ITextSelection_fnGetType(), ITextSelection_fnGetTypeInfo(), ITextSelection_fnGetTypeInfoCount(), ITextSelection_fnHomeKey(), ITextSelection_fnInRange(), ITextSelection_fnInStory(), ITextSelection_fnInvoke(), ITextSelection_fnIsEqual(), ITextSelection_fnMove(), ITextSelection_fnMoveDown(), ITextSelection_fnMoveEnd(), ITextSelection_fnMoveEndUntil(), ITextSelection_fnMoveEndWhile(), ITextSelection_fnMoveLeft(), ITextSelection_fnMoveRight(), ITextSelection_fnMoveStart(), ITextSelection_fnMoveStartUntil(), ITextSelection_fnMoveStartWhile(), ITextSelection_fnMoveUntil(), ITextSelection_fnMoveUp(), ITextSelection_fnMoveWhile(), ITextSelection_fnPaste(), ITextSelection_fnQueryInterface(), ITextSelection_fnRelease(), ITextSelection_fnScrollIntoView(), ITextSelection_fnSelect(), ITextSelection_fnSetChar(), ITextSelection_fnSetEnd(), ITextSelection_fnSetFlags(), ITextSelection_fnSetFont(), ITextSelection_fnSetFormattedText(), ITextSelection_fnSetIndex(), ITextSelection_fnSetPara(), ITextSelection_fnSetPoint(), ITextSelection_fnSetRange(), ITextSelection_fnSetStart(), ITextSelection_fnSetText(), ITextSelection_fnStartOf(), and ITextSelection_fnTypeText().

◆ init_textfont_prop_value()

static void init_textfont_prop_value ( enum textfont_prop_id  propid,
textfont_prop_val v 
)
inlinestatic

Definition at line 359 of file richole.c.

360{
361 switch (propid)
362 {
363 case FONT_ALLCAPS:
364 case FONT_ANIMATION:
365 case FONT_BACKCOLOR:
366 case FONT_BOLD:
367 case FONT_EMBOSS:
368 case FONT_FORECOLOR:
369 case FONT_HIDDEN:
370 case FONT_ENGRAVE:
371 case FONT_ITALIC:
372 case FONT_KERNING:
373 case FONT_LANGID:
374 case FONT_OUTLINE:
375 case FONT_PROTECTED:
376 case FONT_SHADOW:
377 case FONT_SMALLCAPS:
379 case FONT_SUBSCRIPT:
380 case FONT_SUPERSCRIPT:
381 case FONT_UNDERLINE:
382 case FONT_WEIGHT:
383 v->l = tomUndefined;
384 return;
385 case FONT_NAME:
386 v->str = NULL;
387 return;
388 case FONT_POSITION:
389 case FONT_SIZE:
390 case FONT_SPACING:
391 v->f = tomUndefined;
392 return;
393 default:
394 FIXME("unhandled font property %d\n", propid);
395 v->l = tomUndefined;
396 return;
397 }
398}

Referenced by get_textfont_prop().

◆ IOleClientSite_fnAddRef()

static ULONG WINAPI IOleClientSite_fnAddRef ( IOleClientSite iface)
static

Definition at line 983 of file richole.c.

984{
987 TRACE("(%p)->(%u)\n", This, ref);
988 return ref;
989}
#define InterlockedIncrement
Definition: armddk.h:53
static IOleClientSiteImpl * impl_from_IOleClientSite(IOleClientSite *iface)
Definition: richole.c:955
#define TRACE(s)
Definition: solgame.cpp:4
Definition: send.c:48
uint32_t ULONG
Definition: typedefs.h:59

◆ IOleClientSite_fnGetContainer()

static HRESULT WINAPI IOleClientSite_fnGetContainer ( IOleClientSite iface,
IOleContainer **  ppContainer 
)
static

Definition at line 1029 of file richole.c.

1031{
1033 if (!This->child.reole)
1034 return CO_E_RELEASED;
1035
1036 FIXME("stub %p\n", iface);
1037 return E_NOTIMPL;
1038}
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ IOleClientSite_fnGetMoniker()

static HRESULT WINAPI IOleClientSite_fnGetMoniker ( IOleClientSite iface,
DWORD  dwAssign,
DWORD  dwWhichMoniker,
IMoniker **  ppmk 
)
static

Definition at line 1018 of file richole.c.

1020{
1022 if (!This->child.reole)
1023 return CO_E_RELEASED;
1024
1025 FIXME("stub %p\n", iface);
1026 return E_NOTIMPL;
1027}

◆ IOleClientSite_fnOnShowWindow()

static HRESULT WINAPI IOleClientSite_fnOnShowWindow ( IOleClientSite iface,
BOOL  fShow 
)
static

Definition at line 1050 of file richole.c.

1051{
1053 if (!This->child.reole)
1054 return CO_E_RELEASED;
1055
1056 FIXME("stub %p\n", iface);
1057 return E_NOTIMPL;
1058}

◆ IOleClientSite_fnQueryInterface()

static HRESULT WINAPI IOleClientSite_fnQueryInterface ( IOleClientSite me,
REFIID  riid,
LPVOID ppvObj 
)
static

Definition at line 961 of file richole.c.

962{
964 TRACE("%p %s\n", me, debugstr_guid(riid) );
965
966 *ppvObj = NULL;
969 *ppvObj = me;
970 else if (IsEqualGUID(riid, &IID_IOleWindow) ||
972 *ppvObj = &This->IOleInPlaceSite_iface;
973 if (*ppvObj)
974 {
975 IOleClientSite_AddRef(me);
976 return S_OK;
977 }
978 FIXME("%p: unhandled interface %s\n", me, debugstr_guid(riid) );
979
980 return E_NOINTERFACE;
981}
const GUID IID_IUnknown
REFIID riid
Definition: atlbase.h:39
const GUID IID_IOleInPlaceSite
const GUID IID_IOleWindow
const GUID IID_IOleClientSite
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define E_NOINTERFACE
Definition: winerror.h:2364

◆ IOleClientSite_fnRelease()

static ULONG WINAPI IOleClientSite_fnRelease ( IOleClientSite iface)
static

Definition at line 991 of file richole.c.

992{
995
996 TRACE("(%p)->(%u)\n", This, ref);
997
998 if (ref == 0) {
999 if (This->child.reole) {
1000 list_remove(&This->child.entry);
1001 This->child.reole = NULL;
1002 }
1003 heap_free(This);
1004 }
1005 return ref;
1006}
static BOOL heap_free(void *mem)
Definition: appwiz.h:76
#define InterlockedDecrement
Definition: armddk.h:52
static void list_remove(struct list_entry *entry)
Definition: list.h:90

◆ IOleClientSite_fnRequestNewObjectLayout()

static HRESULT WINAPI IOleClientSite_fnRequestNewObjectLayout ( IOleClientSite iface)
static

Definition at line 1060 of file richole.c.

1061{
1063 if (!This->child.reole)
1064 return CO_E_RELEASED;
1065
1066 FIXME("stub %p\n", iface);
1067 return E_NOTIMPL;
1068}

◆ IOleClientSite_fnSaveObject()

static HRESULT WINAPI IOleClientSite_fnSaveObject ( IOleClientSite iface)
static

Definition at line 1008 of file richole.c.

1009{
1011 if (!This->child.reole)
1012 return CO_E_RELEASED;
1013
1014 FIXME("stub %p\n", iface);
1015 return E_NOTIMPL;
1016}

◆ IOleClientSite_fnShowObject()

static HRESULT WINAPI IOleClientSite_fnShowObject ( IOleClientSite iface)
static

Definition at line 1040 of file richole.c.

1041{
1043 if (!This->child.reole)
1044 return CO_E_RELEASED;
1045
1046 FIXME("stub %p\n", iface);
1047 return E_NOTIMPL;
1048}

◆ IOleInPlaceSite_fnAddRef()

static ULONG STDMETHODCALLTYPE IOleInPlaceSite_fnAddRef ( IOleInPlaceSite iface)
static

Definition at line 1089 of file richole.c.

1090{
1092 return IOleClientSite_AddRef(&This->IOleClientSite_iface);
1093}
static IOleClientSiteImpl * impl_from_IOleInPlaceSite(IOleInPlaceSite *iface)
Definition: richole.c:254

◆ IOleInPlaceSite_fnCanInPlaceActivate()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnCanInPlaceActivate ( IOleInPlaceSite iface)
static

Definition at line 1123 of file richole.c.

1124{
1126 FIXME("not implemented: (%p)\n", This);
1127 return E_NOTIMPL;
1128}

◆ IOleInPlaceSite_fnContextSensitiveHelp()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnContextSensitiveHelp ( IOleInPlaceSite iface,
BOOL  fEnterMode 
)
static

Definition at line 1116 of file richole.c.

1117{
1119 FIXME("not implemented: (%p)->(%d)\n", This, fEnterMode);
1120 return E_NOTIMPL;
1121}

◆ IOleInPlaceSite_fnDeactivateAndUndo()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnDeactivateAndUndo ( IOleInPlaceSite iface)
static

Definition at line 1181 of file richole.c.

1182{
1184 FIXME("not implemented: (%p)\n", This);
1185 return E_NOTIMPL;
1186}

◆ IOleInPlaceSite_fnDiscardUndoState()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnDiscardUndoState ( IOleInPlaceSite iface)
static

Definition at line 1174 of file richole.c.

1175{
1177 FIXME("not implemented: (%p)\n", This);
1178 return E_NOTIMPL;
1179}

◆ IOleInPlaceSite_fnGetWindow()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnGetWindow ( IOleInPlaceSite iface,
HWND window 
)
static

Definition at line 1101 of file richole.c.

1102{
1104
1105 TRACE( "(%p)->(%p)\n", This, window );
1106
1107 if (!This->child.reole)
1108 return CO_E_RELEASED;
1109
1110 if (!window) return E_INVALIDARG;
1111
1112 if (!This->child.reole->editor->have_texthost2) return E_NOTIMPL;
1113 return ITextHost2_TxGetWindow( This->child.reole->editor->texthost, window );
1114}
#define ITextHost2_TxGetWindow(This, a)
Definition: editor.h:374
static IHTMLWindow2 * window
Definition: events.c:77

◆ IOleInPlaceSite_fnGetWindowContext()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnGetWindowContext ( IOleInPlaceSite iface,
IOleInPlaceFrame **  ppFrame,
IOleInPlaceUIWindow **  ppDoc,
LPRECT  lprcPosRect,
LPRECT  lprcClipRect,
LPOLEINPLACEFRAMEINFO  lpFrameInfo 
)
static

Definition at line 1144 of file richole.c.

1147{
1149 FIXME("not implemented: (%p)->(%p %p %p %p %p)\n", This, ppFrame, ppDoc, lprcPosRect, lprcClipRect, lpFrameInfo);
1150 return E_NOTIMPL;
1151}

◆ IOleInPlaceSite_fnOnInPlaceActivate()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnInPlaceActivate ( IOleInPlaceSite iface)
static

Definition at line 1130 of file richole.c.

1131{
1133 FIXME("not implemented: (%p)\n", This);
1134 return E_NOTIMPL;
1135}

◆ IOleInPlaceSite_fnOnInPlaceDeactivate()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnInPlaceDeactivate ( IOleInPlaceSite iface)
static

Definition at line 1167 of file richole.c.

1168{
1170 FIXME("not implemented: (%p)\n", This);
1171 return E_NOTIMPL;
1172}

◆ IOleInPlaceSite_fnOnPosRectChange()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnPosRectChange ( IOleInPlaceSite iface,
LPCRECT  lprcPosRect 
)
static

Definition at line 1188 of file richole.c.

1189{
1191 FIXME("not implemented: (%p)->(%p)\n", This, lprcPosRect);
1192 return E_NOTIMPL;
1193}

◆ IOleInPlaceSite_fnOnUIActivate()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnUIActivate ( IOleInPlaceSite iface)
static

Definition at line 1137 of file richole.c.

1138{
1140 FIXME("not implemented: (%p)\n", This);
1141 return E_NOTIMPL;
1142}

◆ IOleInPlaceSite_fnOnUIDeactivate()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnUIDeactivate ( IOleInPlaceSite iface,
BOOL  fUndoable 
)
static

Definition at line 1160 of file richole.c.

1161{
1163 FIXME("not implemented: (%p)->(%d)\n", This, fUndoable);
1164 return E_NOTIMPL;
1165}

◆ IOleInPlaceSite_fnQueryInterface()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnQueryInterface ( IOleInPlaceSite iface,
REFIID  riid,
void **  ppvObj 
)
static

Definition at line 1083 of file richole.c.

1084{
1086 return IOleClientSite_QueryInterface(&This->IOleClientSite_iface, riid, ppvObj);
1087}

◆ IOleInPlaceSite_fnRelease()

static ULONG STDMETHODCALLTYPE IOleInPlaceSite_fnRelease ( IOleInPlaceSite iface)
static

Definition at line 1095 of file richole.c.

1096{
1098 return IOleClientSite_Release(&This->IOleClientSite_iface);
1099}

◆ IOleInPlaceSite_fnScroll()

static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnScroll ( IOleInPlaceSite iface,
SIZE  scrollExtent 
)
static

Definition at line 1153 of file richole.c.

1154{
1156 FIXME("not implemented: (%p)\n", This);
1157 return E_NOTIMPL;
1158}

◆ IRichEditOle_fnActivateAs()

static HRESULT WINAPI IRichEditOle_fnActivateAs ( IRichEditOle iface,
REFCLSID  rclsid,
REFCLSID  rclsidAs 
)
static

Definition at line 932 of file richole.c.

933{
935 FIXME( "stub %p\n", services );
936 return E_NOTIMPL;
937}
static struct text_services * impl_from_IRichEditOle(IRichEditOle *iface)
Definition: richole.c:244

◆ IRichEditOle_fnAddRef()

static ULONG WINAPI IRichEditOle_fnAddRef ( IRichEditOle iface)
static

Definition at line 918 of file richole.c.

919{
921 return IUnknown_AddRef( services->outer_unk );
922}

◆ IRichEditOle_fnContextSensitiveHelp()

static HRESULT WINAPI IRichEditOle_fnContextSensitiveHelp ( IRichEditOle iface,
BOOL  fEnterMode 
)
static

Definition at line 940 of file richole.c.

941{
943 FIXME( "stub %p\n", services );
944 return E_NOTIMPL;
945}

◆ IRichEditOle_fnConvertObject()

static HRESULT WINAPI IRichEditOle_fnConvertObject ( IRichEditOle iface,
LONG  iob,
REFCLSID  class,
LPCSTR  user_type 
)
static

Definition at line 948 of file richole.c.

949{
951 FIXME( "stub %p\n", services );
952 return E_NOTIMPL;
953}

◆ IRichEditOle_fnGetClientSite()

static HRESULT WINAPI IRichEditOle_fnGetClientSite ( IRichEditOle iface,
IOleClientSite **  clientsite 
)
static

Definition at line 1232 of file richole.c.

1233{
1235
1236 TRACE("(%p)->(%p)\n", services, clientsite);
1237
1238 if (!clientsite)
1239 return E_INVALIDARG;
1240
1241 return CreateOleClientSite( services, clientsite );
1242}
static HRESULT CreateOleClientSite(struct text_services *services, IOleClientSite **ret)
Definition: richole.c:1214

◆ IRichEditOle_fnGetClipboardData()

static HRESULT WINAPI IRichEditOle_fnGetClipboardData ( IRichEditOle iface,
CHARRANGE lpchrg,
DWORD  reco,
LPDATAOBJECT lplpdataobj 
)
static

Definition at line 1245 of file richole.c.

1247{
1250 int nChars;
1251
1252 TRACE("(%p,%p,%d)\n", services, lpchrg, reco);
1253 if(!lplpdataobj)
1254 return E_INVALIDARG;
1255 if(!lpchrg)
1256 {
1257 int nFrom, nTo, nStartCur = ME_GetSelectionOfs( services->editor, &nFrom, &nTo );
1258 start = services->editor->pCursors[nStartCur];
1259 nChars = nTo - nFrom;
1260 }
1261 else
1262 {
1263 cursor_from_char_ofs( services->editor, lpchrg->cpMin, &start );
1264 nChars = lpchrg->cpMax - lpchrg->cpMin;
1265 }
1266 return ME_GetDataObject( services->editor, &start, nChars, lplpdataobj );
1267}
int ME_GetSelectionOfs(ME_TextEditor *editor, int *from, int *to)
Definition: caret.c:42
HRESULT ME_GetDataObject(ME_TextEditor *editor, const ME_Cursor *start, int nChars, IDataObject **dataobj)
Definition: clipboard.c:404
LONG cpMax
Definition: richedit.h:501
LONG cpMin
Definition: richedit.h:500

◆ IRichEditOle_fnGetLinkCount()

static LONG WINAPI IRichEditOle_fnGetLinkCount ( IRichEditOle iface)
static

Definition at line 1269 of file richole.c.

1270{
1272 FIXME("stub %p\n", services);
1273 return E_NOTIMPL;
1274}

◆ IRichEditOle_fnGetObject()

static HRESULT WINAPI IRichEditOle_fnGetObject ( IRichEditOle iface,
LONG  iob,
REOBJECT lpreobject,
DWORD  dwFlags 
)
static

Definition at line 1277 of file richole.c.

1279{
1281 struct re_object *reobj = NULL;
1282 LONG count = 0;
1283
1284 TRACE("(%p)->(%x, %p, %x)\n", services, iob, lpreobject, dwFlags);
1285
1286 if (!lpreobject || !lpreobject->cbStruct)
1287 return E_INVALIDARG;
1288
1289 if (iob == REO_IOB_USE_CP)
1290 {
1292
1293 TRACE("character offset: %d\n", lpreobject->cp);
1294 cursor_from_char_ofs( services->editor, lpreobject->cp, &cursor );
1295 if (!cursor.run->reobj)
1296 return E_INVALIDARG;
1297 else
1298 reobj = cursor.run->reobj;
1299 }
1300 else if (iob == REO_IOB_SELECTION)
1301 {
1302 ME_Cursor *from, *to;
1303
1304 ME_GetSelection(services->editor, &from, &to);
1305 if (!from->run->reobj)
1306 return E_INVALIDARG;
1307 else
1308 reobj = from->run->reobj;
1309 }
1310 else
1311 {
1312 if (iob < 0 || iob >= IRichEditOle_GetObjectCount( iface ))
1313 return E_INVALIDARG;
1314 LIST_FOR_EACH_ENTRY(reobj, &services->editor->reobj_list, struct re_object, entry)
1315 {
1316 if (count == iob)
1317 break;
1318 count++;
1319 }
1320 }
1321 ME_CopyReObject(lpreobject, &reobj->obj, dwFlags);
1322 return S_OK;
1323}
int ME_GetSelection(ME_TextEditor *editor, ME_Cursor **from, ME_Cursor **to)
Definition: caret.c:57
void ME_CopyReObject(REOBJECT *dst, const REOBJECT *src, DWORD flags)
Definition: richole.c:5829
GLuint GLuint GLsizei count
Definition: gl.h:1545
const char cursor[]
Definition: icontest.c:13
uint32_t entry
Definition: isohybrid.c:63
#define LIST_FOR_EACH_ENTRY(elem, list, type, field)
Definition: list.h:198
DWORD cbStruct
Definition: richole.idl:58
LONG cp
Definition: richole.idl:59
REOBJECT obj
Definition: editstr.h:154
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
Definition: wincrypt.h:1176

◆ IRichEditOle_fnGetObjectCount()

static LONG WINAPI IRichEditOle_fnGetObjectCount ( IRichEditOle iface)
static

Definition at line 1326 of file richole.c.

1327{
1329 TRACE("(%p)\n", services);
1330 return list_count( &services->editor->reobj_list );
1331}
__WINE_SERVER_LIST_INLINE unsigned int list_count(const struct list *list)
Definition: list.h:155

◆ IRichEditOle_fnHandsOffStorage()

static HRESULT WINAPI IRichEditOle_fnHandsOffStorage ( IRichEditOle iface,
LONG  iob 
)
static

Definition at line 1334 of file richole.c.

1335{
1337 FIXME("stub %p\n", services);
1338 return E_NOTIMPL;
1339}

◆ IRichEditOle_fnImportDataObject()

static HRESULT WINAPI IRichEditOle_fnImportDataObject ( IRichEditOle iface,
LPDATAOBJECT  lpdataobj,
CLIPFORMAT  cf,
HGLOBAL  hMetaPict 
)
static

Definition at line 1342 of file richole.c.

1344{
1346 FIXME("stub %p\n", services);
1347 return E_NOTIMPL;
1348}

◆ IRichEditOle_fnInPlaceDeactivate()

static HRESULT WINAPI IRichEditOle_fnInPlaceDeactivate ( IRichEditOle iface)
static

Definition at line 1351 of file richole.c.

1352{
1354 FIXME("stub %p\n", services);
1355 return E_NOTIMPL;
1356}

◆ IRichEditOle_fnInsertObject()

static HRESULT WINAPI IRichEditOle_fnInsertObject ( IRichEditOle iface,
REOBJECT reo 
)
static

Definition at line 1359 of file richole.c.

1360{
1362
1363 TRACE("(%p,%p)\n", services, reo);
1364
1365 if (!reo)
1366 return E_INVALIDARG;
1367
1368 if (reo->cbStruct < sizeof(*reo)) return STG_E_INVALIDPARAMETER;
1369
1370 ME_InsertOLEFromCursor(services->editor, reo, 0);
1371 ME_CommitUndo(services->editor);
1373 return S_OK;
1374}
void ME_InsertOLEFromCursor(ME_TextEditor *editor, const REOBJECT *reo, int nCursor)
Definition: caret.c:503
void ME_CommitUndo(ME_TextEditor *editor) DECLSPEC_HIDDEN
Definition: undo.c:227
void ME_UpdateRepaint(ME_TextEditor *editor, BOOL update_now) DECLSPEC_HIDDEN
Definition: paint.c:129
#define STG_E_INVALIDPARAMETER
Definition: winerror.h:2580

◆ IRichEditOle_fnQueryInterface()

static HRESULT WINAPI IRichEditOle_fnQueryInterface ( IRichEditOle iface,
REFIID  riid,
LPVOID ppvObj 
)
static

Definition at line 911 of file richole.c.

912{
914 return IUnknown_QueryInterface( services->outer_unk, riid, ppvObj );
915}

◆ IRichEditOle_fnRelease()

static ULONG WINAPI IRichEditOle_fnRelease ( IRichEditOle iface)
static

Definition at line 925 of file richole.c.

926{
928 return IUnknown_Release( services->outer_unk );
929}

◆ IRichEditOle_fnSaveCompleted()

static HRESULT WINAPI IRichEditOle_fnSaveCompleted ( IRichEditOle iface,
LONG  iob,
LPSTORAGE  lpstg 
)
static

Definition at line 1376 of file richole.c.

1378{
1380 FIXME("stub %p\n", services);
1381 return E_NOTIMPL;
1382}

◆ IRichEditOle_fnSetDvaspect()

static HRESULT WINAPI IRichEditOle_fnSetDvaspect ( IRichEditOle iface,
LONG  iob,
DWORD  dvaspect 
)
static

Definition at line 1385 of file richole.c.

1386{
1388 FIXME("stub %p\n", services);
1389 return E_NOTIMPL;
1390}

◆ IRichEditOle_fnSetHostNames()

static HRESULT WINAPI IRichEditOle_fnSetHostNames ( IRichEditOle iface,
LPCSTR  lpstrContainerApp,
LPCSTR  lpstrContainerObj 
)
static

Definition at line 1392 of file richole.c.

1394{
1396 FIXME("stub %p %s %s\n", services, lpstrContainerApp, lpstrContainerObj);
1397 return E_NOTIMPL;
1398}

◆ IRichEditOle_fnSetLinkAvailable()

static HRESULT WINAPI IRichEditOle_fnSetLinkAvailable ( IRichEditOle iface,
LONG  iob,
BOOL  fAvailable 
)
static

Definition at line 1401 of file richole.c.

1402{
1404 FIXME("stub %p\n", services);
1405 return E_NOTIMPL;
1406}

◆ is_equal_textfont_prop_value()

static BOOL is_equal_textfont_prop_value ( enum textfont_prop_id  propid,
textfont_prop_val left,
textfont_prop_val right 
)
inlinestatic

Definition at line 321 of file richole.c.

323{
324 switch (propid)
325 {
326 case FONT_ALLCAPS:
327 case FONT_ANIMATION:
328 case FONT_BACKCOLOR:
329 case FONT_BOLD:
330 case FONT_EMBOSS:
331 case FONT_FORECOLOR:
332 case FONT_HIDDEN:
333 case FONT_ENGRAVE:
334 case FONT_ITALIC:
335 case FONT_KERNING:
336 case FONT_LANGID:
337 case FONT_OUTLINE:
338 case FONT_PROTECTED:
339 case FONT_SHADOW:
340 case FONT_SMALLCAPS:
342 case FONT_SUBSCRIPT:
343 case FONT_SUPERSCRIPT:
344 case FONT_UNDERLINE:
345 case FONT_WEIGHT:
346 return left->l == right->l;
347 case FONT_NAME:
348 return !wcscmp(left->str, right->str);
349 case FONT_POSITION:
350 case FONT_SIZE:
351 case FONT_SPACING:
352 return left->f == right->f;
353 default:
354 FIXME("unhandled font property %d\n", propid);
355 return FALSE;
356 }
357}
GLdouble GLdouble right
Definition: glext.h:10859
GLint left
Definition: glext.h:7726
_Check_return_ _CRTIMP int __cdecl wcscmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)

Referenced by get_textfont_prop().

◆ ITextDocument2Old_fnAddRef()

static ULONG WINAPI ITextDocument2Old_fnAddRef ( ITextDocument2Old iface)
static

Definition at line 4037 of file richole.c.

4038{
4040 return IUnknown_AddRef( services->outer_unk );
4041}
static struct text_services * impl_from_ITextDocument2Old(ITextDocument2Old *iface)
Definition: richole.c:249

◆ ITextDocument2Old_fnAttachMsgFilter()

static HRESULT WINAPI ITextDocument2Old_fnAttachMsgFilter ( ITextDocument2Old iface,
IUnknown filter 
)
static

Definition at line 4285 of file richole.c.

4286{
4288
4289 FIXME("(%p)->(%p): stub\n", services, filter);
4290
4291 return E_NOTIMPL;
4292}
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter
Definition: glext.h:7005

◆ ITextDocument2Old_fnBeginEditCollection()

static HRESULT WINAPI ITextDocument2Old_fnBeginEditCollection ( ITextDocument2Old iface)
static

Definition at line 4219 of file richole.c.

4220{
4222 FIXME("stub %p\n", services);
4223 return E_NOTIMPL;
4224}

◆ ITextDocument2Old_fnCheckTextLimit()

static HRESULT WINAPI ITextDocument2Old_fnCheckTextLimit ( ITextDocument2Old iface,
LONG  cch,
LONG exceed 
)
static

Definition at line 4424 of file richole.c.

4425{
4427
4428 FIXME("(%p)->(%d, %p): stub\n", services, cch, exceed);
4429
4430 return E_NOTIMPL;
4431}
static DWORD DWORD void LPSTR DWORD cch
Definition: str.c:202

◆ ITextDocument2Old_fnEndEditCollection()

static HRESULT WINAPI ITextDocument2Old_fnEndEditCollection ( ITextDocument2Old iface)
static

Definition at line 4226 of file richole.c.

4227{
4229 FIXME("stub %p\n", services);
4230 return E_NOTIMPL;
4231}

◆ ITextDocument2Old_fnFreeze()

static HRESULT WINAPI ITextDocument2Old_fnFreeze ( ITextDocument2Old iface,
LONG pCount 
)
static

Definition at line 4205 of file richole.c.

4206{
4208 FIXME("stub %p\n", services);
4209 return E_NOTIMPL;
4210}

◆ ITextDocument2Old_fnGetCaretType()

static HRESULT WINAPI ITextDocument2Old_fnGetCaretType ( ITextDocument2Old iface,
LONG type 
)
static

Definition at line 4312 of file richole.c.

4313{
4315
4316 FIXME("(%p)->(%p): stub\n", services, type);
4317
4318 return E_NOTIMPL;
4319}
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545

◆ ITextDocument2Old_fnGetClientRect()

static HRESULT WINAPI ITextDocument2Old_fnGetClientRect ( ITextDocument2Old iface,
LONG  type,
LONG left,
LONG top,
LONG right,
LONG bottom 
)
static

Definition at line 4378 of file richole.c.

4380{
4382
4383 FIXME("(%p)->(%d, %p, %p, %p, %p): stub\n", services, type, left, top, right, bottom);
4384
4385 return E_NOTIMPL;
4386}
GLdouble GLdouble GLdouble GLdouble top
Definition: glext.h:10859
GLint GLint bottom
Definition: glext.h:7726

◆ ITextDocument2Old_fnGetDefaultTabStop()

static HRESULT WINAPI ITextDocument2Old_fnGetDefaultTabStop ( ITextDocument2Old iface,
float pValue 
)
static

Definition at line 4168 of file richole.c.

4169{
4171 FIXME("stub %p\n", services);
4172 return E_NOTIMPL;
4173}

◆ ITextDocument2Old_fnGetEffectColor()

static HRESULT WINAPI ITextDocument2Old_fnGetEffectColor ( ITextDocument2Old iface,
LONG  index,
COLORREF cr 
)
static

Definition at line 4303 of file richole.c.

4304{
4306
4307 FIXME("(%p)->(%d, %p): stub\n", services, index, cr);
4308
4309 return E_NOTIMPL;
4310}
GLuint index
Definition: glext.h:6031

◆ ITextDocument2Old_fnGetFEFlags()

static HRESULT WINAPI ITextDocument2Old_fnGetFEFlags ( ITextDocument2Old iface,
LONG flags 
)
static

Definition at line 4406 of file richole.c.

4407{
4409
4410 FIXME("(%p)->(%p): stub\n", services, flags);
4411
4412 return E_NOTIMPL;
4413}
GLbitfield flags
Definition: glext.h:7161

◆ ITextDocument2Old_fnGetIDsOfNames()

static HRESULT WINAPI ITextDocument2Old_fnGetIDsOfNames ( ITextDocument2Old iface,
REFIID  riid,
LPOLESTR rgszNames,
UINT  cNames,
LCID  lcid,
DISPID rgDispId 
)
static

Definition at line 4072 of file richole.c.

4075{
4077 ITypeInfo *ti;
4078 HRESULT hr;
4079
4080 TRACE("(%p)->(%s, %p, %u, %d, %p)\n", services, debugstr_guid(riid),
4081 rgszNames, cNames, lcid, rgDispId);
4082
4084 if (SUCCEEDED(hr))
4085 hr = ITypeInfo_GetIDsOfNames(ti, rgszNames, cNames, rgDispId);
4086 return hr;
4087}
static HRESULT get_typeinfo(enum tid_t tid, ITypeInfo **typeinfo)
Definition: richole.c:108
#define SUCCEEDED(hr)
Definition: intsafe.h:50

◆ ITextDocument2Old_fnGetImmContext()

static HRESULT WINAPI ITextDocument2Old_fnGetImmContext ( ITextDocument2Old iface,
LONG context 
)
static

Definition at line 4330 of file richole.c.

4331{
4333
4334 FIXME("(%p)->(%p): stub\n", services, context);
4335
4336 return E_NOTIMPL;
4337}
Definition: http.c:7252

◆ ITextDocument2Old_fnGetName()

static HRESULT WINAPI ITextDocument2Old_fnGetName ( ITextDocument2Old iface,
BSTR pName 
)
static

Definition at line 4108 of file richole.c.

4109{
4111 FIXME("stub %p\n", services);
4112 return E_NOTIMPL;
4113}

◆ ITextDocument2Old_fnGetNotificationMode()

static HRESULT WINAPI ITextDocument2Old_fnGetNotificationMode ( ITextDocument2Old iface,
LONG mode 
)
static

Definition at line 4360 of file richole.c.

4361{
4363
4364 FIXME("(%p)->(%p): stub\n", services, mode);
4365
4366 return E_NOTIMPL;
4367}
GLenum mode
Definition: glext.h:6217

◆ ITextDocument2Old_fnGetPreferredFont()

static HRESULT WINAPI ITextDocument2Old_fnGetPreferredFont ( ITextDocument2Old iface,
LONG  cp,
LONG  charrep,
LONG  options,
LONG  current_charrep,
LONG  current_fontsize,
BSTR bstr,
LONG pitch_family,
LONG new_fontsize 
)
static

Definition at line 4348 of file richole.c.

4351{
4353
4354 FIXME("(%p)->(%d, %d, %d, %d, %d, %p, %p, %p): stub\n", services, cp, charrep, options, current_charrep,
4355 current_fontsize, bstr, pitch_family, new_fontsize);
4356
4357 return E_NOTIMPL;
4358}
POINT cp
Definition: magnifier.c:59

◆ ITextDocument2Old_fnGetSaved()

static HRESULT WINAPI ITextDocument2Old_fnGetSaved ( ITextDocument2Old iface,
LONG pValue 
)
static

Definition at line 4154 of file richole.c.

4155{
4157 FIXME("stub %p\n", services);
4158 return E_NOTIMPL;
4159}

◆ ITextDocument2Old_fnGetSelection()

static HRESULT WINAPI ITextDocument2Old_fnGetSelection ( ITextDocument2Old iface,
ITextSelection **  selection 
)
static

Definition at line 4115 of file richole.c.

4116{
4118
4119 TRACE("(%p)->(%p)\n", iface, selection);
4120
4121 if (!selection)
4122 return E_INVALIDARG;
4123
4124 if (!services->text_selection)
4125 {
4126 services->text_selection = text_selection_create( services );
4127 if (!services->text_selection)
4128 {
4129 *selection = NULL;
4130 return E_OUTOFMEMORY;
4131 }
4132 }
4133
4134 *selection = &services->text_selection->ITextSelection_iface;
4135 ITextSelection_AddRef(*selection);
4136 return S_OK;
4137}
int selection
Definition: ctm.c:92
static struct text_selection * text_selection_create(struct text_services *)
Definition: richole.c:5625

◆ ITextDocument2Old_fnGetSelectionEx()

static HRESULT WINAPI ITextDocument2Old_fnGetSelectionEx ( ITextDocument2Old iface,
ITextSelection **  selection 
)
static

Definition at line 4388 of file richole.c.

4389{
4391
4392 FIXME("(%p)->(%p): stub\n", services, selection);
4393
4394 return E_NOTIMPL;
4395}

◆ ITextDocument2Old_fnGetStoryCount()

static HRESULT WINAPI ITextDocument2Old_fnGetStoryCount ( ITextDocument2Old iface,
LONG pCount 
)
static

Definition at line 4139 of file richole.c.

4140{
4142 FIXME("stub %p\n", services);
4143 return E_NOTIMPL;
4144}

◆ ITextDocument2Old_fnGetStoryRanges()

static HRESULT WINAPI ITextDocument2Old_fnGetStoryRanges ( ITextDocument2Old iface,
ITextStoryRanges **  ppStories 
)
static

Definition at line 4146 of file richole.c.

4148{
4150 FIXME("stub %p\n", services);
4151 return E_NOTIMPL;
4152}

◆ ITextDocument2Old_fnGetTypeInfo()

static HRESULT WINAPI ITextDocument2Old_fnGetTypeInfo ( ITextDocument2Old iface,
UINT  iTInfo,
LCID  lcid,
ITypeInfo **  ppTInfo 
)
static

Definition at line 4058 of file richole.c.

4060{
4062 HRESULT hr;
4063
4064 TRACE("(%p)->(%u,%d,%p)\n", services, iTInfo, lcid, ppTInfo);
4065
4066 hr = get_typeinfo(ITextDocument_tid, ppTInfo);
4067 if (SUCCEEDED(hr))
4068 ITypeInfo_AddRef(*ppTInfo);
4069 return hr;
4070}

◆ ITextDocument2Old_fnGetTypeInfoCount()

static HRESULT WINAPI ITextDocument2Old_fnGetTypeInfoCount ( ITextDocument2Old iface,
UINT pctinfo 
)
static

Definition at line 4049 of file richole.c.

4051{
4053 TRACE("(%p)->(%p)\n", services, pctinfo);
4054 *pctinfo = 1;
4055 return S_OK;
4056}

◆ ITextDocument2Old_fnGetWindow()

static HRESULT WINAPI ITextDocument2Old_fnGetWindow ( ITextDocument2Old iface,
LONG hwnd 
)
static

Definition at line 4397 of file richole.c.

4398{
4400
4401 FIXME("(%p)->(%p): stub\n", services, hwnd);
4402
4403 return E_NOTIMPL;
4404}
_In_ LONG _In_ HWND hwnd
Definition: winddi.h:4023

◆ ITextDocument2Old_fnIMEInProgress()

static HRESULT WINAPI ITextDocument2Old_fnIMEInProgress ( ITextDocument2Old iface,
LONG  mode 
)
static

Definition at line 4433 of file richole.c.

4434{
4436
4437 FIXME("(%p)->(0x%x): stub\n", services, mode);
4438
4439 return E_NOTIMPL;
4440}

◆ ITextDocument2Old_fnInvoke()

static HRESULT WINAPI ITextDocument2Old_fnInvoke ( ITextDocument2Old iface,
DISPID  dispIdMember,
REFIID  riid,
LCID  lcid,
WORD  wFlags,
DISPPARAMS *  pDispParams,
VARIANT pVarResult,
EXCEPINFO *  pExcepInfo,
UINT puArgErr 
)
static

Definition at line 4089 of file richole.c.

4093{
4095 ITypeInfo *ti;
4096 HRESULT hr;
4097
4098 TRACE("(%p)->(%d, %s, %d, %u, %p, %p, %p, %p)\n", services, dispIdMember,
4099 debugstr_guid(riid), lcid, wFlags, pDispParams, pVarResult,
4100 pExcepInfo, puArgErr);
4101
4103 if (SUCCEEDED(hr))
4104 hr = ITypeInfo_Invoke(ti, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
4105 return hr;
4106}
_In_ DWORD _Out_ _In_ WORD wFlags
Definition: wincon.h:531

◆ ITextDocument2Old_fnNew()

static HRESULT WINAPI ITextDocument2Old_fnNew ( ITextDocument2Old iface)
static

Definition at line 4182 of file richole.c.

4183{
4185 FIXME("stub %p\n", services);
4186 return E_NOTIMPL;
4187}

◆ ITextDocument2Old_fnNotify()

static HRESULT WINAPI ITextDocument2Old_fnNotify ( ITextDocument2Old iface,
LONG  notify 
)
static

Definition at line 4460 of file richole.c.

4461{
4463
4464 FIXME("(%p)->(%d): stub\n", services, notify);
4465
4466 return E_NOTIMPL;
4467}
int notify
Definition: msacm.c:1366

◆ ITextDocument2Old_fnOpen()

static HRESULT WINAPI ITextDocument2Old_fnOpen ( ITextDocument2Old iface,
VARIANT pVar,
LONG  Flags,
LONG  CodePage 
)
static

Definition at line 4189 of file richole.c.

4191{
4193 FIXME("stub %p\n", services);
4194 return E_NOTIMPL;
4195}

◆ ITextDocument2Old_fnQueryInterface()

static HRESULT WINAPI ITextDocument2Old_fnQueryInterface ( ITextDocument2Old iface,
REFIID  riid,
void **  ppvObject 
)
static

Definition at line 4030 of file richole.c.

4032{
4034 return IUnknown_QueryInterface( services->outer_unk, riid, ppvObject );
4035}
_In_ void _In_ PCCERT_CONTEXT _In_opt_ LPFILETIME _In_ DWORD _In_ DWORD _Outptr_opt_ void ** ppvObject
Definition: wincrypt.h:6082

◆ ITextDocument2Old_fnRange()

static HRESULT WINAPI ITextDocument2Old_fnRange ( ITextDocument2Old iface,
LONG  cp1,
LONG  cp2,
ITextRange **  ppRange 
)
static

Definition at line 4263 of file richole.c.

4265{
4267
4268 TRACE("%p %p %d %d\n", services, ppRange, cp1, cp2);
4269 if (!ppRange)
4270 return E_INVALIDARG;
4271
4272 cp2range(services->editor, &cp1, &cp2);
4273 return CreateITextRange(services, cp1, cp2, ppRange);
4274}
static HRESULT CreateITextRange(struct text_services *services, LONG start, LONG end, ITextRange **ppRange)
Definition: richole.c:4247
static void cp2range(ME_TextEditor *editor, LONG *cp1, LONG *cp2)
Definition: richole.c:1938

◆ ITextDocument2Old_fnRangeFromPoint()

static HRESULT WINAPI ITextDocument2Old_fnRangeFromPoint ( ITextDocument2Old iface,
LONG  x,
LONG  y,
ITextRange **  ppRange 
)
static

Definition at line 4276 of file richole.c.

4278{
4280 FIXME("stub %p\n", services);
4281 return E_NOTIMPL;
4282}

◆ ITextDocument2Old_fnRedo()

static HRESULT WINAPI ITextDocument2Old_fnRedo ( ITextDocument2Old iface,
LONG  Count,
LONG prop 
)
static

Definition at line 4240 of file richole.c.

4241{
4243 FIXME("stub %p\n", services);
4244 return E_NOTIMPL;
4245}

◆ ITextDocument2Old_fnRelease()

static ULONG WINAPI ITextDocument2Old_fnRelease ( ITextDocument2Old iface)
static

Definition at line 4043 of file richole.c.

4044{
4046 return IUnknown_Release( services->outer_unk );
4047}

◆ ITextDocument2Old_fnReleaseImmContext()

static HRESULT WINAPI ITextDocument2Old_fnReleaseImmContext ( ITextDocument2Old iface,
LONG  context 
)
static

Definition at line 4339 of file richole.c.

4340{
4342
4343 FIXME("(%p)->(%d): stub\n", services, context);
4344
4345 return E_NOTIMPL;
4346}

◆ ITextDocument2Old_fnSave()

static HRESULT WINAPI ITextDocument2Old_fnSave ( ITextDocument2Old iface,
VARIANT pVar,
LONG  Flags,
LONG  CodePage 
)
static

Definition at line 4197 of file richole.c.

4199{
4201 FIXME("stub %p\n", services);
4202 return E_NOTIMPL;
4203}

◆ ITextDocument2Old_fnSetCaretType()

static HRESULT WINAPI ITextDocument2Old_fnSetCaretType ( ITextDocument2Old iface,
LONG  type 
)
static

Definition at line 4321 of file richole.c.

4322{
4324
4325 FIXME("(%p)->(%d): stub\n", services, type);
4326
4327 return E_NOTIMPL;
4328}

◆ ITextDocument2Old_fnSetDefaultTabStop()

static HRESULT WINAPI ITextDocument2Old_fnSetDefaultTabStop ( ITextDocument2Old iface,
float  Value 
)
static

Definition at line 4175 of file richole.c.

4176{
4178 FIXME("stub %p\n", services);
4179 return E_NOTIMPL;
4180}

◆ ITextDocument2Old_fnSetEffectColor()

static HRESULT WINAPI ITextDocument2Old_fnSetEffectColor ( ITextDocument2Old iface,
LONG  index,
COLORREF  cr 
)
static

Definition at line 4294 of file richole.c.

4295{
4297
4298 FIXME("(%p)->(%d, 0x%x): stub\n", services, index, cr);
4299
4300 return E_NOTIMPL;
4301}

◆ ITextDocument2Old_fnSetNotificationMode()

static HRESULT WINAPI ITextDocument2Old_fnSetNotificationMode ( ITextDocument2Old iface,
LONG  mode 
)
static

Definition at line 4369 of file richole.c.

4370{
4372
4373 FIXME("(%p)->(0x%x): stub\n", services, mode);
4374
4375 return E_NOTIMPL;
4376}

◆ ITextDocument2Old_fnSetSaved()

static HRESULT WINAPI ITextDocument2Old_fnSetSaved ( ITextDocument2Old iface,
LONG  Value 
)
static

Definition at line 4161 of file richole.c.

4162{
4164 FIXME("stub %p\n", services);
4165 return E_NOTIMPL;
4166}

◆ ITextDocument2Old_fnSysBeep()

static HRESULT WINAPI ITextDocument2Old_fnSysBeep ( ITextDocument2Old iface)
static

Definition at line 4442 of file richole.c.

4443{
4445
4446 FIXME("(%p): stub\n", services);
4447
4448 return E_NOTIMPL;
4449}

◆ ITextDocument2Old_fnUndo()

static HRESULT WINAPI ITextDocument2Old_fnUndo ( ITextDocument2Old iface,
LONG  Count,
LONG prop 
)
static

Definition at line 4233 of file richole.c.

4234{
4236 FIXME("stub %p\n", services);
4237 return E_NOTIMPL;
4238}

◆ ITextDocument2Old_fnUnfreeze()

static HRESULT WINAPI ITextDocument2Old_fnUnfreeze ( ITextDocument2Old iface,
LONG pCount 
)
static

Definition at line 4212 of file richole.c.

4213{
4215 FIXME("stub %p\n", services);
4216 return E_NOTIMPL;
4217}

◆ ITextDocument2Old_fnUpdate()

static HRESULT WINAPI ITextDocument2Old_fnUpdate ( ITextDocument2Old iface,
LONG  mode 
)
static

Definition at line 4451 of file richole.c.

4452{
4454
4455 FIXME("(%p)->(0x%x): stub\n", services, mode);
4456
4457 return E_NOTIMPL;
4458}

◆ ITextDocument2Old_fnUpdateWindow()

static HRESULT WINAPI ITextDocument2Old_fnUpdateWindow ( ITextDocument2Old iface)
static

Definition at line 4415 of file richole.c.

4416{
4418
4419 FIXME("(%p): stub\n", services);
4420
4421 return E_NOTIMPL;
4422}

◆ ITextRange_fnAddRef()

static ULONG WINAPI ITextRange_fnAddRef ( ITextRange me)
static

Definition at line 1454 of file richole.c.

1455{
1457 return InterlockedIncrement(&This->ref);
1458}
static ITextRangeImpl * impl_from_ITextRange(ITextRange *iface)
Definition: richole.c:259

◆ ITextRange_fnCanEdit()

static HRESULT WINAPI ITextRange_fnCanEdit ( ITextRange me,
LONG ret 
)
static

Definition at line 2573 of file richole.c.

2574{
2576
2577 FIXME("(%p)->(%p): stub\n", This, ret);
2578
2579 if (!This->child.reole)
2580 return CO_E_RELEASED;
2581
2582 return E_NOTIMPL;
2583}

◆ ITextRange_fnCanPaste()

static HRESULT WINAPI ITextRange_fnCanPaste ( ITextRange me,
VARIANT v,
LONG  format,
LONG ret 
)
static

Definition at line 2561 of file richole.c.

2562{
2564
2565 FIXME("(%p)->(%s %x %p): stub\n", This, debugstr_variant(v), format, ret);
2566
2567 if (!This->child.reole)
2568 return CO_E_RELEASED;
2569
2570 return E_NOTIMPL;
2571}
static const char * debugstr_variant(const VARIANT *var)
Definition: container.c:46
Definition: format.c:58

◆ ITextRange_fnChangeCase()

static HRESULT WINAPI ITextRange_fnChangeCase ( ITextRange me,
LONG  type 
)
static

Definition at line 2585 of file richole.c.

2586{
2588
2589 FIXME("(%p)->(%d): stub\n", This, type);
2590
2591 if (!This->child.reole)
2592 return CO_E_RELEASED;
2593
2594 return E_NOTIMPL;
2595}

◆ ITextRange_fnCollapse()

static HRESULT WINAPI ITextRange_fnCollapse ( ITextRange me,
LONG  bStart 
)
static

Definition at line 1889 of file richole.c.

1890{
1892
1893 TRACE("(%p)->(%d)\n", This, bStart);
1894
1895 if (!This->child.reole)
1896 return CO_E_RELEASED;
1897
1898 return range_Collapse(bStart, &This->start, &This->end);
1899}
static HRESULT range_Collapse(LONG bStart, LONG *start, LONG *end)
Definition: richole.c:1877

◆ ITextRange_fnCopy()

static HRESULT WINAPI ITextRange_fnCopy ( ITextRange me,
VARIANT v 
)
static

Definition at line 2537 of file richole.c.

2538{
2540
2541 TRACE("(%p)->(%p)\n", This, v);
2542
2543 if (!This->child.reole)
2544 return CO_E_RELEASED;
2545
2546 return textrange_copy_or_cut(me, This->child.reole->editor, FALSE, v);
2547}
static HRESULT textrange_copy_or_cut(ITextRange *range, ME_TextEditor *editor, BOOL cut, VARIANT *v)
Definition: richole.c:2500

◆ ITextRange_fnCut()

static HRESULT WINAPI ITextRange_fnCut ( ITextRange me,
VARIANT v 
)
static

Definition at line 2525 of file richole.c.

2526{
2528
2529 TRACE("(%p)->(%p)\n", This, v);
2530
2531 if (!This->child.reole)
2532 return CO_E_RELEASED;
2533
2534 return textrange_copy_or_cut(me, This->child.reole->editor, TRUE, v);
2535}

◆ ITextRange_fnDelete()

static HRESULT WINAPI ITextRange_fnDelete ( ITextRange me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2488 of file richole.c.

2489{
2491
2492 FIXME("(%p)->(%d %d %p): stub\n", This, unit, count, delta);
2493
2494 if (!This->child.reole)
2495 return CO_E_RELEASED;
2496
2497 return E_NOTIMPL;
2498}
png_const_structrp png_const_inforp int * unit
Definition: png.h:2159

◆ ITextRange_fnEndOf()

static HRESULT WINAPI ITextRange_fnEndOf ( ITextRange me,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 2150 of file richole.c.

2152{
2154
2155 TRACE("(%p)->(%d %d %p)\n", This, unit, extend, delta);
2156
2157 if (!This->child.reole)
2158 return CO_E_RELEASED;
2159
2160 return textrange_endof(me, This->child.reole->editor, unit, extend, delta);
2161}
static HRESULT textrange_endof(ITextRange *range, ME_TextEditor *editor, LONG unit, LONG extend, LONG *delta)
Definition: richole.c:2110

◆ ITextRange_fnExpand()

static HRESULT WINAPI ITextRange_fnExpand ( ITextRange me,
LONG  unit,
LONG delta 
)
static

Definition at line 1901 of file richole.c.

1902{
1904
1905 TRACE("(%p)->(%d %p)\n", This, unit, delta);
1906
1907 if (!This->child.reole)
1908 return CO_E_RELEASED;
1909
1910 return textrange_expand(me, unit, delta);
1911}
static HRESULT textrange_expand(ITextRange *range, LONG unit, LONG *delta)
Definition: richole.c:881

◆ ITextRange_fnFindText()

static HRESULT WINAPI ITextRange_fnFindText ( ITextRange me,
BSTR  text,
LONG  count,
LONG  flags,
LONG length 
)
static

Definition at line 2449 of file richole.c.

2451{
2453
2454 FIXME("(%p)->(%s %d %x %p): stub\n", This, debugstr_w(text), count, flags, length);
2455
2456 if (!This->child.reole)
2457 return CO_E_RELEASED;
2458
2459 return E_NOTIMPL;
2460}
const WCHAR * text
Definition: package.c:1794
GLuint GLsizei GLsizei * length
Definition: glext.h:6040
#define debugstr_w
Definition: kernel32.h:32

◆ ITextRange_fnFindTextEnd()

static HRESULT WINAPI ITextRange_fnFindTextEnd ( ITextRange me,
BSTR  text,
LONG  count,
LONG  flags,
LONG length 
)
static

Definition at line 2475 of file richole.c.

2477{
2479
2480 FIXME("(%p)->(%s %d %x %p): stub\n", This, debugstr_w(text), count, flags, length);
2481
2482 if (!This->child.reole)
2483 return CO_E_RELEASED;
2484
2485 return E_NOTIMPL;
2486}

◆ ITextRange_fnFindTextStart()

static HRESULT WINAPI ITextRange_fnFindTextStart ( ITextRange me,
BSTR  text,
LONG  count,
LONG  flags,
LONG length 
)
static

Definition at line 2462 of file richole.c.

2464{
2466
2467 FIXME("(%p)->(%s %d %x %p): stub\n", This, debugstr_w(text), count, flags, length);
2468
2469 if (!This->child.reole)
2470 return CO_E_RELEASED;
2471
2472 return E_NOTIMPL;
2473}

◆ ITextRange_fnGetChar()

static HRESULT WINAPI ITextRange_fnGetChar ( ITextRange me,
LONG pch 
)
static

Definition at line 1626 of file richole.c.

1627{
1629 ME_TextEditor *editor;
1631
1632 TRACE("(%p)->(%p)\n", This, pch);
1633
1634 if (!This->child.reole)
1635 return CO_E_RELEASED;
1636
1637 if (!pch)
1638 return E_INVALIDARG;
1639
1640 editor = This->child.reole->editor;
1641 cursor_from_char_ofs( editor, This->start, &cursor );
1642 return range_GetChar(editor, &cursor, pch);
1643}
static HRESULT range_GetChar(ME_TextEditor *editor, ME_Cursor *cursor, LONG *pch)
Definition: richole.c:1616
#define pch(ap)
Definition: match.c:418

◆ ITextRange_fnGetDuplicate()

static HRESULT WINAPI ITextRange_fnGetDuplicate ( ITextRange me,
ITextRange **  ppRange 
)
static

Definition at line 1659 of file richole.c.

1660{
1662
1663 TRACE("(%p)->(%p)\n", This, ppRange);
1664
1665 if (!This->child.reole)
1666 return CO_E_RELEASED;
1667
1668 if (!ppRange)
1669 return E_INVALIDARG;
1670
1671 return CreateITextRange(This->child.reole, This->start, This->end, ppRange);
1672}

◆ ITextRange_fnGetEmbeddedObject()

static HRESULT WINAPI ITextRange_fnGetEmbeddedObject ( ITextRange me,
IUnknown **  ppv 
)
static

Definition at line 2654 of file richole.c.

2655{
2657
2658 FIXME("(%p)->(%p): stub\n", This, ppv);
2659
2660 if (!This->child.reole)
2661 return CO_E_RELEASED;
2662
2663 return E_NOTIMPL;
2664}
REFIID LPVOID * ppv
Definition: atlbase.h:39

◆ ITextRange_fnGetEnd()

static HRESULT WINAPI ITextRange_fnGetEnd ( ITextRange me,
LONG end 
)
static

Definition at line 1746 of file richole.c.

1747{
1749
1750 TRACE("(%p)->(%p)\n", This, end);
1751
1752 if (!This->child.reole)
1753 return CO_E_RELEASED;
1754
1755 if (!end)
1756 return E_INVALIDARG;
1757
1758 *end = This->end;
1759 return S_OK;
1760}

◆ ITextRange_fnGetFont()

static HRESULT WINAPI ITextRange_fnGetFont ( ITextRange me,
ITextFont **  font 
)
static

Definition at line 1791 of file richole.c.

1792{
1794
1795 TRACE("(%p)->(%p)\n", This, font);
1796
1797 if (!This->child.reole)
1798 return CO_E_RELEASED;
1799
1800 if (!font)
1801 return E_INVALIDARG;
1802
1803 return create_textfont(me, NULL, font);
1804}
static HRESULT create_textfont(ITextRange *, const ITextFontImpl *, ITextFont **)
Definition: richole.c:3476

◆ ITextRange_fnGetFormattedText()

static HRESULT WINAPI ITextRange_fnGetFormattedText ( ITextRange me,
ITextRange **  range 
)
static

Definition at line 1674 of file richole.c.

1675{
1677
1678 FIXME("(%p)->(%p): stub\n", This, range);
1679
1680 if (!This->child.reole)
1681 return CO_E_RELEASED;
1682
1683 return E_NOTIMPL;
1684}

◆ ITextRange_fnGetIDsOfNames()

static HRESULT WINAPI ITextRange_fnGetIDsOfNames ( ITextRange me,
REFIID  riid,
LPOLESTR rgszNames,
UINT  cNames,
LCID  lcid,
DISPID rgDispId 
)
static

Definition at line 1500 of file richole.c.

1502{
1504 ITypeInfo *ti;
1505 HRESULT hr;
1506
1507 TRACE("(%p)->(%s, %p, %u, %d, %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid,
1508 rgDispId);
1509
1511 if (SUCCEEDED(hr))
1512 hr = ITypeInfo_GetIDsOfNames(ti, rgszNames, cNames, rgDispId);
1513 return hr;
1514}

◆ ITextRange_fnGetIndex()

static HRESULT WINAPI ITextRange_fnGetIndex ( ITextRange me,
LONG  unit,
LONG index 
)
static

Definition at line 1913 of file richole.c.

1914{
1916
1917 FIXME("(%p)->(%d %p): stub\n", This, unit, index);
1918
1919 if (!This->child.reole)
1920 return CO_E_RELEASED;
1921
1922 return E_NOTIMPL;
1923}

◆ ITextRange_fnGetPara()

static HRESULT WINAPI ITextRange_fnGetPara ( ITextRange me,
ITextPara **  para 
)
static

Definition at line 1822 of file richole.c.

1823{
1825
1826 TRACE("(%p)->(%p)\n", This, para);
1827
1828 if (!This->child.reole)
1829 return CO_E_RELEASED;
1830
1831 if (!para)
1832 return E_INVALIDARG;
1833
1834 return create_textpara(me, para);
1835}
static HRESULT create_textpara(ITextRange *, ITextPara **)
Definition: richole.c:4011

◆ ITextRange_fnGetPoint()

static HRESULT WINAPI ITextRange_fnGetPoint ( ITextRange me,
LONG  type,
LONG cx,
LONG cy 
)
static

Definition at line 2597 of file richole.c.

2598{
2600
2601 FIXME("(%p)->(%d %p %p): stub\n", This, type, cx, cy);
2602
2603 if (!This->child.reole)
2604 return CO_E_RELEASED;
2605
2606 return E_NOTIMPL;
2607}
_Out_opt_ int _Out_opt_ int * cy
Definition: commctrl.h:586
_Out_opt_ int * cx
Definition: commctrl.h:585

◆ ITextRange_fnGetStart()

static HRESULT WINAPI ITextRange_fnGetStart ( ITextRange me,
LONG start 
)
static

Definition at line 1698 of file richole.c.

1699{
1701
1702 TRACE("(%p)->(%p)\n", This, start);
1703
1704 if (!This->child.reole)
1705 return CO_E_RELEASED;
1706
1707 if (!start)
1708 return E_INVALIDARG;
1709
1710 *start = This->start;
1711 return S_OK;
1712}

◆ ITextRange_fnGetStoryLength()

static HRESULT WINAPI ITextRange_fnGetStoryLength ( ITextRange me,
LONG length 
)
static

Definition at line 1849 of file richole.c.

1850{
1852
1853 TRACE("(%p)->(%p)\n", This, length);
1854
1855 if (!This->child.reole)
1856 return CO_E_RELEASED;
1857
1858 return textrange_get_storylength(This->child.reole->editor, length);
1859}
static HRESULT textrange_get_storylength(ME_TextEditor *editor, LONG *length)
Definition: richole.c:283

◆ ITextRange_fnGetStoryType()

static HRESULT WINAPI ITextRange_fnGetStoryType ( ITextRange me,
LONG value 
)
static

Definition at line 1861 of file richole.c.

1862{
1864
1865 TRACE("(%p)->(%p)\n", This, value);
1866
1867 if (!This->child.reole)
1868 return CO_E_RELEASED;
1869
1870 if (!value)
1871 return E_INVALIDARG;
1872
1874 return S_OK;
1875}
@ tomUnknownStory
Definition: tom.idl:139

◆ ITextRange_fnGetText()

static HRESULT WINAPI ITextRange_fnGetText ( ITextRange me,
BSTR str 
)
static

Definition at line 1534 of file richole.c.

1535{
1537 ME_TextEditor *editor;
1539 int length;
1540 BOOL bEOP;
1541
1542 TRACE("(%p)->(%p)\n", This, str);
1543
1544 if (!This->child.reole)
1545 return CO_E_RELEASED;
1546
1547 if (!str)
1548 return E_INVALIDARG;
1549
1550 /* return early for degenerate range */
1551 if (This->start == This->end) {
1552 *str = NULL;
1553 return S_OK;
1554 }
1555
1556 editor = This->child.reole->editor;
1557 cursor_from_char_ofs( editor, This->start, &start );
1558 cursor_from_char_ofs( editor, This->end, &end );
1559
1560 length = This->end - This->start;
1562 if (!*str)
1563 return E_OUTOFMEMORY;
1564
1565 bEOP = (!para_next( para_next( end.para )) && This->end > ME_GetTextLength(editor));
1566 ME_GetTextW(editor, *str, length, &start, length, FALSE, bEOP);
1567 return S_OK;
1568}
int ME_GetTextW(ME_TextEditor *editor, WCHAR *buffer, int buflen, const ME_Cursor *start, int srcChars, BOOL bCRLF, BOOL bEOP)
Definition: editor.c:4310
ME_Paragraph * para_next(ME_Paragraph *para) DECLSPEC_HIDDEN
Definition: para.c:57
BSTR WINAPI SysAllocStringLen(const OLECHAR *str, unsigned int len)
Definition: oleaut.c:339
const WCHAR * str

◆ ITextRange_fnGetTypeInfo()

static HRESULT WINAPI ITextRange_fnGetTypeInfo ( ITextRange me,
UINT  iTInfo,
LCID  lcid,
ITypeInfo **  ppTInfo 
)
static

Definition at line 1486 of file richole.c.

1488{
1490 HRESULT hr;
1491
1492 TRACE("(%p)->(%u,%d,%p)\n", This, iTInfo, lcid, ppTInfo);
1493
1494 hr = get_typeinfo(ITextRange_tid, ppTInfo);
1495 if (SUCCEEDED(hr))
1496 ITypeInfo_AddRef(*ppTInfo);
1497 return hr;
1498}

◆ ITextRange_fnGetTypeInfoCount()

static HRESULT WINAPI ITextRange_fnGetTypeInfoCount ( ITextRange me,
UINT pctinfo 
)
static

Definition at line 1478 of file richole.c.

1479{
1481 TRACE("(%p)->(%p)\n", This, pctinfo);
1482 *pctinfo = 1;
1483 return S_OK;
1484}

◆ ITextRange_fnInRange()

static HRESULT WINAPI ITextRange_fnInRange ( ITextRange me,
ITextRange range,
LONG ret 
)
static

Definition at line 1989 of file richole.c.

1990{
1992
1993 TRACE("(%p)->(%p %p)\n", This, range, ret);
1994
1995 if (ret)
1996 *ret = tomFalse;
1997
1998 if (!This->child.reole)
1999 return CO_E_RELEASED;
2000
2001 if (!range)
2002 return S_FALSE;
2003
2004 return textrange_inrange(This->start, This->end, range, ret);
2005}
static HRESULT textrange_inrange(LONG start, LONG end, ITextRange *range, LONG *ret)
Definition: richole.c:1974
#define S_FALSE
Definition: winerror.h:2357

◆ ITextRange_fnInStory()

static HRESULT WINAPI ITextRange_fnInStory ( ITextRange me,
ITextRange pRange,
LONG ret 
)
static

Definition at line 2007 of file richole.c.

2008{
2010
2011 FIXME("(%p)->(%p): stub\n", This, ret);
2012
2013 if (!This->child.reole)
2014 return CO_E_RELEASED;
2015
2016 return E_NOTIMPL;
2017}

◆ ITextRange_fnInvoke()

static HRESULT WINAPI ITextRange_fnInvoke ( ITextRange me,
DISPID  dispIdMember,
REFIID  riid,
LCID  lcid,
WORD  wFlags,
DISPPARAMS *  pDispParams,
VARIANT pVarResult,
EXCEPINFO *  pExcepInfo,
UINT puArgErr 
)
static

Definition at line 1516 of file richole.c.

1520{
1522 ITypeInfo *ti;
1523 HRESULT hr;
1524
1525 TRACE("(%p)->(%d, %s, %d, %u, %p, %p, %p, %p)\n", This, dispIdMember, debugstr_guid(riid),
1526 lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
1527
1529 if (SUCCEEDED(hr))
1530 hr = ITypeInfo_Invoke(ti, me, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
1531 return hr;
1532}

◆ ITextRange_fnIsEqual()

static HRESULT WINAPI ITextRange_fnIsEqual ( ITextRange me,
ITextRange range,
LONG ret 
)
static

Definition at line 2034 of file richole.c.

2035{
2037
2038 TRACE("(%p)->(%p %p)\n", This, range, ret);
2039
2040 if (ret)
2041 *ret = tomFalse;
2042
2043 if (!This->child.reole)
2044 return CO_E_RELEASED;
2045
2046 if (!range)
2047 return S_FALSE;
2048
2049 return textrange_isequal(This->start, This->end, range, ret);
2050}
static HRESULT textrange_isequal(LONG start, LONG end, ITextRange *range, LONG *ret)
Definition: richole.c:2019

◆ ITextRange_fnMove()

static HRESULT WINAPI ITextRange_fnMove ( ITextRange me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2229 of file richole.c.

2230{
2232
2233 TRACE("(%p)->(%d %d %p)\n", This, unit, count, delta);
2234
2235 if (!This->child.reole)
2236 return CO_E_RELEASED;
2237
2238 return textrange_move(me, This->child.reole->editor, unit, count, delta);
2239}
static HRESULT textrange_move(ITextRange *range, ME_TextEditor *editor, LONG unit, LONG count, LONG *delta)
Definition: richole.c:2163

◆ ITextRange_fnMoveEnd()

static HRESULT WINAPI ITextRange_fnMoveEnd ( ITextRange me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2358 of file richole.c.

2360{
2362
2363 TRACE("(%p)->(%d %d %p)\n", This, unit, count, delta);
2364
2365 if (!This->child.reole)
2366 return CO_E_RELEASED;
2367
2368 return textrange_moveend(me, This->child.reole->editor, unit, count, delta);
2369}
static HRESULT textrange_moveend(ITextRange *range, ME_TextEditor *editor, LONG unit, LONG count, LONG *delta)
Definition: richole.c:2297

◆ ITextRange_fnMoveEndUntil()

static HRESULT WINAPI ITextRange_fnMoveEndUntil ( ITextRange me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 2436 of file richole.c.

2438{
2440
2441 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
2442
2443 if (!This->child.reole)
2444 return CO_E_RELEASED;
2445
2446 return E_NOTIMPL;
2447}
CFF_Charset charset
Definition: cffcmap.c:138

◆ ITextRange_fnMoveEndWhile()

static HRESULT WINAPI ITextRange_fnMoveEndWhile ( ITextRange me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 2397 of file richole.c.

2399{
2401
2402 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
2403
2404 if (!This->child.reole)
2405 return CO_E_RELEASED;
2406
2407 return E_NOTIMPL;
2408}

◆ ITextRange_fnMoveStart()

static HRESULT WINAPI ITextRange_fnMoveStart ( ITextRange me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2284 of file richole.c.

2286{
2288
2289 TRACE("(%p)->(%d %d %p)\n", This, unit, count, delta);
2290
2291 if (!This->child.reole)
2292 return CO_E_RELEASED;
2293
2294 return textrange_movestart(me, This->child.reole->editor, unit, count, delta);
2295}
static HRESULT textrange_movestart(ITextRange *range, ME_TextEditor *editor, LONG unit, LONG count, LONG *delta)
Definition: richole.c:2241

◆ ITextRange_fnMoveStartUntil()

static HRESULT WINAPI ITextRange_fnMoveStartUntil ( ITextRange me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 2423 of file richole.c.

2425{
2427
2428 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
2429
2430 if (!This->child.reole)
2431 return CO_E_RELEASED;
2432
2433 return E_NOTIMPL;
2434}

◆ ITextRange_fnMoveStartWhile()

static HRESULT WINAPI ITextRange_fnMoveStartWhile ( ITextRange me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 2384 of file richole.c.

2386{
2388
2389 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
2390
2391 if (!This->child.reole)
2392 return CO_E_RELEASED;
2393
2394 return E_NOTIMPL;
2395}

◆ ITextRange_fnMoveUntil()

static HRESULT WINAPI ITextRange_fnMoveUntil ( ITextRange me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 2410 of file richole.c.

2412{
2414
2415 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
2416
2417 if (!This->child.reole)
2418 return CO_E_RELEASED;
2419
2420 return E_NOTIMPL;
2421}

◆ ITextRange_fnMoveWhile()

static HRESULT WINAPI ITextRange_fnMoveWhile ( ITextRange me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 2371 of file richole.c.

2373{
2375
2376 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
2377
2378 if (!This->child.reole)
2379 return CO_E_RELEASED;
2380
2381 return E_NOTIMPL;
2382}

◆ ITextRange_fnPaste()

static HRESULT WINAPI ITextRange_fnPaste ( ITextRange me,
VARIANT v,
LONG  format 
)
static

Definition at line 2549 of file richole.c.

2550{
2552
2553 FIXME("(%p)->(%s %x): stub\n", This, debugstr_variant(v), format);
2554
2555 if (!This->child.reole)
2556 return CO_E_RELEASED;
2557
2558 return E_NOTIMPL;
2559}

◆ ITextRange_fnQueryInterface()

static HRESULT WINAPI ITextRange_fnQueryInterface ( ITextRange me,
REFIID  riid,
void **  ppvObj 
)
static

Definition at line 1432 of file richole.c.

1433{
1435
1436 *ppvObj = NULL;
1439 || IsEqualGUID(riid, &IID_ITextRange))
1440 {
1441 *ppvObj = me;
1442 ITextRange_AddRef(me);
1443 return S_OK;
1444 }
1445 else if (IsEqualGUID(riid, &IID_Igetrichole))
1446 {
1447 *ppvObj = This->child.reole;
1448 return S_OK;
1449 }
1450
1451 return E_NOINTERFACE;
1452}
const GUID IID_IDispatch

◆ ITextRange_fnRelease()

static ULONG WINAPI ITextRange_fnRelease ( ITextRange me)
static

Definition at line 1460 of file richole.c.

1461{
1464
1465 TRACE ("%p ref=%u\n", This, ref);
1466 if (ref == 0)
1467 {
1468 if (This->child.reole)
1469 {
1470 list_remove(&This->child.entry);
1471 This->child.reole = NULL;
1472 }
1473 heap_free(This);
1474 }
1475 return ref;
1476}

◆ ITextRange_fnScrollIntoView()

static HRESULT WINAPI ITextRange_fnScrollIntoView ( ITextRange me,
LONG  value 
)
static

Definition at line 2622 of file richole.c.

2623{
2625 ME_TextEditor *editor;
2627 int x, y, height;
2628
2629 TRACE("(%p)->(%d)\n", This, value);
2630
2631 if (!This->child.reole)
2632 return CO_E_RELEASED;
2633
2634 editor = This->child.reole->editor;
2635
2636 switch (value)
2637 {
2638 case tomStart:
2639 cursor_from_char_ofs( editor, This->start, &cursor );
2640 cursor_coords( editor, &cursor, &x, &y, &height );
2641 break;
2642 case tomEnd:
2643 cursor_from_char_ofs( editor, This->end, &cursor );
2644 cursor_coords( editor, &cursor, &x, &y, &height );
2645 break;
2646 default:
2647 FIXME("bStart value %d not handled\n", value);
2648 return E_NOTIMPL;
2649 }
2650 scroll_abs( editor, x, y, TRUE );
2651 return S_OK;
2652}
void cursor_coords(ME_TextEditor *editor, ME_Cursor *cursor, int *x, int *y, int *height)
Definition: caret.c:221
void scroll_abs(ME_TextEditor *editor, int x, int y, BOOL notify) DECLSPEC_HIDDEN
Definition: paint.c:1087
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
@ tomEnd
Definition: tom.idl:66
@ tomStart
Definition: tom.idl:67

◆ ITextRange_fnSelect()

static HRESULT WINAPI ITextRange_fnSelect ( ITextRange me)
static

Definition at line 2052 of file richole.c.

2053{
2055
2056 TRACE("(%p)\n", This);
2057
2058 if (!This->child.reole)
2059 return CO_E_RELEASED;
2060
2061 set_selection(This->child.reole->editor, This->start, This->end);
2062 return S_OK;
2063}
#define set_selection(hctl, start, end)

◆ ITextRange_fnSetChar()

static HRESULT WINAPI ITextRange_fnSetChar ( ITextRange me,
LONG  ch 
)
static

Definition at line 1645 of file richole.c.

1646{
1648
1649 FIXME("(%p)->(%x): stub\n", This, ch);
1650
1651 if (!This->child.reole)
1652 return CO_E_RELEASED;
1653
1654 return E_NOTIMPL;
1655}

◆ ITextRange_fnSetEnd()

static HRESULT WINAPI ITextRange_fnSetEnd ( ITextRange me,
LONG  value 
)
static

Definition at line 1779 of file richole.c.

1780{
1782
1783 TRACE("(%p)->(%d)\n", This, value);
1784
1785 if (!This->child.reole)
1786 return CO_E_RELEASED;
1787
1788 return textrange_setend(This->child.reole, value, &This->start, &This->end);
1789}
static HRESULT textrange_setend(const struct text_services *services, LONG value, LONG *start, LONG *end)
Definition: richole.c:1762

◆ ITextRange_fnSetFont()

static HRESULT WINAPI ITextRange_fnSetFont ( ITextRange me,
ITextFont font 
)
static

Definition at line 1806 of file richole.c.

1807{
1809
1810 TRACE("(%p)->(%p)\n", This, font);
1811
1812 if (!font)
1813 return E_INVALIDARG;
1814
1815 if (!This->child.reole)
1816 return CO_E_RELEASED;
1817
1819 return S_OK;
1820}
static void textrange_set_font(ITextRange *range, ITextFont *font)
Definition: richole.c:491

◆ ITextRange_fnSetFormattedText()

static HRESULT WINAPI ITextRange_fnSetFormattedText ( ITextRange me,
ITextRange range 
)
static

Definition at line 1686 of file richole.c.

1687{
1689
1690 FIXME("(%p)->(%p): stub\n", This, range);
1691
1692 if (!This->child.reole)
1693 return CO_E_RELEASED;
1694
1695 return E_NOTIMPL;
1696}

◆ ITextRange_fnSetIndex()

static HRESULT WINAPI ITextRange_fnSetIndex ( ITextRange me,
LONG  unit,
LONG  index,
LONG  extend 
)
static

Definition at line 1925 of file richole.c.

1927{
1929
1930 FIXME("(%p)->(%d %d %d): stub\n", This, unit, index, extend);
1931
1932 if (!This->child.reole)
1933 return CO_E_RELEASED;
1934
1935 return E_NOTIMPL;
1936}

◆ ITextRange_fnSetPara()

static HRESULT WINAPI ITextRange_fnSetPara ( ITextRange me,
ITextPara para 
)
static

Definition at line 1837 of file richole.c.

1838{
1840
1841 FIXME("(%p)->(%p): stub\n", This, para);
1842
1843 if (!This->child.reole)
1844 return CO_E_RELEASED;
1845
1846 return E_NOTIMPL;
1847}

◆ ITextRange_fnSetPoint()

static HRESULT WINAPI ITextRange_fnSetPoint ( ITextRange me,
LONG  x,
LONG  y,
LONG  type,
LONG  extend 
)
static

Definition at line 2609 of file richole.c.

2611{
2613
2614 FIXME("(%p)->(%d %d %d %d): stub\n", This, x, y, type, extend);
2615
2616 if (!This->child.reole)
2617 return CO_E_RELEASED;
2618
2619 return E_NOTIMPL;
2620}

◆ ITextRange_fnSetRange()

static HRESULT WINAPI ITextRange_fnSetRange ( ITextRange me,
LONG  anchor,
LONG  active 
)
static

Definition at line 1956 of file richole.c.

1957{
1959
1960 TRACE("(%p)->(%d %d)\n", This, anchor, active);
1961
1962 if (!This->child.reole)
1963 return CO_E_RELEASED;
1964
1965 cp2range(This->child.reole->editor, &anchor, &active);
1966 if (anchor == This->start && active == This->end)
1967 return S_FALSE;
1968
1969 This->start = anchor;
1970 This->end = active;
1971 return S_OK;
1972}

◆ ITextRange_fnSetStart()

static HRESULT WINAPI ITextRange_fnSetStart ( ITextRange me,
LONG  value 
)
static

Definition at line 1734 of file richole.c.

1735{
1737
1738 TRACE("(%p)->(%d)\n", This, value);
1739
1740 if (!This->child.reole)
1741 return CO_E_RELEASED;
1742
1743 return textrange_setstart(This->child.reole, value, &This->start, &This->end);
1744}
static HRESULT textrange_setstart(const struct text_services *services, LONG value, LONG *start, LONG *end)
Definition: richole.c:1714

◆ ITextRange_fnSetText()

static HRESULT WINAPI ITextRange_fnSetText ( ITextRange me,
BSTR  str 
)
static

Definition at line 1570 of file richole.c.

1571{
1573 ME_TextEditor *editor;
1575 ME_Style *style;
1576 int len;
1577
1578 TRACE("(%p)->(%s)\n", This, debugstr_w(str));
1579
1580 if (!This->child.reole)
1581 return CO_E_RELEASED;
1582
1583 editor = This->child.reole->editor;
1584
1585 /* delete only where's something to delete */
1586 if (This->start != This->end)
1587 {
1588 cursor_from_char_ofs( editor, This->start, &cursor );
1589 ME_InternalDeleteText(editor, &cursor, This->end - This->start, FALSE);
1590 }
1591
1592 if (!str || !*str)
1593 {
1594 /* will update this range as well */
1595 textranges_update_ranges(This->child.reole, This->start, This->end, RANGE_UPDATE_DELETE);
1596 return S_OK;
1597 }
1598
1599 /* it's safer not to rely on stored BSTR length */
1600 len = lstrlenW(str);
1601 cursor = editor->pCursors[0];
1602 cursor_from_char_ofs( editor, This->start, &editor->pCursors[0] );
1603 style = style_get_insert_style( editor, editor->pCursors );
1604 ME_InsertTextFromCursor(editor, 0, str, len, style);
1606 editor->pCursors[0] = cursor;
1607
1608 if (len < This->end - This->start)
1609 textranges_update_ranges(This->child.reole, This->start + len, This->end, RANGE_UPDATE_DELETE);
1610 else
1611 This->end = len - This->start;
1612
1613 return S_OK;
1614}
Arabic default style
Definition: afstyles.h:94
#define lstrlenW
Definition: compat.h:750
void ME_InsertTextFromCursor(ME_TextEditor *editor, int nCursor, const WCHAR *str, int len, ME_Style *style)
Definition: caret.c:553
BOOL ME_InternalDeleteText(ME_TextEditor *editor, ME_Cursor *start, int nChars, BOOL bForce)
Definition: caret.c:339
static void textranges_update_ranges(struct text_services *services, LONG start, LONG end, enum range_update_op op)
Definition: richole.c:292
void ME_ReleaseStyle(ME_Style *item) DECLSPEC_HIDDEN
Definition: style.c:462
ME_Style * style_get_insert_style(ME_TextEditor *editor, ME_Cursor *cursor) DECLSPEC_HIDDEN
Definition: style.c:476
ME_Cursor * pCursors
Definition: editstr.h:389

◆ ITextRange_fnStartOf()

static HRESULT WINAPI ITextRange_fnStartOf ( ITextRange me,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 2097 of file richole.c.

2099{
2101
2102 TRACE("(%p)->(%d %d %p)\n", This, unit, extend, delta);
2103
2104 if (!This->child.reole)
2105 return CO_E_RELEASED;
2106
2107 return textrange_startof(me, unit, extend, delta);
2108}
static HRESULT textrange_startof(ITextRange *range, LONG unit, LONG extend, LONG *delta)
Definition: richole.c:2065

◆ ITextSelection_fnAddRef()

static ULONG WINAPI ITextSelection_fnAddRef ( ITextSelection me)
static

Definition at line 4547 of file richole.c.

4548{
4550 return InterlockedIncrement(&This->ref);
4551}
static struct text_selection * impl_from_ITextSelection(ITextSelection *iface)
Definition: richole.c:264

◆ ITextSelection_fnCanEdit()

static HRESULT WINAPI ITextSelection_fnCanEdit ( ITextSelection me,
LONG ret 
)
static

Definition at line 5354 of file richole.c.

5355{
5357
5358 FIXME("(%p)->(%p): stub\n", This, ret);
5359
5360 if (!This->services)
5361 return CO_E_RELEASED;
5362
5363 return E_NOTIMPL;
5364}

◆ ITextSelection_fnCanPaste()

static HRESULT WINAPI ITextSelection_fnCanPaste ( ITextSelection me,
VARIANT v,
LONG  format,
LONG ret 
)
static

Definition at line 5341 of file richole.c.

5343{
5345
5346 FIXME("(%p)->(%s %x %p): stub\n", This, debugstr_variant(v), format, ret);
5347
5348 if (!This->services)
5349 return CO_E_RELEASED;
5350
5351 return E_NOTIMPL;
5352}

◆ ITextSelection_fnChangeCase()

static HRESULT WINAPI ITextSelection_fnChangeCase ( ITextSelection me,
LONG  type 
)
static

Definition at line 5366 of file richole.c.

5367{
5369
5370 FIXME("(%p)->(%d): stub\n", This, type);
5371
5372 if (!This->services)
5373 return CO_E_RELEASED;
5374
5375 return E_NOTIMPL;
5376}

◆ ITextSelection_fnCollapse()

static HRESULT WINAPI ITextSelection_fnCollapse ( ITextSelection me,
LONG  bStart 
)
static

Definition at line 4924 of file richole.c.

4925{
4927 LONG start, end;
4928 HRESULT hres;
4929
4930 TRACE("(%p)->(%d)\n", This, bStart);
4931
4932 if (!This->services)
4933 return CO_E_RELEASED;
4934
4935 ME_GetSelectionOfs(This->services->editor, &start, &end);
4936 hres = range_Collapse(bStart, &start, &end);
4937 if (SUCCEEDED(hres))
4938 set_selection(This->services->editor, start, end);
4939 return hres;
4940}
HRESULT hres
Definition: protocol.c:465

◆ ITextSelection_fnCopy()

static HRESULT WINAPI ITextSelection_fnCopy ( ITextSelection me,
VARIANT v 
)
static

Definition at line 5312 of file richole.c.

5313{
5316 HRESULT hr;
5317
5318 TRACE("(%p)->(%p)\n", This, v);
5319
5320 if (!This->services)
5321 return CO_E_RELEASED;
5322
5323 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5324 hr = textrange_copy_or_cut(range, This->services->editor, FALSE, v);
5325 ITextRange_Release(range);
5326 return hr;
5327}

◆ ITextSelection_fnCut()

static HRESULT WINAPI ITextSelection_fnCut ( ITextSelection me,
VARIANT v 
)
static

Definition at line 5295 of file richole.c.

5296{
5299 HRESULT hr;
5300
5301 TRACE("(%p)->(%p): stub\n", This, v);
5302
5303 if (!This->services)
5304 return CO_E_RELEASED;
5305
5306 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5307 hr = textrange_copy_or_cut(range, This->services->editor, TRUE, v);
5308 ITextRange_Release(range);
5309 return hr;
5310}

◆ ITextSelection_fnDelete()

static HRESULT WINAPI ITextSelection_fnDelete ( ITextSelection me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 5282 of file richole.c.

5284{
5286
5287 FIXME("(%p)->(%d %d %p): stub\n", This, unit, count, delta);
5288
5289 if (!This->services)
5290 return CO_E_RELEASED;
5291
5292 return E_NOTIMPL;
5293}

◆ ITextSelection_fnEndKey()

static HRESULT WINAPI ITextSelection_fnEndKey ( ITextSelection me,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 5529 of file richole.c.

5531{
5533
5534 FIXME("(%p)->(%d %d %p): stub\n", This, unit, extend, delta);
5535
5536 if (!This->services)
5537 return CO_E_RELEASED;
5538
5539 return E_NOTIMPL;
5540}

◆ ITextSelection_fnEndOf()

static HRESULT WINAPI ITextSelection_fnEndOf ( ITextSelection me,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 5093 of file richole.c.

5095{
5098 HRESULT hr;
5099
5100 TRACE("(%p)->(%d %d %p)\n", This, unit, extend, delta);
5101
5102 if (!This->services)
5103 return CO_E_RELEASED;
5104
5105 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5106 hr = textrange_endof(range, This->services->editor, unit, extend, delta);
5107 ITextRange_Release(range);
5108 return hr;
5109}

◆ ITextSelection_fnExpand()

static HRESULT WINAPI ITextSelection_fnExpand ( ITextSelection me,
LONG  unit,
LONG delta 
)
static

Definition at line 4942 of file richole.c.

4943{
4946 HRESULT hr;
4947
4948 TRACE("(%p)->(%d %p)\n", This, unit, delta);
4949
4950 if (!This->services)
4951 return CO_E_RELEASED;
4952
4953 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
4954 hr = textrange_expand(range, unit, delta);
4955 ITextRange_Release(range);
4956 return hr;
4957}

◆ ITextSelection_fnFindText()

static HRESULT WINAPI ITextSelection_fnFindText ( ITextSelection me,
BSTR  text,
LONG  count,
LONG  flags,
LONG length 
)
static

Definition at line 5242 of file richole.c.

5244{
5246
5247 FIXME("(%p)->(%s %d %x %p): stub\n", This, debugstr_w(text), count, flags, length);
5248
5249 if (!This->services)
5250 return CO_E_RELEASED;
5251
5252 FIXME("not implemented\n");
5253 return E_NOTIMPL;
5254}

◆ ITextSelection_fnFindTextEnd()

static HRESULT WINAPI ITextSelection_fnFindTextEnd ( ITextSelection me,
BSTR  text,
LONG  count,
LONG  flags,
LONG length 
)
static

Definition at line 5269 of file richole.c.

5271{
5273
5274 FIXME("(%p)->(%s %d %x %p): stub\n", This, debugstr_w(text), count, flags, length);
5275
5276 if (!This->services)
5277 return CO_E_RELEASED;
5278
5279 return E_NOTIMPL;
5280}

◆ ITextSelection_fnFindTextStart()

static HRESULT WINAPI ITextSelection_fnFindTextStart ( ITextSelection me,
BSTR  text,
LONG  count,
LONG  flags,
LONG length 
)
static

Definition at line 5256 of file richole.c.

5258{
5260
5261 FIXME("(%p)->(%s %d %x %p): stub\n", This, debugstr_w(text), count, flags, length);
5262
5263 if (!This->services)
5264 return CO_E_RELEASED;
5265
5266 return E_NOTIMPL;
5267}

◆ ITextSelection_fnGetChar()

static HRESULT WINAPI ITextSelection_fnGetChar ( ITextSelection me,
LONG pch 
)
static

Definition at line 4682 of file richole.c.

4683{
4685 ME_Cursor *start = NULL, *end = NULL;
4686
4687 TRACE("(%p)->(%p)\n", This, pch);
4688
4689 if (!This->services)
4690 return CO_E_RELEASED;
4691
4692 if (!pch)
4693 return E_INVALIDARG;
4694
4695 ME_GetSelection(This->services->editor, &start, &end);
4696 return range_GetChar(This->services->editor, start, pch);
4697}

◆ ITextSelection_fnGetDuplicate()

static HRESULT WINAPI ITextSelection_fnGetDuplicate ( ITextSelection me,
ITextRange **  range 
)
static

Definition at line 4711 of file richole.c.

4712{
4714 LONG start, end;
4715
4716 TRACE("(%p)->(%p)\n", This, range);
4717
4718 if (!This->services)
4719 return CO_E_RELEASED;
4720
4721 if (!range)
4722 return E_INVALIDARG;
4723
4724 ITextSelection_GetStart(me, &start);
4725 ITextSelection_GetEnd(me, &end);
4726 return CreateITextRange(This->services, start, end, range);
4727}

◆ ITextSelection_fnGetEmbeddedObject()

static HRESULT WINAPI ITextSelection_fnGetEmbeddedObject ( ITextSelection me,
IUnknown **  ppv 
)
static

Definition at line 5415 of file richole.c.

5416{
5418
5419 FIXME("(%p)->(%p): stub\n", This, ppv);
5420
5421 if (!This->services)
5422 return CO_E_RELEASED;
5423
5424 return E_NOTIMPL;
5425}

◆ ITextSelection_fnGetEnd()

static HRESULT WINAPI ITextSelection_fnGetEnd ( ITextSelection me,
LONG pcpLim 
)
static

Definition at line 4789 of file richole.c.

4790{
4792 LONG first;
4793
4794 TRACE("(%p)->(%p)\n", This, pcpLim);
4795
4796 if (!This->services)
4797 return CO_E_RELEASED;
4798
4799 if (!pcpLim)
4800 return E_INVALIDARG;
4801 ME_GetSelectionOfs(This->services->editor, &first, pcpLim);
4802 return S_OK;
4803}
const GLint * first
Definition: glext.h:5794

◆ ITextSelection_fnGetFlags()

static HRESULT WINAPI ITextSelection_fnGetFlags ( ITextSelection me,
LONG flags 
)
static

Definition at line 5428 of file richole.c.

5429{
5431
5432 FIXME("(%p)->(%p): stub\n", This, flags);
5433
5434 if (!This->services)
5435 return CO_E_RELEASED;
5436
5437 return E_NOTIMPL;
5438}

◆ ITextSelection_fnGetFont()

static HRESULT WINAPI ITextSelection_fnGetFont ( ITextSelection me,
ITextFont **  font 
)
static

Definition at line 4824 of file richole.c.

4825{
4828 HRESULT hr;
4829
4830 TRACE("(%p)->(%p)\n", This, font);
4831
4832 if (!This->services)
4833 return CO_E_RELEASED;
4834
4835 if (!font)
4836 return E_INVALIDARG;
4837
4838 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
4840 ITextRange_Release(range);
4841 return hr;
4842}

◆ ITextSelection_fnGetFormattedText()

static HRESULT WINAPI ITextSelection_fnGetFormattedText ( ITextSelection me,
ITextRange **  range 
)
static

Definition at line 4729 of file richole.c.

4730{
4732
4733 FIXME("(%p)->(%p): stub\n", This, range);
4734
4735 if (!This->services)
4736 return CO_E_RELEASED;
4737
4738 return E_NOTIMPL;
4739}

◆ ITextSelection_fnGetIDsOfNames()

static HRESULT WINAPI ITextSelection_fnGetIDsOfNames ( ITextSelection me,
REFIID  riid,
LPOLESTR rgszNames,
UINT  cNames,
LCID  lcid,
DISPID rgDispId 
)
static

Definition at line 4584 of file richole.c.

4586{
4588 ITypeInfo *ti;
4589 HRESULT hr;
4590
4591 TRACE("(%p)->(%s, %p, %u, %d, %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid,
4592 rgDispId);
4593
4595 if (SUCCEEDED(hr))
4596 hr = ITypeInfo_GetIDsOfNames(ti, rgszNames, cNames, rgDispId);
4597 return hr;
4598}

◆ ITextSelection_fnGetIndex()

static HRESULT WINAPI ITextSelection_fnGetIndex ( ITextSelection me,
LONG  unit,
LONG index 
)
static

Definition at line 4959 of file richole.c.

4960{
4962
4963 FIXME("(%p)->(%d %p): stub\n", This, unit, index);
4964
4965 if (!This->services)
4966 return CO_E_RELEASED;
4967
4968 return E_NOTIMPL;
4969}

◆ ITextSelection_fnGetPara()

static HRESULT WINAPI ITextSelection_fnGetPara ( ITextSelection me,
ITextPara **  para 
)
static

Definition at line 4863 of file richole.c.

4864{
4867 HRESULT hr;
4868
4869 TRACE("(%p)->(%p)\n", This, para);
4870
4871 if (!This->services)
4872 return CO_E_RELEASED;
4873
4874 if (!para)
4875 return E_INVALIDARG;
4876
4877 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
4878 hr = create_textpara(range, para);
4879 ITextRange_Release(range);
4880 return hr;
4881}

◆ ITextSelection_fnGetPoint()

static HRESULT WINAPI ITextSelection_fnGetPoint ( ITextSelection me,
LONG  type,
LONG cx,
LONG cy 
)
static

Definition at line 5378 of file richole.c.

5379{
5381
5382 FIXME("(%p)->(%d %p %p): stub\n", This, type, cx, cy);
5383
5384 if (!This->services)
5385 return CO_E_RELEASED;
5386
5387 return E_NOTIMPL;
5388}

◆ ITextSelection_fnGetStart()

static HRESULT WINAPI ITextSelection_fnGetStart ( ITextSelection me,
LONG pcpFirst 
)
static

Definition at line 4754 of file richole.c.

4755{
4757 LONG lim;
4758
4759 TRACE("(%p)->(%p)\n", This, pcpFirst);
4760
4761 if (!This->services)
4762 return CO_E_RELEASED;
4763
4764 if (!pcpFirst)
4765 return E_INVALIDARG;
4766 ME_GetSelectionOfs(This->services->editor, pcpFirst, &lim);
4767 return S_OK;
4768}

◆ ITextSelection_fnGetStoryLength()

static HRESULT WINAPI ITextSelection_fnGetStoryLength ( ITextSelection me,
LONG length 
)
static

Definition at line 4896 of file richole.c.

4897{
4899
4900 TRACE("(%p)->(%p)\n", This, length);
4901
4902 if (!This->services)
4903 return CO_E_RELEASED;
4904
4905 return textrange_get_storylength(This->services->editor, length);
4906}

◆ ITextSelection_fnGetStoryType()

static HRESULT WINAPI ITextSelection_fnGetStoryType ( ITextSelection me,
LONG value 
)
static

Definition at line 4908 of file richole.c.

4909{
4911
4912 TRACE("(%p)->(%p)\n", This, value);
4913
4914 if (!This->services)
4915 return CO_E_RELEASED;
4916
4917 if (!value)
4918 return E_INVALIDARG;
4919
4921 return S_OK;
4922}

◆ ITextSelection_fnGetText()

static HRESULT WINAPI ITextSelection_fnGetText ( ITextSelection me,
BSTR pbstr 
)
static

Definition at line 4625 of file richole.c.

4626{
4628 ME_Cursor *start = NULL, *end = NULL;
4629 int nChars, endOfs;
4630 BOOL bEOP;
4631
4632 TRACE("(%p)->(%p)\n", This, pbstr);
4633
4634 if (!This->services)
4635 return CO_E_RELEASED;
4636
4637 if (!pbstr)
4638 return E_INVALIDARG;
4639
4640 ME_GetSelection(This->services->editor, &start, &end);
4641 endOfs = ME_GetCursorOfs(end);
4642 nChars = endOfs - ME_GetCursorOfs(start);
4643 if (!nChars)
4644 {
4645 *pbstr = NULL;
4646 return S_OK;
4647 }
4648
4649 *pbstr = SysAllocStringLen(NULL, nChars);
4650 if (!*pbstr)
4651 return E_OUTOFMEMORY;
4652
4653 bEOP = (!para_next( para_next( end->para ) ) && endOfs > ME_GetTextLength(This->services->editor));
4654 ME_GetTextW(This->services->editor, *pbstr, nChars, start, nChars, FALSE, bEOP);
4655 TRACE("%s\n", wine_dbgstr_w(*pbstr));
4656
4657 return S_OK;
4658}
int ME_GetCursorOfs(const ME_Cursor *cursor)
Definition: caret.c:889
#define wine_dbgstr_w
Definition: kernel32.h:34

◆ ITextSelection_fnGetType()

static HRESULT WINAPI ITextSelection_fnGetType ( ITextSelection me,
LONG type 
)
static

Definition at line 5452 of file richole.c.

5453{
5455
5456 FIXME("(%p)->(%p): stub\n", This, type);
5457
5458 if (!This->services)
5459 return CO_E_RELEASED;
5460
5461 return E_NOTIMPL;
5462}

◆ ITextSelection_fnGetTypeInfo()

static HRESULT WINAPI ITextSelection_fnGetTypeInfo ( ITextSelection me,
UINT  iTInfo,
LCID  lcid,
ITypeInfo **  ppTInfo 
)
static

Definition at line 4570 of file richole.c.

4572{
4574 HRESULT hr;
4575
4576 TRACE("(%p)->(%u,%d,%p)\n", This, iTInfo, lcid, ppTInfo);
4577
4579 if (SUCCEEDED(hr))
4580 ITypeInfo_AddRef(*ppTInfo);
4581 return hr;
4582}

◆ ITextSelection_fnGetTypeInfoCount()

static HRESULT WINAPI ITextSelection_fnGetTypeInfoCount ( ITextSelection me,
UINT pctinfo 
)
static

Definition at line 4562 of file richole.c.

4563{
4565 TRACE("(%p)->(%p)\n", This, pctinfo);
4566 *pctinfo = 1;
4567 return S_OK;
4568}

◆ ITextSelection_fnHomeKey()

static HRESULT WINAPI ITextSelection_fnHomeKey ( ITextSelection me,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 5516 of file richole.c.

5518{
5520
5521 FIXME("(%p)->(%d %d %p): stub\n", This, unit, extend, delta);
5522
5523 if (!This->services)
5524 return CO_E_RELEASED;
5525
5526 return E_NOTIMPL;
5527}

◆ ITextSelection_fnInRange()

static HRESULT WINAPI ITextSelection_fnInRange ( ITextSelection me,
ITextRange range,
LONG ret 
)
static

Definition at line 4996 of file richole.c.

4997{
5000 LONG start, end;
5001
5002 TRACE("(%p)->(%p %p)\n", This, range, ret);
5003
5004 if (ret)
5005 *ret = tomFalse;
5006
5007 if (!This->services)
5008 return CO_E_RELEASED;
5009
5010 if (!range)
5011 return S_FALSE;
5012
5013 ITextRange_QueryInterface(range, &IID_ITextSelection, (void**)&selection);
5014 if (!selection)
5015 return S_FALSE;
5016 ITextSelection_Release(selection);
5017
5018 ITextSelection_GetStart(me, &start);
5019 ITextSelection_GetEnd(me, &end);
5020 return textrange_inrange(start, end, range, ret);
5021}

◆ ITextSelection_fnInStory()

static HRESULT WINAPI ITextSelection_fnInStory ( ITextSelection me,
ITextRange range,
LONG ret 
)
static

Definition at line 5023 of file richole.c.

5024{
5026
5027 FIXME("(%p)->(%p %p): stub\n", This, range, ret);
5028
5029 if (!This->services)
5030 return CO_E_RELEASED;
5031
5032 return E_NOTIMPL;
5033}

◆ ITextSelection_fnInvoke()

static HRESULT WINAPI ITextSelection_fnInvoke ( ITextSelection me,
DISPID  dispIdMember,
REFIID  riid,
LCID  lcid,
WORD  wFlags,
DISPPARAMS *  pDispParams,
VARIANT pVarResult,
EXCEPINFO *  pExcepInfo,
UINT puArgErr 
)
static

Definition at line 4600 of file richole.c.

4610{
4612 ITypeInfo *ti;
4613 HRESULT hr;
4614
4615 TRACE("(%p)->(%d, %s, %d, %u, %p, %p, %p, %p)\n", This, dispIdMember, debugstr_guid(riid), lcid,
4616 wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
4617
4619 if (SUCCEEDED(hr))
4620 hr = ITypeInfo_Invoke(ti, me, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
4621 return hr;
4622}

◆ ITextSelection_fnIsEqual()

static HRESULT WINAPI ITextSelection_fnIsEqual ( ITextSelection me,
ITextRange range,
LONG ret 
)
static

Definition at line 5035 of file richole.c.

5036{
5039 LONG start, end;
5040
5041 TRACE("(%p)->(%p %p)\n", This, range, ret);
5042
5043 if (ret)
5044 *ret = tomFalse;
5045
5046 if (!This->services)
5047 return CO_E_RELEASED;
5048
5049 if (!range)
5050 return S_FALSE;
5051
5052 ITextRange_QueryInterface(range, &IID_ITextSelection, (void**)&selection);
5053 if (!selection)
5054 return S_FALSE;
5055 ITextSelection_Release(selection);
5056
5057 ITextSelection_GetStart(me, &start);
5058 ITextSelection_GetEnd(me, &end);
5059 return textrange_isequal(start, end, range, ret);
5060}

◆ ITextSelection_fnMove()

static HRESULT WINAPI ITextSelection_fnMove ( ITextSelection me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 5111 of file richole.c.

5112{
5115 HRESULT hr;
5116
5117 TRACE("(%p)->(%d %d %p)\n", This, unit, count, delta);
5118
5119 if (!This->services)
5120 return CO_E_RELEASED;
5121
5122 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5123 hr = textrange_movestart(range, This->services->editor, unit, count, delta);
5124 ITextRange_Release(range);
5125 return hr;
5126}

◆ ITextSelection_fnMoveDown()

static HRESULT WINAPI ITextSelection_fnMoveDown ( ITextSelection me,
LONG  unit,
LONG  count,
LONG  extend,
LONG delta 
)
static

Definition at line 5503 of file richole.c.

5505{
5507
5508 FIXME("(%p)->(%d %d %d %p): stub\n", This, unit, count, extend, delta);
5509
5510 if (!This->services)
5511 return CO_E_RELEASED;
5512
5513 return E_NOTIMPL;
5514}

◆ ITextSelection_fnMoveEnd()

static HRESULT WINAPI ITextSelection_fnMoveEnd ( ITextSelection me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 5146 of file richole.c.

5148{
5151 HRESULT hr;
5152
5153 TRACE("(%p)->(%d %d %p)\n", This, unit, count, delta);
5154
5155 if (!This->services)
5156 return CO_E_RELEASED;
5157
5158 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5159 hr = textrange_moveend(range, This->services->editor, unit, count, delta);
5160 ITextRange_Release(range);
5161 return hr;
5162}

◆ ITextSelection_fnMoveEndUntil()

static HRESULT WINAPI ITextSelection_fnMoveEndUntil ( ITextSelection me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 5229 of file richole.c.

5231{
5233
5234 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
5235
5236 if (!This->services)
5237 return CO_E_RELEASED;
5238
5239 return E_NOTIMPL;
5240}

◆ ITextSelection_fnMoveEndWhile()

static HRESULT WINAPI ITextSelection_fnMoveEndWhile ( ITextSelection me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 5190 of file richole.c.

5192{
5194
5195 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
5196
5197 if (!This->services)
5198 return CO_E_RELEASED;
5199
5200 return E_NOTIMPL;
5201}

◆ ITextSelection_fnMoveLeft()

static HRESULT WINAPI ITextSelection_fnMoveLeft ( ITextSelection me,
LONG  unit,
LONG  count,
LONG  extend,
LONG delta 
)
static

Definition at line 5464 of file richole.c.

5466{
5468
5469 FIXME("(%p)->(%d %d %d %p): stub\n", This, unit, count, extend, delta);
5470
5471 if (!This->services)
5472 return CO_E_RELEASED;
5473
5474 return E_NOTIMPL;
5475}

◆ ITextSelection_fnMoveRight()

static HRESULT WINAPI ITextSelection_fnMoveRight ( ITextSelection me,
LONG  unit,
LONG  count,
LONG  extend,
LONG delta 
)
static

Definition at line 5477 of file richole.c.

5479{
5481
5482 FIXME("(%p)->(%d %d %d %p): stub\n", This, unit, count, extend, delta);
5483
5484 if (!This->services)
5485 return CO_E_RELEASED;
5486
5487 return E_NOTIMPL;
5488}

◆ ITextSelection_fnMoveStart()

static HRESULT WINAPI ITextSelection_fnMoveStart ( ITextSelection me,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 5128 of file richole.c.

5130{
5133 HRESULT hr;
5134
5135 TRACE("(%p)->(%d %d %p)\n", This, unit, count, delta);
5136
5137 if (!This->services)
5138 return CO_E_RELEASED;
5139
5140 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5141 hr = textrange_movestart(range, This->services->editor, unit, count, delta);
5142 ITextRange_Release(range);
5143 return hr;
5144}

◆ ITextSelection_fnMoveStartUntil()

static HRESULT WINAPI ITextSelection_fnMoveStartUntil ( ITextSelection me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 5216 of file richole.c.

5218{
5220
5221 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
5222
5223 if (!This->services)
5224 return CO_E_RELEASED;
5225
5226 return E_NOTIMPL;
5227}

◆ ITextSelection_fnMoveStartWhile()

static HRESULT WINAPI ITextSelection_fnMoveStartWhile ( ITextSelection me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 5177 of file richole.c.

5179{
5181
5182 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
5183
5184 if (!This->services)
5185 return CO_E_RELEASED;
5186
5187 return E_NOTIMPL;
5188}

◆ ITextSelection_fnMoveUntil()

static HRESULT WINAPI ITextSelection_fnMoveUntil ( ITextSelection me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 5203 of file richole.c.

5205{
5207
5208 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
5209
5210 if (!This->services)
5211 return CO_E_RELEASED;
5212
5213 return E_NOTIMPL;
5214}

◆ ITextSelection_fnMoveUp()

static HRESULT WINAPI ITextSelection_fnMoveUp ( ITextSelection me,
LONG  unit,
LONG  count,
LONG  extend,
LONG delta 
)
static

Definition at line 5490 of file richole.c.

5492{
5494
5495 FIXME("(%p)->(%d %d %d %p): stub\n", This, unit, count, extend, delta);
5496
5497 if (!This->services)
5498 return CO_E_RELEASED;
5499
5500 return E_NOTIMPL;
5501}

◆ ITextSelection_fnMoveWhile()

static HRESULT WINAPI ITextSelection_fnMoveWhile ( ITextSelection me,
VARIANT charset,
LONG  count,
LONG delta 
)
static

Definition at line 5164 of file richole.c.

5166{
5168
5169 FIXME("(%p)->(%s %d %p): stub\n", This, debugstr_variant(charset), count, delta);
5170
5171 if (!This->services)
5172 return CO_E_RELEASED;
5173
5174 return E_NOTIMPL;
5175}

◆ ITextSelection_fnPaste()

static HRESULT WINAPI ITextSelection_fnPaste ( ITextSelection me,
VARIANT v,
LONG  format 
)
static

Definition at line 5329 of file richole.c.

5330{
5332
5333 FIXME("(%p)->(%s %x): stub\n", This, debugstr_variant(v), format);
5334
5335 if (!This->services)
5336 return CO_E_RELEASED;
5337
5338 return E_NOTIMPL;
5339}

◆ ITextSelection_fnQueryInterface()

static HRESULT WINAPI ITextSelection_fnQueryInterface ( ITextSelection me,
REFIID  riid,
void **  ppvObj 
)
static

Definition at line 4521 of file richole.c.

4525{
4527
4528 *ppvObj = NULL;
4531 || IsEqualGUID(riid, &IID_ITextRange)
4532 || IsEqualGUID(riid, &IID_ITextSelection))
4533 {
4534 *ppvObj = me;
4535 ITextSelection_AddRef(me);
4536 return S_OK;
4537 }
4538 else if (IsEqualGUID(riid, &IID_Igetrichole))
4539 {
4540 *ppvObj = This->services;
4541 return S_OK;
4542 }
4543
4544 return E_NOINTERFACE;
4545}

◆ ITextSelection_fnRelease()

static ULONG WINAPI ITextSelection_fnRelease ( ITextSelection me)
static

Definition at line 4553 of file richole.c.

4554{
4557 if (ref == 0)
4558 heap_free(This);
4559 return ref;
4560}

◆ ITextSelection_fnScrollIntoView()

static HRESULT WINAPI ITextSelection_fnScrollIntoView ( ITextSelection me,
LONG  value 
)
static

Definition at line 5403 of file richole.c.

5404{
5406
5407 FIXME("(%p)->(%d): stub\n", This, value);
5408
5409 if (!This->services)
5410 return CO_E_RELEASED;
5411
5412 return E_NOTIMPL;
5413}

◆ ITextSelection_fnSelect()

static HRESULT WINAPI ITextSelection_fnSelect ( ITextSelection me)
static

Definition at line 5062 of file richole.c.

5063{
5065
5066 TRACE("(%p)\n", This);
5067
5068 if (!This->services)
5069 return CO_E_RELEASED;
5070
5071 /* nothing to do */
5072 return S_OK;
5073}

◆ ITextSelection_fnSetChar()

static HRESULT WINAPI ITextSelection_fnSetChar ( ITextSelection me,
LONG  ch 
)
static

Definition at line 4699 of file richole.c.

4700{
4702
4703 FIXME("(%p)->(%x): stub\n", This, ch);
4704
4705 if (!This->services)
4706 return CO_E_RELEASED;
4707
4708 return E_NOTIMPL;
4709}

◆ ITextSelection_fnSetEnd()

static HRESULT WINAPI ITextSelection_fnSetEnd ( ITextSelection me,
LONG  value 
)
static

Definition at line 4805 of file richole.c.

4806{
4808 LONG start, end;
4809 HRESULT hr;
4810
4811 TRACE("(%p)->(%d)\n", This, value);
4812
4813 if (!This->services)
4814 return CO_E_RELEASED;
4815
4816 ME_GetSelectionOfs(This->services->editor, &start, &end);
4817 hr = textrange_setend(This->services, value, &start, &end);
4818 if (hr == S_OK)
4819 set_selection(This->services->editor, start, end);
4820
4821 return hr;
4822}

◆ ITextSelection_fnSetFlags()

static HRESULT WINAPI ITextSelection_fnSetFlags ( ITextSelection me,
LONG  flags 
)
static

Definition at line 5440 of file richole.c.

5441{
5443
5444 FIXME("(%p)->(%x): stub\n", This, flags);
5445
5446 if (!This->services)
5447 return CO_E_RELEASED;
5448
5449 return E_NOTIMPL;
5450}

◆ ITextSelection_fnSetFont()

static HRESULT WINAPI ITextSelection_fnSetFont ( ITextSelection me,
ITextFont font 
)
static

Definition at line 4844 of file richole.c.

4845{
4848
4849 TRACE("(%p)->(%p)\n", This, font);
4850
4851 if (!font)
4852 return E_INVALIDARG;
4853
4854 if (!This->services)
4855 return CO_E_RELEASED;
4856
4857 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
4859 ITextRange_Release(range);
4860 return S_OK;
4861}

◆ ITextSelection_fnSetFormattedText()

static HRESULT WINAPI ITextSelection_fnSetFormattedText ( ITextSelection me,
ITextRange range 
)
static

Definition at line 4741 of file richole.c.

4742{
4744
4745 FIXME("(%p)->(%p): stub\n", This, range);
4746
4747 if (!This->services)
4748 return CO_E_RELEASED;
4749
4750 FIXME("not implemented\n");
4751 return E_NOTIMPL;
4752}

◆ ITextSelection_fnSetIndex()

static HRESULT WINAPI ITextSelection_fnSetIndex ( ITextSelection me,
LONG  unit,
LONG  index,
LONG  extend 
)
static

Definition at line 4971 of file richole.c.

4973{
4975
4976 FIXME("(%p)->(%d %d %d): stub\n", This, unit, index, extend);
4977
4978 if (!This->services)
4979 return CO_E_RELEASED;
4980
4981 return E_NOTIMPL;
4982}

◆ ITextSelection_fnSetPara()

static HRESULT WINAPI ITextSelection_fnSetPara ( ITextSelection me,
ITextPara para 
)
static

Definition at line 4883 of file richole.c.

4884{
4886
4887 FIXME("(%p)->(%p): stub\n", This, para);
4888
4889 if (!This->services)
4890 return CO_E_RELEASED;
4891
4892 FIXME("not implemented\n");
4893 return E_NOTIMPL;
4894}

◆ ITextSelection_fnSetPoint()

static HRESULT WINAPI ITextSelection_fnSetPoint ( ITextSelection me,
LONG  x,
LONG  y,
LONG  type,
LONG  extend 
)
static

Definition at line 5390 of file richole.c.

5392{
5394
5395 FIXME("(%p)->(%d %d %d %d): stub\n", This, x, y, type, extend);
5396
5397 if (!This->services)
5398 return CO_E_RELEASED;
5399
5400 return E_NOTIMPL;
5401}

◆ ITextSelection_fnSetRange()

static HRESULT WINAPI ITextSelection_fnSetRange ( ITextSelection me,
LONG  anchor,
LONG  active 
)
static

Definition at line 4984 of file richole.c.

4985{
4987
4988 FIXME("(%p)->(%d %d): stub\n", This, anchor, active);
4989
4990 if (!This->services)
4991 return CO_E_RELEASED;
4992
4993 return E_NOTIMPL;
4994}

◆ ITextSelection_fnSetStart()

static HRESULT WINAPI ITextSelection_fnSetStart ( ITextSelection me,
LONG  value 
)
static

Definition at line 4770 of file richole.c.

4771{
4773 LONG start, end;
4774 HRESULT hr;
4775
4776 TRACE("(%p)->(%d)\n", This, value);
4777
4778 if (!This->services)
4779 return CO_E_RELEASED;
4780
4781 ME_GetSelectionOfs(This->services->editor, &start, &end);
4782 hr = textrange_setstart(This->services, value, &start, &end);
4783 if (hr == S_OK)
4784 set_selection(This->services->editor, start, end);
4785
4786 return hr;
4787}

◆ ITextSelection_fnSetText()

static HRESULT WINAPI ITextSelection_fnSetText ( ITextSelection me,
BSTR  str 
)
static

Definition at line 4660 of file richole.c.

4661{
4663 ME_TextEditor *editor;
4664 int len, to, from;
4665
4666 TRACE("(%p)->(%s)\n", This, debugstr_w(str));
4667
4668 if (!This->services)
4669 return CO_E_RELEASED;
4670
4671 editor = This->services->editor;
4672 len = lstrlenW(str);
4673 ME_GetSelectionOfs(editor, &from, &to);
4674 ME_ReplaceSel(editor, FALSE, str, len);
4675
4676 if (len < to - from)
4678
4679 return S_OK;
4680}
void ME_ReplaceSel(ME_TextEditor *editor, BOOL can_undo, const WCHAR *str, int len)
Definition: editor.c:3161

◆ ITextSelection_fnStartOf()

static HRESULT WINAPI ITextSelection_fnStartOf ( ITextSelection me,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 5075 of file richole.c.

5077{
5080 HRESULT hr;
5081
5082 TRACE("(%p)->(%d %d %p)\n", This, unit, extend, delta);
5083
5084 if (!This->services)
5085 return CO_E_RELEASED;
5086
5087 ITextSelection_QueryInterface(me, &IID_ITextRange, (void**)&range);
5088 hr = textrange_startof(range, unit, extend, delta);
5089 ITextRange_Release(range);
5090 return hr;
5091}

◆ ITextSelection_fnTypeText()

static HRESULT WINAPI ITextSelection_fnTypeText ( ITextSelection me,
BSTR  text 
)
static

Definition at line 5542 of file richole.c.

5543{
5545
5546 FIXME("(%p)->(%s): stub\n", This, debugstr_w(text));
5547
5548 if (!This->services)
5549 return CO_E_RELEASED;
5550
5551 return E_NOTIMPL;
5552}

◆ load_typelib()

static HRESULT load_typelib ( void  )
static

Definition at line 78 of file richole.c.

79{
80 ITypeLib *tl;
81 HRESULT hr;
82
83 hr = LoadRegTypeLib(&LIBID_tom, 1, 0, LOCALE_SYSTEM_DEFAULT, &tl);
84 if (FAILED(hr)) {
85 ERR("LoadRegTypeLib failed: %08x\n", hr);
86 return hr;
87 }
88
90 ITypeLib_Release(tl);
91 return hr;
92}
HRESULT WINAPI LoadRegTypeLib(REFGUID rguid, WORD wVerMajor, WORD wVerMinor, LCID lcid, ITypeLib **ppTLib)
Definition: typelib.c:531
#define LOCALE_SYSTEM_DEFAULT

Referenced by get_typeinfo().

◆ ME_CopyReObject()

void ME_CopyReObject ( REOBJECT dst,
const REOBJECT src,
DWORD  flags 
)

Definition at line 5829 of file richole.c.

5830{
5831 *dst = *src;
5832 dst->poleobj = NULL;
5833 dst->pstg = NULL;
5834 dst->polesite = NULL;
5835
5836 if ((flags & REO_GETOBJ_POLEOBJ) && src->poleobj)
5837 {
5838 dst->poleobj = src->poleobj;
5839 IOleObject_AddRef(dst->poleobj);
5840 }
5841 if ((flags & REO_GETOBJ_PSTG) && src->pstg)
5842 {
5843 dst->pstg = src->pstg;
5844 IStorage_AddRef(dst->pstg);
5845 }
5846 if ((flags & REO_GETOBJ_POLESITE) && src->polesite)
5847 {
5848 dst->polesite = src->polesite;
5849 IOleClientSite_AddRef(dst->polesite);
5850 }
5851}
GLenum GLenum dst
Definition: glext.h:6340

Referenced by create_re_object(), and IRichEditOle_fnGetObject().

◆ ME_DeleteReObject()

void ME_DeleteReObject ( struct re_object reobj)

Definition at line 5821 of file richole.c.

5822{
5823 if (reobj->obj.poleobj) IOleObject_Release(reobj->obj.poleobj);
5824 if (reobj->obj.pstg) IStorage_Release(reobj->obj.pstg);
5825 if (reobj->obj.polesite) IOleClientSite_Release(reobj->obj.polesite);
5826 heap_free(reobj);
5827}
LPSTORAGE pstg
Definition: richole.idl:62
LPOLEOBJECT poleobj
Definition: richole.idl:61
LPOLECLIENTSITE polesite
Definition: richole.idl:63

Referenced by ME_DestroyDisplayItem().

◆ ME_GetOLEObjectSize()

void ME_GetOLEObjectSize ( const ME_Context c,
ME_Run run,
SIZE pSize 
)

Definition at line 5649 of file richole.c.

5650{
5651 IDataObject* ido;
5652 FORMATETC fmt;
5653 STGMEDIUM stgm;
5654 DIBSECTION dibsect;
5655 ENHMETAHEADER emh;
5656
5657 assert(run->nFlags & MERF_GRAPHICS);
5658 assert(run->reobj);
5659
5660 if (run->reobj->obj.sizel.cx != 0 || run->reobj->obj.sizel.cy != 0)
5661 {
5662 convert_sizel(c, &run->reobj->obj.sizel, pSize);
5663 if (c->editor->nZoomNumerator != 0)
5664 {
5665 pSize->cx = MulDiv(pSize->cx, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5666 pSize->cy = MulDiv(pSize->cy, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5667 }
5668 return;
5669 }
5670
5671 if (!run->reobj->obj.poleobj)
5672 {
5673 pSize->cx = pSize->cy = 0;
5674 return;
5675 }
5676
5677 if (IOleObject_QueryInterface(run->reobj->obj.poleobj, &IID_IDataObject, (void**)&ido) != S_OK)
5678 {
5679 FIXME("Query Interface IID_IDataObject failed!\n");
5680 pSize->cx = pSize->cy = 0;
5681 return;
5682 }
5683 fmt.cfFormat = CF_BITMAP;
5684 fmt.ptd = NULL;
5685 fmt.dwAspect = DVASPECT_CONTENT;
5686 fmt.lindex = -1;
5687 fmt.tymed = TYMED_GDI;
5688 if (IDataObject_GetData(ido, &fmt, &stgm) != S_OK)
5689 {
5690 fmt.cfFormat = CF_ENHMETAFILE;
5691 fmt.tymed = TYMED_ENHMF;
5692 if (IDataObject_GetData(ido, &fmt, &stgm) != S_OK)
5693 {
5694 FIXME("unsupported format\n");
5695 pSize->cx = pSize->cy = 0;
5696 IDataObject_Release(ido);
5697 return;
5698 }
5699 }
5700 IDataObject_Release(ido);
5701
5702 switch (stgm.tymed)
5703 {
5704 case TYMED_GDI:
5705 GetObjectW(stgm.u.hBitmap, sizeof(dibsect), &dibsect);
5706 pSize->cx = dibsect.dsBm.bmWidth;
5707 pSize->cy = dibsect.dsBm.bmHeight;
5708 break;
5709 case TYMED_ENHMF:
5710 GetEnhMetaFileHeader(stgm.u.hEnhMetaFile, sizeof(emh), &emh);
5711 pSize->cx = emh.rclBounds.right - emh.rclBounds.left;
5712 pSize->cy = emh.rclBounds.bottom - emh.rclBounds.top;
5713 break;
5714 default:
5715 FIXME("Unsupported tymed %d\n", stgm.tymed);
5716 break;
5717 }
5718 ReleaseStgMedium(&stgm);
5719 if (c->editor->nZoomNumerator != 0)
5720 {
5721 pSize->cx = MulDiv(pSize->cx, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5722 pSize->cy = MulDiv(pSize->cy, c->editor->nZoomNumerator, c->editor->nZoomDenominator);
5723 }
5724}

Referenced by ME_CharFromPointContext(), ME_GetRunSizeCommon(), and ME_PointFromCharContext().

◆ points_to_twips()

static FLOAT points_to_twips ( FLOAT  value)
inlinestatic

Definition at line 405 of file richole.c.

406{
407 return value * 1440 / 72.0;
408}

Referenced by textrange_set_font().

◆ range_Collapse()

static HRESULT range_Collapse ( LONG  bStart,
LONG start,
LONG end 
)
static

Definition at line 1877 of file richole.c.

1878{
1879 if (*end == *start)
1880 return S_FALSE;
1881
1882 if (bStart == tomEnd)
1883 *start = *end;
1884 else
1885 *end = *start;
1886 return S_OK;
1887}

Referenced by ITextRange_fnCollapse(), and ITextSelection_fnCollapse().

◆ range_GetChar()

static HRESULT range_GetChar ( ME_TextEditor editor,
ME_Cursor cursor,
LONG pch 
)
static

Definition at line 1616 of file richole.c.

1617{
1618 WCHAR wch[2];
1619
1620 ME_GetTextW(editor, wch, 1, cursor, 1, FALSE, !para_next( para_next( cursor->para ) ));
1621 *pch = wch[0];
1622
1623 return S_OK;
1624}
__wchar_t WCHAR
Definition: xmlstorage.h:180

Referenced by ITextRange_fnGetChar(), and ITextSelection_fnGetChar().

◆ release_typelib()

void release_typelib ( void  )

Definition at line 94 of file richole.c.

95{
96 unsigned i;
97
98 if (!typelib)
99 return;
100
101 for (i = 0; i < ARRAY_SIZE(typeinfos); i++)
102 if (typeinfos[i])
103 ITypeInfo_Release(typeinfos[i]);
104
105 ITypeLib_Release(typelib);
106}
#define ARRAY_SIZE(A)
Definition: main.h:20

◆ richole_release_children()

void richole_release_children ( struct text_services services)

Definition at line 5853 of file richole.c.

5854{
5857
5858 if (services->text_selection)
5859 {
5860 services->text_selection->services = NULL;
5861 ITextSelection_Release( &services->text_selection->ITextSelection_iface );
5862 }
5863
5864 LIST_FOR_EACH_ENTRY( range, &services->rangelist, ITextRangeImpl, child.entry )
5865 range->child.reole = NULL;
5866
5868 site->child.reole = NULL;
5869}
static IActiveScriptSite * site
Definition: script.c:149
static HWND child
Definition: cursoricon.c:298
IWbemServices * services
Definition: locator.c:1514

Referenced by ITextServicesImpl_Release().

◆ set_textfont_prop()

static HRESULT set_textfont_prop ( ITextFontImpl font,
enum textfont_prop_id  propid,
const textfont_prop_val value 
)
static

Definition at line 721 of file richole.c.

722{
723 const struct text_services *services;
724 ME_Cursor from, to;
726 LONG start, end;
727
728 /* when font is not attached to any range use cache */
729 if (!font->range || font->set_cache_enabled) {
730 if (propid == FONT_NAME) {
731 SysFreeString(font->props[propid].str);
732 font->props[propid].str = SysAllocString(value->str);
733 }
734 else
735 font->props[propid] = *value;
736 return S_OK;
737 }
738
739 if (!(services = get_range_reole(font->range)))
740 return CO_E_RELEASED;
741
742 memset(&fmt, 0, sizeof(fmt));
743 fmt.cbSize = sizeof(fmt);
744 fmt.dwMask = textfont_prop_masks[propid][0];
745
746 switch (propid)
747 {
748 case FONT_ALLCAPS:
749 case FONT_BOLD:
750 case FONT_EMBOSS:
751 case FONT_HIDDEN:
752 case FONT_ENGRAVE:
753 case FONT_ITALIC:
754 case FONT_OUTLINE:
755 case FONT_PROTECTED:
756 case FONT_SHADOW:
757 case FONT_SMALLCAPS:
759 case FONT_SUBSCRIPT:
760 case FONT_SUPERSCRIPT:
761 case FONT_UNDERLINE:
762 fmt.dwEffects = value->l == tomTrue ? textfont_prop_masks[propid][1] : 0;
763 break;
764 case FONT_ANIMATION:
765 fmt.bAnimation = value->l;
766 break;
767 case FONT_BACKCOLOR:
768 case FONT_FORECOLOR:
769 if (value->l == tomAutoColor)
770 fmt.dwEffects = textfont_prop_masks[propid][1];
771 else if (propid == FONT_BACKCOLOR)
772 fmt.crBackColor = value->l;
773 else
774 fmt.crTextColor = value->l;
775 break;
776 case FONT_KERNING:
777 fmt.wKerning = value->f;
778 break;
779 case FONT_LANGID:
780 fmt.lcid = value->l;
781 break;
782 case FONT_POSITION:
783 fmt.yOffset = value->f;
784 break;
785 case FONT_SIZE:
786 fmt.yHeight = value->f;
787 break;
788 case FONT_SPACING:
789 fmt.sSpacing = value->f;
790 break;
791 case FONT_WEIGHT:
792 fmt.wWeight = value->l;
793 break;
794 case FONT_NAME:
795 lstrcpynW(fmt.szFaceName, value->str, ARRAY_SIZE(fmt.szFaceName));
796 break;
797 default:
798 FIXME("unhandled font property %d\n", propid);
799 return E_FAIL;
800 }
801
802 ITextRange_GetStart(font->range, &start);
803 ITextRange_GetEnd(font->range, &end);
804
806 cursor_from_char_ofs( services->editor, end, &to );
807 ME_SetCharFormat( services->editor, &from, &to, &fmt );
808
809 return S_OK;
810}
#define lstrcpynW
Definition: compat.h:738
void ME_SetCharFormat(ME_TextEditor *editor, ME_Cursor *start, ME_Cursor *end, CHARFORMAT2W *pFmt) DECLSPEC_HIDDEN
Definition: run.c:777
void WINAPI DECLSPEC_HOTPATCH SysFreeString(BSTR str)
Definition: oleaut.c:271
@ tomAutoColor
Definition: tom.idl:32

Referenced by set_textfont_propd(), set_textfont_propf(), set_textfont_propl(), textfont_apply_range_props(), and TextFont_SetName().

◆ set_textfont_propd()

static HRESULT set_textfont_propd ( ITextFontImpl font,
enum textfont_prop_id  propid,
LONG  value 
)
static

Definition at line 826 of file richole.c.

827{
829
830 switch (value)
831 {
832 case tomUndefined:
833 return S_OK;
834 case tomToggle: {
835 LONG oldvalue;
836 get_textfont_propl(font, propid, &oldvalue);
837 if (oldvalue == tomFalse)
838 value = tomTrue;
839 else if (oldvalue == tomTrue)
840 value = tomFalse;
841 else
842 return E_INVALIDARG;
843 /* fallthrough */
844 }
845 case tomTrue:
846 case tomFalse:
847 v.l = value;
848 return set_textfont_prop(font, propid, &v);
849 default:
850 return E_INVALIDARG;
851 }
852}
static HRESULT get_textfont_propl(const ITextFontImpl *font, enum textfont_prop_id propid, LONG *value)
Definition: richole.c:707
static HRESULT set_textfont_prop(ITextFontImpl *font, enum textfont_prop_id propid, const textfont_prop_val *value)
Definition: richole.c:721
@ tomToggle
Definition: tom.idl:31

Referenced by TextFont_SetAllCaps(), TextFont_SetBold(), TextFont_SetEmboss(), TextFont_SetEngrave(), TextFont_SetHidden(), TextFont_SetItalic(), TextFont_SetOutline(), TextFont_SetProtected(), TextFont_SetShadow(), TextFont_SetSmallCaps(), TextFont_SetStrikeThrough(), TextFont_SetSubscript(), TextFont_SetSuperscript(), and TextFont_SetUnderline().

◆ set_textfont_propf()

static HRESULT set_textfont_propf ( ITextFontImpl font,
enum textfont_prop_id  propid,
FLOAT  value 
)
inlinestatic

Definition at line 819 of file richole.c.

820{
822 v.f = value;
823 return set_textfont_prop(font, propid, &v);
824}

Referenced by TextFont_SetKerning(), TextFont_SetPosition(), TextFont_SetSize(), and TextFont_SetSpacing().

◆ set_textfont_propl()

static HRESULT set_textfont_propl ( ITextFontImpl font,
enum textfont_prop_id  propid,
LONG  value 
)
inlinestatic

◆ text_selection_create()

static struct text_selection * text_selection_create ( struct text_services services)
static

Definition at line 5625 of file richole.c.

5626{
5627 struct text_selection *txtSel = heap_alloc(sizeof *txtSel);
5628 if (!txtSel)
5629 return NULL;
5630
5631 txtSel->ITextSelection_iface.lpVtbl = &tsvt;
5632 txtSel->ref = 1;
5633 txtSel->services = services;
5634 return txtSel;
5635}
static const ITextSelectionVtbl tsvt
Definition: richole.c:5554
ITextSelection ITextSelection_iface
Definition: editstr.h:470
struct text_services * services
Definition: editstr.h:473

Referenced by ITextDocument2Old_fnGetSelection().

◆ TextFont_AddRef()

static ULONG WINAPI TextFont_AddRef ( ITextFont iface)
static

Definition at line 2747 of file richole.c.

2748{
2751 TRACE("(%p)->(%u)\n", This, ref);
2752 return ref;
2753}
static ITextFontImpl * impl_from_ITextFont(ITextFont *iface)
Definition: richole.c:269

◆ textfont_apply_range_props()

static void textfont_apply_range_props ( ITextFontImpl font)
static

Definition at line 2965 of file richole.c.

2966{
2967 enum textfont_prop_id propid;
2968 for (propid = FONT_PROPID_FIRST; propid < FONT_PROPID_LAST; propid++)
2969 set_textfont_prop(font, propid, &font->props[propid]);
2970}
textfont_prop_id
Definition: richole.c:142

Referenced by TextFont_Reset().

◆ textfont_cache_range_props()

static void textfont_cache_range_props ( ITextFontImpl font)
static

Definition at line 870 of file richole.c.

871{
872 enum textfont_prop_id propid;
873 for (propid = FONT_PROPID_FIRST; propid < FONT_PROPID_LAST; propid++) {
874 if (propid == FONT_NAME)
875 textfont_getname_from_range(font->range, &font->props[propid].str);
876 else
877 get_textfont_prop(font, propid, &font->props[propid]);
878 }
879}
static HRESULT textfont_getname_from_range(ITextRange *range, BSTR *ret)
Definition: richole.c:854

Referenced by create_textfont(), and TextFont_Reset().

◆ TextFont_CanChange()

static HRESULT WINAPI TextFont_CanChange ( ITextFont iface,
LONG ret 
)
static

Definition at line 2858 of file richole.c.

2859{
2861 FIXME("(%p)->(%p): stub\n", This, ret);
2862 return E_NOTIMPL;
2863}

◆ TextFont_GetAllCaps()

static HRESULT WINAPI TextFont_GetAllCaps ( ITextFont iface,
LONG value 
)
static

Definition at line 3051 of file richole.c.

3052{
3054 TRACE("(%p)->(%p)\n", This, value);
3056}

◆ TextFont_GetAnimation()

static HRESULT WINAPI TextFont_GetAnimation ( ITextFont iface,
LONG value 
)
static

Definition at line 3065 of file richole.c.

3066{
3068 TRACE("(%p)->(%p)\n", This, value);
3070}

◆ TextFont_GetBackColor()

static HRESULT WINAPI TextFont_GetBackColor ( ITextFont iface,
LONG value 
)
static

Definition at line 3084 of file richole.c.

3085{
3087 TRACE("(%p)->(%p)\n", This, value);
3089}

◆ TextFont_GetBold()

static HRESULT WINAPI TextFont_GetBold ( ITextFont iface,
LONG value 
)
static

Definition at line 3098 of file richole.c.

3099{
3101 TRACE("(%p)->(%p)\n", This, value);
3103}

◆ TextFont_GetDuplicate()

static HRESULT WINAPI TextFont_GetDuplicate ( ITextFont iface,
ITextFont **  ret 
)
static

Definition at line 2835 of file richole.c.

2836{
2838
2839 TRACE("(%p)->(%p)\n", This, ret);
2840
2841 if (!ret)
2842 return E_INVALIDARG;
2843
2844 *ret = NULL;
2845 if (This->range && !get_range_reole(This->range))
2846 return CO_E_RELEASED;
2847
2848 return create_textfont(NULL, This, ret);
2849}

◆ TextFont_GetEmboss()

static HRESULT WINAPI TextFont_GetEmboss ( ITextFont iface,
LONG value 
)
static

Definition at line 3112 of file richole.c.

3113{
3115 TRACE("(%p)->(%p)\n", This, value);
3117}

◆ TextFont_GetEngrave()

static HRESULT WINAPI TextFont_GetEngrave ( ITextFont iface,
LONG value 
)
static

Definition at line 3154 of file richole.c.

3155{
3157 TRACE("(%p)->(%p)\n", This, value);
3159}

◆ TextFont_GetForeColor()

static HRESULT WINAPI TextFont_GetForeColor ( ITextFont iface,
LONG value 
)
static

Definition at line 3126 of file richole.c.

3127{
3129 TRACE("(%p)->(%p)\n", This, value);
3131}

◆ TextFont_GetHidden()

static HRESULT WINAPI TextFont_GetHidden ( ITextFont iface,
LONG value 
)
static

Definition at line 3140 of file richole.c.

3141{
3143 TRACE("(%p)->(%p)\n", This, value);
3145}

◆ TextFont_GetIDsOfNames()

static HRESULT WINAPI TextFont_GetIDsOfNames ( ITextFont iface,
REFIID  riid,
LPOLESTR rgszNames,
UINT  cNames,
LCID  lcid,
DISPID rgDispId 
)
static

Definition at line 2795 of file richole.c.

2797{
2799 ITypeInfo *ti;
2800 HRESULT hr;
2801
2802 TRACE("(%p)->(%s, %p, %u, %d, %p)\n", This, debugstr_guid(riid),
2803 rgszNames, cNames, lcid, rgDispId);
2804
2806 if (SUCCEEDED(hr))
2807 hr = ITypeInfo_GetIDsOfNames(ti, rgszNames, cNames, rgDispId);
2808 return hr;
2809}

◆ TextFont_GetItalic()

static HRESULT WINAPI TextFont_GetItalic ( ITextFont iface,
LONG value 
)
static

Definition at line 3168 of file richole.c.

3169{
3171 TRACE("(%p)->(%p)\n", This, value);
3173}

◆ TextFont_GetKerning()

static HRESULT WINAPI TextFont_GetKerning ( ITextFont iface,
FLOAT value 
)
static

Definition at line 3182 of file richole.c.

3183{
3185 TRACE("(%p)->(%p)\n", This, value);
3187}
static HRESULT get_textfont_propf(const ITextFontImpl *font, enum textfont_prop_id propid, FLOAT *value)
Definition: richole.c:694

◆ TextFont_GetLanguageID()

static HRESULT WINAPI TextFont_GetLanguageID ( ITextFont iface,
LONG value 
)
static

Definition at line 3196 of file richole.c.

3197{
3199 TRACE("(%p)->(%p)\n", This, value);
3201}

◆ TextFont_GetName()

static HRESULT WINAPI TextFont_GetName ( ITextFont iface,
BSTR value 
)
static

Definition at line 3210 of file richole.c.

3211{
3213
3214 TRACE("(%p)->(%p)\n", This, value);
3215
3216 if (!value)
3217 return E_INVALIDARG;
3218
3219 *value = NULL;
3220
3221 if (!This->range) {
3222 if (This->props[FONT_NAME].str)
3223 *value = SysAllocString(This->props[FONT_NAME].str);
3224 else
3226 return *value ? S_OK : E_OUTOFMEMORY;
3227 }
3228
3229 return textfont_getname_from_range(This->range, value);
3230}

◆ textfont_getname_from_range()

static HRESULT textfont_getname_from_range ( ITextRange range,
BSTR ret 
)
static

Definition at line 854 of file richole.c.

855{
856 const struct text_services *services;
858 HRESULT hr;
859 LONG start;
860
861 if (!(services = get_range_reole( range )))
862 return CO_E_RELEASED;
863
864 ITextRange_GetStart(range, &start);
866 *ret = v.str;
867 return hr;
868}

Referenced by textfont_cache_range_props(), and TextFont_GetName().

◆ TextFont_GetOutline()

static HRESULT WINAPI TextFont_GetOutline ( ITextFont iface,
LONG value 
)
static

Definition at line 3243 of file richole.c.

3244{
3246 TRACE("(%p)->(%p)\n", This, value);
3248}

◆ TextFont_GetPosition()

static HRESULT WINAPI TextFont_GetPosition ( ITextFont iface,
FLOAT value 
)
static

Definition at line 3257 of file richole.c.

3258{
3260 TRACE("(%p)->(%p)\n", This, value);
3262}

◆ TextFont_GetProtected()

static HRESULT WINAPI TextFont_GetProtected ( ITextFont iface,
LONG value 
)
static

Definition at line 3271 of file richole.c.

3272{
3274 TRACE("(%p)->(%p)\n", This, value);
3276}

◆ TextFont_GetShadow()

static HRESULT WINAPI TextFont_GetShadow ( ITextFont iface,
LONG value 
)
static

Definition at line 3285 of file richole.c.

3286{
3288 TRACE("(%p)->(%p)\n", This, value);
3290}

◆ TextFont_GetSize()

static HRESULT WINAPI TextFont_GetSize ( ITextFont iface,
FLOAT value 
)
static

Definition at line 3299 of file richole.c.

3300{
3302 TRACE("(%p)->(%p)\n", This, value);
3304}

◆ TextFont_GetSmallCaps()

static HRESULT WINAPI TextFont_GetSmallCaps ( ITextFont iface,
LONG value 
)
static

Definition at line 3313 of file richole.c.

3314{
3316 TRACE("(%p)->(%p)\n", This, value);
3318}

◆ TextFont_GetSpacing()

static HRESULT WINAPI TextFont_GetSpacing ( ITextFont iface,
FLOAT value 
)
static

Definition at line 3327 of file richole.c.

3328{
3330 TRACE("(%p)->(%p)\n", This, value);
3332}

◆ TextFont_GetStrikeThrough()

static HRESULT WINAPI TextFont_GetStrikeThrough ( ITextFont iface,
LONG value 
)
static

Definition at line 3341 of file richole.c.

3342{
3344 TRACE("(%p)->(%p)\n", This, value);
3346}

◆ TextFont_GetStyle()

static HRESULT WINAPI TextFont_GetStyle ( ITextFont iface,
LONG value 
)
static

Definition at line 3037 of file richole.c.

3038{
3040 FIXME("(%p)->(%p): stub\n", This, value);
3041 return E_NOTIMPL;
3042}

◆ TextFont_GetSubscript()

static HRESULT WINAPI TextFont_GetSubscript ( ITextFont iface,
LONG value 
)
static

Definition at line 3355 of file richole.c.

3356{
3358 TRACE("(%p)->(%p)\n", This, value);
3360}

◆ TextFont_GetSuperscript()

static HRESULT WINAPI TextFont_GetSuperscript ( ITextFont iface,
LONG value 
)
static

Definition at line 3369 of file richole.c.

3370{
3372 TRACE("(%p)->(%p)\n", This, value);
3374}

◆ TextFont_GetTypeInfo()

static HRESULT WINAPI TextFont_GetTypeInfo ( ITextFont iface,
UINT  iTInfo,
LCID  lcid,
ITypeInfo **  ppTInfo 
)
static

Definition at line 2781 of file richole.c.

2783{
2785 HRESULT hr;
2786
2787 TRACE("(%p)->(%u,%d,%p)\n", This, iTInfo, lcid, ppTInfo);
2788
2789 hr = get_typeinfo(ITextFont_tid, ppTInfo);
2790 if (SUCCEEDED(hr))
2791 ITypeInfo_AddRef(*ppTInfo);
2792 return hr;
2793}

◆ TextFont_GetTypeInfoCount()

static HRESULT WINAPI TextFont_GetTypeInfoCount ( ITextFont iface,
UINT pctinfo 
)
static

Definition at line 2773 of file richole.c.

2774{
2776 TRACE("(%p)->(%p)\n", This, pctinfo);
2777 *pctinfo = 1;
2778 return S_OK;
2779}

◆ TextFont_GetUnderline()

static HRESULT WINAPI TextFont_GetUnderline ( ITextFont iface,
LONG value 
)
static

Definition at line 3383 of file richole.c.

3384{
3386 TRACE("(%p)->(%p)\n", This, value);
3388}

◆ TextFont_GetWeight()

static HRESULT WINAPI TextFont_GetWeight ( ITextFont iface,
LONG value 
)
static

Definition at line 3397 of file richole.c.

3398{
3400 TRACE("(%p)->(%p)\n", This, value);
3402}

◆ TextFont_Invoke()

static HRESULT WINAPI TextFont_Invoke ( ITextFont iface,
DISPID  dispIdMember,
REFIID  riid,
LCID  lcid,
WORD  wFlags,
DISPPARAMS *  pDispParams,
VARIANT pVarResult,
EXCEPINFO *  pExcepInfo,
UINT puArgErr 
)
static

Definition at line 2811 of file richole.c.

2821{
2823 ITypeInfo *ti;
2824 HRESULT hr;
2825
2826 TRACE("(%p)->(%d, %s, %d, %u, %p, %p, %p, %p)\n", This, dispIdMember, debugstr_guid(riid),
2827 lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
2828
2830 if (SUCCEEDED(hr))
2831 hr = ITypeInfo_Invoke(ti, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
2832 return hr;
2833}

◆ TextFont_IsEqual()

static HRESULT WINAPI TextFont_IsEqual ( ITextFont iface,
ITextFont font,
LONG ret 
)
static

Definition at line 2865 of file richole.c.

2866{
2868 FIXME("(%p)->(%p %p): stub\n", This, font, ret);
2869 return E_NOTIMPL;
2870}

◆ TextFont_QueryInterface()

static HRESULT WINAPI TextFont_QueryInterface ( ITextFont iface,
REFIID  riid,
void **  ppv 
)
static

Definition at line 2728 of file richole.c.

2729{
2731
2732 TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv);
2733
2734 if (IsEqualIID(riid, &IID_ITextFont) ||
2737 {
2738 *ppv = iface;
2739 ITextFont_AddRef(iface);
2740 return S_OK;
2741 }
2742
2743 *ppv = NULL;
2744 return E_NOINTERFACE;
2745}
#define IsEqualIID(riid1, riid2)
Definition: guiddef.h:95

◆ TextFont_Release()

static ULONG WINAPI TextFont_Release ( ITextFont iface)
static

Definition at line 2755 of file richole.c.

2756{
2759
2760 TRACE("(%p)->(%u)\n", This, ref);
2761
2762 if (!ref)
2763 {
2764 if (This->range)
2765 ITextRange_Release(This->range);
2766 SysFreeString(This->props[FONT_NAME].str);
2767 heap_free(This);
2768 }
2769
2770 return ref;
2771}

◆ TextFont_Reset()

static HRESULT WINAPI TextFont_Reset ( ITextFont iface,
LONG  value 
)
static

Definition at line 2972 of file richole.c.

2973{
2975
2976 TRACE("(%p)->(%d)\n", This, value);
2977
2978 /* If font is attached to a range, released or not, we can't
2979 reset to undefined */
2980 if (This->range) {
2981 if (!get_range_reole(This->range))
2982 return CO_E_RELEASED;
2983
2984 switch (value)
2985 {
2986 case tomUndefined:
2987 return E_INVALIDARG;
2988 case tomCacheParms:
2990 This->get_cache_enabled = TRUE;
2991 break;
2992 case tomTrackParms:
2993 This->get_cache_enabled = FALSE;
2994 break;
2995 case tomApplyLater:
2996 This->set_cache_enabled = TRUE;
2997 break;
2998 case tomApplyNow:
2999 This->set_cache_enabled = FALSE;
3001 break;
3002 case tomUsePoints:
3003 case tomUseTwips:
3004 return E_INVALIDARG;
3005 default:
3006 FIXME("reset mode %d not supported\n", value);
3007 }
3008
3009 return S_OK;
3010 }
3011 else {
3012 switch (value)
3013 {
3014 /* reset to global defaults */
3015 case tomDefault:
3017 return S_OK;
3018 /* all properties are set to tomUndefined, font name is retained */
3019 case tomUndefined:
3021 return S_OK;
3022 case tomApplyNow:
3023 case tomApplyLater:
3024 case tomTrackParms:
3025 case tomCacheParms:
3026 return S_OK;
3027 case tomUsePoints:
3028 case tomUseTwips:
3029 return E_INVALIDARG;
3030 }
3031 }
3032
3033 FIXME("reset mode %d not supported\n", value);
3034 return E_NOTIMPL;
3035}
static void textfont_reset_to_default(ITextFontImpl *font)
Definition: richole.c:2872
static void textfont_apply_range_props(ITextFontImpl *font)
Definition: richole.c:2965
static void textfont_reset_to_undefined(ITextFontImpl *font)
Definition: richole.c:2923
@ tomUseTwips
Definition: tom.idl:46
@ tomApplyNow
Definition: tom.idl:38
@ tomUsePoints
Definition: tom.idl:45
@ tomDefault
Definition: tom.idl:33
@ tomApplyLater
Definition: tom.idl:39
@ tomCacheParms
Definition: tom.idl:41
@ tomTrackParms
Definition: tom.idl:40

◆ textfont_reset_to_default()

static void textfont_reset_to_default ( ITextFontImpl font)
static

Definition at line 2872 of file richole.c.

2873{
2874 enum textfont_prop_id id;
2875
2876 for (id = FONT_PROPID_FIRST; id < FONT_PROPID_LAST; id++) {
2877 switch (id)
2878 {
2879 case FONT_ALLCAPS:
2880 case FONT_ANIMATION:
2881 case FONT_BOLD:
2882 case FONT_EMBOSS:
2883 case FONT_HIDDEN:
2884 case FONT_ENGRAVE:
2885 case FONT_ITALIC:
2886 case FONT_OUTLINE:
2887 case FONT_PROTECTED:
2888 case FONT_SHADOW:
2889 case FONT_SMALLCAPS:
2890 case FONT_STRIKETHROUGH:
2891 case FONT_SUBSCRIPT:
2892 case FONT_SUPERSCRIPT:
2893 case FONT_UNDERLINE:
2894 font->props[id].l = tomFalse;
2895 break;
2896 case FONT_BACKCOLOR:
2897 case FONT_FORECOLOR:
2898 font->props[id].l = tomAutoColor;
2899 break;
2900 case FONT_KERNING:
2901 case FONT_POSITION:
2902 case FONT_SIZE:
2903 case FONT_SPACING:
2904 font->props[id].f = 0.0;
2905 break;
2906 case FONT_LANGID:
2907 font->props[id].l = GetSystemDefaultLCID();
2908 break;
2909 case FONT_NAME: {
2910 SysFreeString(font->props[id].str);
2911 font->props[id].str = SysAllocString(L"System");
2912 break;
2913 }
2914 case FONT_WEIGHT:
2915 font->props[id].l = FW_NORMAL;
2916 break;
2917 default:
2918 FIXME("font property %d not handled\n", id);
2919 }
2920 }
2921}
LCID WINAPI GetSystemDefaultLCID(void)
Definition: locale.c:1230
GLuint id
Definition: glext.h:5910
#define L(x)
Definition: ntvdm.h:50
#define FW_NORMAL
Definition: wingdi.h:373

Referenced by TextFont_Reset().

◆ textfont_reset_to_undefined()

static void textfont_reset_to_undefined ( ITextFontImpl font)
static

Definition at line 2923 of file richole.c.

2924{
2925 enum textfont_prop_id id;
2926
2927 for (id = FONT_PROPID_FIRST; id < FONT_PROPID_LAST; id++) {
2928 switch (id)
2929 {
2930 case FONT_ALLCAPS:
2931 case FONT_ANIMATION:
2932 case FONT_BOLD:
2933 case FONT_EMBOSS:
2934 case FONT_HIDDEN:
2935 case FONT_ENGRAVE:
2936 case FONT_ITALIC:
2937 case FONT_OUTLINE:
2938 case FONT_PROTECTED:
2939 case FONT_SHADOW:
2940 case FONT_SMALLCAPS:
2941 case FONT_STRIKETHROUGH:
2942 case FONT_SUBSCRIPT:
2943 case FONT_SUPERSCRIPT:
2944 case FONT_UNDERLINE:
2945 case FONT_BACKCOLOR:
2946 case FONT_FORECOLOR:
2947 case FONT_LANGID:
2948 case FONT_WEIGHT:
2949 font->props[id].l = tomUndefined;
2950 break;
2951 case FONT_KERNING:
2952 case FONT_POSITION:
2953 case FONT_SIZE:
2954 case FONT_SPACING:
2955 font->props[id].f = tomUndefined;
2956 break;
2957 case FONT_NAME:
2958 break;
2959 default:
2960 FIXME("font property %d not handled\n", id);
2961 }
2962 }
2963}

Referenced by TextFont_Reset().

◆ TextFont_SetAllCaps()

static HRESULT WINAPI TextFont_SetAllCaps ( ITextFont iface,
LONG  value 
)
static

Definition at line 3058 of file richole.c.

3059{
3061 TRACE("(%p)->(%d)\n", This, value);
3063}
static HRESULT set_textfont_propd(ITextFontImpl *font, enum textfont_prop_id propid, LONG value)
Definition: richole.c:826

◆ TextFont_SetAnimation()

static HRESULT WINAPI TextFont_SetAnimation ( ITextFont iface,
LONG  value 
)
static

Definition at line 3072 of file richole.c.

3073{
3075
3076 TRACE("(%p)->(%d)\n", This, value);
3077
3078 if (value < tomNoAnimation || value > tomAnimationMax)
3079 return E_INVALIDARG;
3080
3082}
static HRESULT set_textfont_propl(ITextFontImpl *font, enum textfont_prop_id propid, LONG value)
Definition: richole.c:812
@ tomAnimationMax
Definition: tom.idl:162

◆ TextFont_SetBackColor()

static HRESULT WINAPI TextFont_SetBackColor ( ITextFont iface,
LONG  value 
)
static

Definition at line 3091 of file richole.c.

3092{
3094 TRACE("(%p)->(%d)\n", This, value);
3096}

◆ TextFont_SetBold()

static HRESULT WINAPI TextFont_SetBold ( ITextFont iface,
LONG  value 
)
static

Definition at line 3105 of file richole.c.

3106{
3108 TRACE("(%p)->(%d)\n", This, value);
3110}

◆ TextFont_SetDuplicate()

static HRESULT WINAPI TextFont_SetDuplicate ( ITextFont iface,
ITextFont pFont 
)
static

Definition at line 2851 of file richole.c.

2852{
2854 FIXME("(%p)->(%p): stub\n", This, pFont);
2855 return E_NOTIMPL;
2856}

◆ TextFont_SetEmboss()

static HRESULT WINAPI TextFont_SetEmboss ( ITextFont iface,
LONG  value 
)
static

Definition at line 3119 of file richole.c.

3120{
3122 TRACE("(%p)->(%d)\n", This, value);
3124}

◆ TextFont_SetEngrave()

static HRESULT WINAPI TextFont_SetEngrave ( ITextFont iface,
LONG  value 
)
static

Definition at line 3161 of file richole.c.

3162{
3164 TRACE("(%p)->(%d)\n", This, value);
3166}

◆ TextFont_SetForeColor()

static HRESULT WINAPI TextFont_SetForeColor ( ITextFont iface,
LONG  value 
)
static

Definition at line 3133 of file richole.c.

3134{
3136 TRACE("(%p)->(%d)\n", This, value);
3138}

◆ TextFont_SetHidden()

static HRESULT WINAPI TextFont_SetHidden ( ITextFont iface,
LONG  value 
)
static

Definition at line 3147 of file richole.c.

3148{
3150 TRACE("(%p)->(%d)\n", This, value);
3152}

◆ TextFont_SetItalic()

static HRESULT WINAPI TextFont_SetItalic ( ITextFont iface,
LONG  value 
)
static

Definition at line 3175 of file richole.c.

3176{
3178 TRACE("(%p)->(%d)\n", This, value);
3180}

◆ TextFont_SetKerning()

static HRESULT WINAPI TextFont_SetKerning ( ITextFont iface,
FLOAT  value 
)
static

Definition at line 3189 of file richole.c.

3190{
3192 TRACE("(%p)->(%.2f)\n", This, value);
3194}
static HRESULT set_textfont_propf(ITextFontImpl *font, enum textfont_prop_id propid, FLOAT value)
Definition: richole.c:819

◆ TextFont_SetLanguageID()

static HRESULT WINAPI TextFont_SetLanguageID ( ITextFont iface,
LONG  value 
)
static

Definition at line 3203 of file richole.c.

3204{
3206 TRACE("(%p)->(%d)\n", This, value);
3208}

◆ TextFont_SetName()

static HRESULT WINAPI TextFont_SetName ( ITextFont iface,
BSTR  value 
)
static

Definition at line 3232 of file richole.c.

3233{
3236
3237 TRACE("(%p)->(%s)\n", This, debugstr_w(value));
3238
3239 v.str = value;
3240 return set_textfont_prop(This, FONT_NAME, &v);
3241}

◆ TextFont_SetOutline()

static HRESULT WINAPI TextFont_SetOutline ( ITextFont iface,
LONG  value 
)
static

Definition at line 3250 of file richole.c.

3251{
3253 TRACE("(%p)->(%d)\n", This, value);
3255}

◆ TextFont_SetPosition()

static HRESULT WINAPI TextFont_SetPosition ( ITextFont iface,
FLOAT  value 
)
static

Definition at line 3264 of file richole.c.

3265{
3267 TRACE("(%p)->(%.2f)\n", This, value);
3269}

◆ TextFont_SetProtected()

static HRESULT WINAPI TextFont_SetProtected ( ITextFont iface,
LONG  value 
)
static

Definition at line 3278 of file richole.c.

3279{
3281 TRACE("(%p)->(%d)\n", This, value);
3283}

◆ TextFont_SetShadow()

static HRESULT WINAPI TextFont_SetShadow ( ITextFont iface,
LONG  value 
)
static

Definition at line 3292 of file richole.c.

3293{
3295 TRACE("(%p)->(%d)\n", This, value);
3297}

◆ TextFont_SetSize()

static HRESULT WINAPI TextFont_SetSize ( ITextFont iface,
FLOAT  value 
)
static

Definition at line 3306 of file richole.c.

3307{
3309 TRACE("(%p)->(%.2f)\n", This, value);
3311}

◆ TextFont_SetSmallCaps()

static HRESULT WINAPI TextFont_SetSmallCaps ( ITextFont iface,
LONG  value 
)
static

Definition at line 3320 of file richole.c.

3321{
3323 TRACE("(%p)->(%d)\n", This, value);
3325}

◆ TextFont_SetSpacing()

static HRESULT WINAPI TextFont_SetSpacing ( ITextFont iface,
FLOAT  value 
)
static

Definition at line 3334 of file richole.c.

3335{
3337 TRACE("(%p)->(%.2f)\n", This, value);
3339}

◆ TextFont_SetStrikeThrough()

static HRESULT WINAPI TextFont_SetStrikeThrough ( ITextFont iface,
LONG  value 
)
static

Definition at line 3348 of file richole.c.

3349{
3351 TRACE("(%p)->(%d)\n", This, value);
3353}

◆ TextFont_SetStyle()

static HRESULT WINAPI TextFont_SetStyle ( ITextFont iface,
LONG  value 
)
static

Definition at line 3044 of file richole.c.

3045{
3047 FIXME("(%p)->(%d): stub\n", This, value);
3048 return E_NOTIMPL;
3049}

◆ TextFont_SetSubscript()

static HRESULT WINAPI TextFont_SetSubscript ( ITextFont iface,
LONG  value 
)
static

Definition at line 3362 of file richole.c.

3363{
3365 TRACE("(%p)->(%d)\n", This, value);
3367}

◆ TextFont_SetSuperscript()

static HRESULT WINAPI TextFont_SetSuperscript ( ITextFont iface,
LONG  value 
)
static

Definition at line 3376 of file richole.c.

3377{
3379 TRACE("(%p)->(%d)\n", This, value);
3381}

◆ TextFont_SetUnderline()

static HRESULT WINAPI TextFont_SetUnderline ( ITextFont iface,
LONG  value 
)
static

Definition at line 3390 of file richole.c.

3391{
3393 TRACE("(%p)->(%d)\n", This, value);
3395}

◆ TextFont_SetWeight()

static HRESULT WINAPI TextFont_SetWeight ( ITextFont iface,
LONG  value 
)
static

Definition at line 3404 of file richole.c.

3405{
3407 TRACE("(%p)->(%d)\n", This, value);
3409}

◆ TextPara_AddRef()

static ULONG WINAPI TextPara_AddRef ( ITextPara iface)
static

Definition at line 3530 of file richole.c.

3531{
3534 TRACE("(%p)->(%u)\n", This, ref);
3535 return ref;
3536}
static ITextParaImpl * impl_from_ITextPara(ITextPara *iface)
Definition: richole.c:274

◆ TextPara_AddTab()

static HRESULT WINAPI TextPara_AddTab ( ITextPara iface,
FLOAT  tbPos,
LONG  tbAlign,
LONG  tbLeader 
)
static

Definition at line 3925 of file richole.c.

3926{
3928 FIXME("(%p)->(%.2f %d %d)\n", This, tbPos, tbAlign, tbLeader);
3929 return E_NOTIMPL;
3930}

◆ TextPara_CanChange()

static HRESULT WINAPI TextPara_CanChange ( ITextPara iface,
LONG ret 
)
static

Definition at line 3631 of file richole.c.

3632{
3634 FIXME("(%p)->(%p)\n", This, ret);
3635 return E_NOTIMPL;
3636}

◆ TextPara_ClearAllTabs()

static HRESULT WINAPI TextPara_ClearAllTabs ( ITextPara iface)
static

Definition at line 3932 of file richole.c.

3933{
3935 FIXME("(%p)\n", This);
3936 return E_NOTIMPL;
3937}

◆ TextPara_DeleteTab()

static HRESULT WINAPI TextPara_DeleteTab ( ITextPara iface,
FLOAT  pos 
)
static

Definition at line 3939 of file richole.c.

3940{
3942 FIXME("(%p)->(%.2f)\n", This, pos);
3943 return E_NOTIMPL;
3944}

◆ TextPara_GetAlignment()

static HRESULT WINAPI TextPara_GetAlignment ( ITextPara iface,
LONG value 
)
static

Definition at line 3666 of file richole.c.

3667{
3669 FIXME("(%p)->(%p)\n", This, value);
3670 return E_NOTIMPL;
3671}

◆ TextPara_GetDuplicate()

static HRESULT WINAPI TextPara_GetDuplicate ( ITextPara iface,
ITextPara **  ret 
)
static

Definition at line 3617 of file richole.c.

3618{
3620 FIXME("(%p)->(%p)\n", This, ret);
3621 return E_NOTIMPL;
3622}

◆ TextPara_GetFirstLineIndent()

static HRESULT WINAPI TextPara_GetFirstLineIndent ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3694 of file richole.c.

3695{
3697 FIXME("(%p)->(%p)\n", This, value);
3698 return E_NOTIMPL;
3699}

◆ TextPara_GetHyphenation()

static HRESULT WINAPI TextPara_GetHyphenation ( ITextPara iface,
LONG value 
)
static

Definition at line 3680 of file richole.c.

3681{
3683 FIXME("(%p)->(%p)\n", This, value);
3684 return E_NOTIMPL;
3685}

◆ TextPara_GetIDsOfNames()

static HRESULT WINAPI TextPara_GetIDsOfNames ( ITextPara iface,
REFIID  riid,
LPOLESTR rgszNames,
UINT  cNames,
LCID  lcid,
DISPID rgDispId 
)
static

Definition at line 3576 of file richole.c.

3578{
3580 ITypeInfo *ti;
3581 HRESULT hr;
3582
3583 TRACE("(%p)->(%s, %p, %u, %d, %p)\n", This, debugstr_guid(riid), rgszNames,
3584 cNames, lcid, rgDispId);
3585
3587 if (SUCCEEDED(hr))
3588 hr = ITypeInfo_GetIDsOfNames(ti, rgszNames, cNames, rgDispId);
3589 return hr;
3590}

◆ TextPara_GetKeepTogether()

static HRESULT WINAPI TextPara_GetKeepTogether ( ITextPara iface,
LONG value 
)
static

Definition at line 3701 of file richole.c.

3702{
3704 FIXME("(%p)->(%p)\n", This, value);
3705 return E_NOTIMPL;
3706}

◆ TextPara_GetKeepWithNext()

static HRESULT WINAPI TextPara_GetKeepWithNext ( ITextPara iface,
LONG value 
)
static

Definition at line 3715 of file richole.c.

3716{
3718 FIXME("(%p)->(%p)\n", This, value);
3719 return E_NOTIMPL;
3720}

◆ TextPara_GetLeftIndent()

static HRESULT WINAPI TextPara_GetLeftIndent ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3729 of file richole.c.

3730{
3732 FIXME("(%p)->(%p)\n", This, value);
3733 return E_NOTIMPL;
3734}

◆ TextPara_GetLineSpacing()

static HRESULT WINAPI TextPara_GetLineSpacing ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3736 of file richole.c.

3737{
3739 FIXME("(%p)->(%p)\n", This, value);
3740 return E_NOTIMPL;
3741}

◆ TextPara_GetLineSpacingRule()

static HRESULT WINAPI TextPara_GetLineSpacingRule ( ITextPara iface,
LONG value 
)
static

Definition at line 3743 of file richole.c.

3744{
3746 FIXME("(%p)->(%p)\n", This, value);
3747 return E_NOTIMPL;
3748}

◆ TextPara_GetListAlignment()

static HRESULT WINAPI TextPara_GetListAlignment ( ITextPara iface,
LONG value 
)
static

Definition at line 3750 of file richole.c.

3751{
3753 FIXME("(%p)->(%p)\n", This, value);
3754 return E_NOTIMPL;
3755}

◆ TextPara_GetListLevelIndex()

static HRESULT WINAPI TextPara_GetListLevelIndex ( ITextPara iface,
LONG value 
)
static

Definition at line 3764 of file richole.c.

3765{
3767 FIXME("(%p)->(%p)\n", This, value);
3768 return E_NOTIMPL;
3769}

◆ TextPara_GetListStart()

static HRESULT WINAPI TextPara_GetListStart ( ITextPara iface,
LONG value 
)
static

Definition at line 3778 of file richole.c.

3779{
3781 FIXME("(%p)->(%p)\n", This, value);
3782 return E_NOTIMPL;
3783}

◆ TextPara_GetListTab()

static HRESULT WINAPI TextPara_GetListTab ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3792 of file richole.c.

3793{
3795 FIXME("(%p)->(%p)\n", This, value);
3796 return E_NOTIMPL;
3797}

◆ TextPara_GetListType()

static HRESULT WINAPI TextPara_GetListType ( ITextPara iface,
LONG value 
)
static

Definition at line 3806 of file richole.c.

3807{
3809 FIXME("(%p)->(%p)\n", This, value);
3810 return E_NOTIMPL;
3811}

◆ TextPara_GetNoLineNumber()

static HRESULT WINAPI TextPara_GetNoLineNumber ( ITextPara iface,
LONG value 
)
static

Definition at line 3820 of file richole.c.

3821{
3823 FIXME("(%p)->(%p)\n", This, value);
3824 return E_NOTIMPL;
3825}

◆ TextPara_GetPageBreakBefore()

static HRESULT WINAPI TextPara_GetPageBreakBefore ( ITextPara iface,
LONG value 
)
static

Definition at line 3834 of file richole.c.

3835{
3837 FIXME("(%p)->(%p)\n", This, value);
3838 return E_NOTIMPL;
3839}

◆ TextPara_GetRightIndent()

static HRESULT WINAPI TextPara_GetRightIndent ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3848 of file richole.c.

3849{
3851 FIXME("(%p)->(%p)\n", This, value);
3852 return E_NOTIMPL;
3853}

◆ TextPara_GetSpaceAfter()

static HRESULT WINAPI TextPara_GetSpaceAfter ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3876 of file richole.c.

3877{
3879 FIXME("(%p)->(%p)\n", This, value);
3880 return E_NOTIMPL;
3881}

◆ TextPara_GetSpaceBefore()

static HRESULT WINAPI TextPara_GetSpaceBefore ( ITextPara iface,
FLOAT value 
)
static

Definition at line 3890 of file richole.c.

3891{
3893 FIXME("(%p)->(%p)\n", This, value);
3894 return E_NOTIMPL;
3895}

◆ TextPara_GetStyle()

static HRESULT WINAPI TextPara_GetStyle ( ITextPara iface,
LONG value 
)
static

Definition at line 3652 of file richole.c.

3653{
3655 FIXME("(%p)->(%p)\n", This, value);
3656 return E_NOTIMPL;
3657}

◆ TextPara_GetTab()

static HRESULT WINAPI TextPara_GetTab ( ITextPara iface,
LONG  iTab,
FLOAT ptbPos,
LONG ptbAlign,
LONG ptbLeader 
)
static

Definition at line 3946 of file richole.c.

3947{
3949 FIXME("(%p)->(%d %p %p %p)\n", This, iTab, ptbPos, ptbAlign, ptbLeader);
3950 return E_NOTIMPL;
3951}

◆ TextPara_GetTabCount()

static HRESULT WINAPI TextPara_GetTabCount ( ITextPara iface,
LONG value 
)
static

Definition at line 3918 of file richole.c.

3919{
3921 FIXME("(%p)->(%p)\n", This, value);
3922 return E_NOTIMPL;
3923}

◆ TextPara_GetTypeInfo()

static HRESULT WINAPI TextPara_GetTypeInfo ( ITextPara iface,
UINT  iTInfo,
LCID  lcid,
ITypeInfo **  ppTInfo 
)
static

Definition at line 3562 of file richole.c.

3564{
3566 HRESULT hr;
3567
3568 TRACE("(%p)->(%u,%d,%p)\n", This, iTInfo, lcid, ppTInfo);
3569
3570 hr = get_typeinfo(ITextPara_tid, ppTInfo);
3571 if (SUCCEEDED(hr))
3572 ITypeInfo_AddRef(*ppTInfo);
3573 return hr;
3574}

◆ TextPara_GetTypeInfoCount()

static HRESULT WINAPI TextPara_GetTypeInfoCount ( ITextPara iface,
UINT pctinfo 
)
static

Definition at line 3554 of file richole.c.

3555{
3557 TRACE("(%p)->(%p)\n", This, pctinfo);
3558 *pctinfo = 1;
3559 return S_OK;
3560}

◆ TextPara_GetWidowControl()

static HRESULT WINAPI TextPara_GetWidowControl ( ITextPara iface,
LONG value 
)
static

Definition at line 3904 of file richole.c.

3905{
3907 FIXME("(%p)->(%p)\n", This, value);
3908 return E_NOTIMPL;
3909}

◆ TextPara_Invoke()

static HRESULT WINAPI TextPara_Invoke ( ITextPara iface,
DISPID  dispIdMember,
REFIID  riid,
LCID  lcid,
WORD  wFlags,
DISPPARAMS *  pDispParams,
VARIANT pVarResult,
EXCEPINFO *  pExcepInfo,
UINT puArgErr 
)
static

Definition at line 3592 of file richole.c.

3602{
3604 ITypeInfo *ti;
3605 HRESULT hr;
3606
3607 TRACE("(%p)->(%d, %s, %d, %u, %p, %p, %p, %p)\n", This, dispIdMember,
3608 debugstr_guid(riid), lcid, wFlags, pDispParams, pVarResult,
3609 pExcepInfo, puArgErr);
3610
3612 if (SUCCEEDED(hr))
3613 hr = ITypeInfo_Invoke(ti, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
3614 return hr;
3615}

◆ TextPara_IsEqual()

static HRESULT WINAPI TextPara_IsEqual ( ITextPara iface,
ITextPara para,
LONG ret 
)
static

Definition at line 3638 of file richole.c.

3639{
3641 FIXME("(%p)->(%p %p)\n", This, para, ret);
3642 return E_NOTIMPL;
3643}

◆ TextPara_QueryInterface()

static HRESULT WINAPI TextPara_QueryInterface ( ITextPara iface,
REFIID  riid,
void **  ppv 
)
static

Definition at line 3511 of file richole.c.

3512{
3514
3515 TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv);
3516
3517 if (IsEqualIID(riid, &IID_ITextPara) ||
3520 {
3521 *ppv = iface;
3522 ITextPara_AddRef(iface);
3523 return S_OK;
3524 }
3525
3526 *ppv = NULL;
3527 return E_NOINTERFACE;
3528}

◆ TextPara_Release()

static ULONG WINAPI TextPara_Release ( ITextPara iface)
static

Definition at line 3538 of file richole.c.

3539{
3542
3543 TRACE("(%p)->(%u)\n", This, ref);
3544
3545 if (!ref)
3546 {
3547 ITextRange_Release(This->range);
3548 heap_free(This);
3549 }
3550
3551 return ref;
3552}

◆ TextPara_Reset()

static HRESULT WINAPI TextPara_Reset ( ITextPara iface,
LONG  value 
)
static

Definition at line 3645 of file richole.c.

3646{
3648 FIXME("(%p)->(%d)\n", This, value);
3649 return E_NOTIMPL;
3650}

◆ TextPara_SetAlignment()

static HRESULT WINAPI TextPara_SetAlignment ( ITextPara iface,
LONG  value 
)
static

Definition at line 3673 of file richole.c.

3674{
3676 FIXME("(%p)->(%d)\n", This, value);
3677 return E_NOTIMPL;
3678}

◆ TextPara_SetDuplicate()

static HRESULT WINAPI TextPara_SetDuplicate ( ITextPara iface,
ITextPara para 
)
static

Definition at line 3624 of file richole.c.

3625{
3627 FIXME("(%p)->(%p)\n", This, para);
3628 return E_NOTIMPL;
3629}

◆ TextPara_SetHyphenation()

static HRESULT WINAPI TextPara_SetHyphenation ( ITextPara iface,
LONG  value 
)
static

Definition at line 3687 of file richole.c.

3688{
3690 FIXME("(%p)->(%d)\n", This, value);
3691 return E_NOTIMPL;
3692}

◆ TextPara_SetIndents()

static HRESULT WINAPI TextPara_SetIndents ( ITextPara iface,
FLOAT  StartIndent,
FLOAT  LeftIndent,
FLOAT  RightIndent 
)
static

Definition at line 3862 of file richole.c.

3863{
3865 FIXME("(%p)->(%.2f %.2f %.2f)\n", This, StartIndent, LeftIndent, RightIndent);
3866 return E_NOTIMPL;
3867}

◆ TextPara_SetKeepTogether()

static HRESULT WINAPI TextPara_SetKeepTogether ( ITextPara iface,
LONG  value 
)
static

Definition at line 3708 of file richole.c.

3709{
3711 FIXME("(%p)->(%d)\n", This, value);
3712 return E_NOTIMPL;
3713}

◆ TextPara_SetKeepWithNext()

static HRESULT WINAPI TextPara_SetKeepWithNext ( ITextPara iface,
LONG  value 
)
static

Definition at line 3722 of file richole.c.

3723{
3725 FIXME("(%p)->(%d)\n", This, value);
3726 return E_NOTIMPL;
3727}

◆ TextPara_SetLineSpacing()

static HRESULT WINAPI TextPara_SetLineSpacing ( ITextPara iface,
LONG  LineSpacingRule,
FLOAT  LineSpacing 
)
static

Definition at line 3869 of file richole.c.

3870{
3872 FIXME("(%p)->(%d %.2f)\n", This, LineSpacingRule, LineSpacing);
3873 return E_NOTIMPL;
3874}

◆ TextPara_SetListAlignment()

static HRESULT WINAPI TextPara_SetListAlignment ( ITextPara iface,
LONG  value 
)
static

Definition at line 3757 of file richole.c.

3758{
3760 FIXME("(%p)->(%d)\n", This, value);
3761 return E_NOTIMPL;
3762}

◆ TextPara_SetListLevelIndex()

static HRESULT WINAPI TextPara_SetListLevelIndex ( ITextPara iface,
LONG  value 
)
static

Definition at line 3771 of file richole.c.

3772{
3774 FIXME("(%p)->(%d)\n", This, value);
3775 return E_NOTIMPL;
3776}

◆ TextPara_SetListStart()

static HRESULT WINAPI TextPara_SetListStart ( ITextPara iface,
LONG  value 
)
static

Definition at line 3785 of file richole.c.

3786{
3788 FIXME("(%p)->(%d)\n", This, value);
3789 return E_NOTIMPL;
3790}

◆ TextPara_SetListTab()

static HRESULT WINAPI TextPara_SetListTab ( ITextPara iface,
FLOAT  value 
)
static

Definition at line 3799 of file richole.c.

3800{
3802 FIXME("(%p)->(%.2f)\n", This, value);
3803 return E_NOTIMPL;
3804}

◆ TextPara_SetListType()

static HRESULT WINAPI TextPara_SetListType ( ITextPara iface,
LONG  value 
)
static

Definition at line 3813 of file richole.c.

3814{
3816 FIXME("(%p)->(%d)\n", This, value);
3817 return E_NOTIMPL;
3818}

◆ TextPara_SetNoLineNumber()

static HRESULT WINAPI TextPara_SetNoLineNumber ( ITextPara iface,
LONG  value 
)
static

Definition at line 3827 of file richole.c.

3828{
3830 FIXME("(%p)->(%d)\n", This, value);
3831 return E_NOTIMPL;
3832}

◆ TextPara_SetPageBreakBefore()

static HRESULT WINAPI TextPara_SetPageBreakBefore ( ITextPara iface,
LONG  value 
)
static

Definition at line 3841 of file richole.c.

3842{
3844 FIXME("(%p)->(%d)\n", This, value);
3845 return E_NOTIMPL;
3846}

◆ TextPara_SetRightIndent()

static HRESULT WINAPI TextPara_SetRightIndent ( ITextPara iface,
FLOAT  value 
)
static

Definition at line 3855 of file richole.c.

3856{
3858 FIXME("(%p)->(%.2f)\n", This, value);
3859 return E_NOTIMPL;
3860}

◆ TextPara_SetSpaceAfter()

static HRESULT WINAPI TextPara_SetSpaceAfter ( ITextPara iface,
FLOAT  value 
)
static

Definition at line 3883 of file richole.c.

3884{
3886 FIXME("(%p)->(%.2f)\n", This, value);
3887 return E_NOTIMPL;
3888}

◆ TextPara_SetSpaceBefore()

static HRESULT WINAPI TextPara_SetSpaceBefore ( ITextPara iface,
FLOAT  value 
)
static

Definition at line 3897 of file richole.c.

3898{
3900 FIXME("(%p)->(%.2f)\n", This, value);
3901 return E_NOTIMPL;
3902}

◆ TextPara_SetStyle()

static HRESULT WINAPI TextPara_SetStyle ( ITextPara iface,
LONG  value 
)
static

Definition at line 3659 of file richole.c.

3660{
3662 FIXME("(%p)->(%d)\n", This, value);
3663 return E_NOTIMPL;
3664}

◆ TextPara_SetWidowControl()

static HRESULT WINAPI TextPara_SetWidowControl ( ITextPara iface,
LONG  value 
)
static

Definition at line 3911 of file richole.c.

3912{
3914 FIXME("(%p)->(%d)\n", This, value);
3915 return E_NOTIMPL;
3916}

◆ textrange_copy_or_cut()

static HRESULT textrange_copy_or_cut ( ITextRange range,
ME_TextEditor editor,
BOOL  cut,
VARIANT v 
)
static

Definition at line 2500 of file richole.c.

2501{
2502 LONG start, end;
2504 IDataObject **data_out = NULL;
2505
2506 ITextRange_GetStart( range, &start );
2507 ITextRange_GetEnd( range, &end );
2508 if (start == end)
2509 {
2510 /* If the range is empty, all text is copied */
2511 LONG prev_end = end;
2512 ITextRange_SetEnd( range, MAXLONG );
2513 start = 0;
2514 ITextRange_GetEnd( range, &end );
2515 ITextRange_SetEnd( range, prev_end );
2516 }
2517 cursor_from_char_ofs( editor, start, &cursor );
2518
2519 if (v && V_VT(v) == (VT_UNKNOWN | VT_BYREF) && V_UNKNOWNREF( v ))
2520 data_out = (IDataObject **)V_UNKNOWNREF( v );
2521
2522 return editor_copy_or_cut( editor, cut, &cursor, end - start, data_out );
2523}
@ VT_UNKNOWN
Definition: compat.h:2308
@ VT_BYREF
Definition: compat.h:2342
HRESULT editor_copy_or_cut(ME_TextEditor *editor, BOOL cut, ME_Cursor *start, int count, IDataObject **data_out)
Definition: editor.c:2355
#define V_UNKNOWNREF(A)
Definition: oleauto.h:282
#define V_VT(A)
Definition: oleauto.h:211
#define MAXLONG
Definition: umtypes.h:116

Referenced by ITextRange_fnCopy(), ITextRange_fnCut(), ITextSelection_fnCopy(), and ITextSelection_fnCut().

◆ textrange_endof()

static HRESULT textrange_endof ( ITextRange range,
ME_TextEditor editor,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 2110 of file richole.c.

2111{
2112 HRESULT hr;
2113 LONG old_start, old_end, new_end;
2114 LONG moved;
2115
2116 ITextRange_GetStart(range, &old_start);
2117 ITextRange_GetEnd(range, &old_end);
2118
2119 switch (unit)
2120 {
2121 case tomCharacter:
2122 {
2123 moved = 0;
2124 new_end = old_end;
2125 if (old_end == 0)
2126 {
2128 cursor_from_char_ofs( editor, old_end, &cursor );
2129 moved = ME_MoveCursorChars(editor, &cursor, 1, TRUE);
2130 new_end = old_end + moved;
2131 }
2132 else if (extend == tomMove && old_start != old_end)
2133 moved = 1;
2134
2135 ITextRange_SetEnd(range, new_end);
2136 if (extend == tomMove)
2137 ITextRange_SetStart(range, new_end);
2138 if (delta)
2139 *delta = moved;
2140 hr = moved ? S_OK : S_FALSE;
2141 break;
2142 }
2143 default:
2144 FIXME("unit %d is not supported\n", unit);
2145 return E_NOTIMPL;
2146 }
2147 return hr;
2148}
@ tomCharacter
Definition: tom.idl:118
@ tomMove
Definition: tom.idl:50

Referenced by ITextRange_fnEndOf(), and ITextSelection_fnEndOf().

◆ textrange_expand()

static HRESULT textrange_expand ( ITextRange range,
LONG  unit,
LONG delta 
)
static

Definition at line 881 of file richole.c.

882{
883 LONG expand_start, expand_end;
884
885 switch (unit)
886 {
887 case tomStory:
888 expand_start = 0;
889 ITextRange_GetStoryLength(range, &expand_end);
890 break;
891 default:
892 FIXME("unit %d is not supported\n", unit);
893 return E_NOTIMPL;
894 }
895
896 if (delta) {
897 LONG start, end;
898
899 ITextRange_GetStart(range, &start);
900 ITextRange_GetEnd(range, &end);
901 *delta = expand_end - expand_start - (end - start);
902 }
903
904 ITextRange_SetStart(range, expand_start);
905 ITextRange_SetEnd(range, expand_end);
906
907 return S_OK;
908}
@ tomStory
Definition: tom.idl:123

Referenced by ITextRange_fnExpand(), and ITextSelection_fnExpand().

◆ textrange_get_storylength()

static HRESULT textrange_get_storylength ( ME_TextEditor editor,
LONG length 
)
static

Definition at line 283 of file richole.c.

284{
285 if (!length)
286 return E_INVALIDARG;
287
288 *length = ME_GetTextLength(editor) + 1;
289 return S_OK;
290}

Referenced by ITextRange_fnGetStoryLength(), and ITextSelection_fnGetStoryLength().

◆ textrange_inrange()

static HRESULT textrange_inrange ( LONG  start,
LONG  end,
ITextRange range,
LONG ret 
)
static

Definition at line 1974 of file richole.c.

1975{
1976 LONG from, to, v;
1977
1978 if (!ret)
1979 ret = &v;
1980
1981 if (FAILED(ITextRange_GetStart(range, &from)) || FAILED(ITextRange_GetEnd(range, &to))) {
1982 *ret = tomFalse;
1983 }
1984 else
1985 *ret = (start >= from && end <= to) ? tomTrue : tomFalse;
1986 return *ret == tomTrue ? S_OK : S_FALSE;
1987}

Referenced by ITextRange_fnInRange(), and ITextSelection_fnInRange().

◆ textrange_isequal()

static HRESULT textrange_isequal ( LONG  start,
LONG  end,
ITextRange range,
LONG ret 
)
static

Definition at line 2019 of file richole.c.

2020{
2021 LONG from, to, v;
2022
2023 if (!ret)
2024 ret = &v;
2025
2026 if (FAILED(ITextRange_GetStart(range, &from)) || FAILED(ITextRange_GetEnd(range, &to))) {
2027 *ret = tomFalse;
2028 }
2029 else
2030 *ret = (start == from && end == to) ? tomTrue : tomFalse;
2031 return *ret == tomTrue ? S_OK : S_FALSE;
2032}

Referenced by ITextRange_fnIsEqual(), and ITextSelection_fnIsEqual().

◆ textrange_move()

static HRESULT textrange_move ( ITextRange range,
ME_TextEditor editor,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2163 of file richole.c.

2164{
2165 LONG old_start, old_end, new_start, new_end;
2166 LONG move_by;
2167 LONG moved;
2168 HRESULT hr = S_OK;
2169
2170 if (!count)
2171 {
2172 if (delta)
2173 *delta = 0;
2174 return S_FALSE;
2175 }
2176
2177 ITextRange_GetStart(range, &old_start);
2178 ITextRange_GetEnd(range, &old_end);
2179 switch (unit)
2180 {
2181 case tomCharacter:
2182 {
2184
2185 if (count > 0)
2186 {
2187 cursor_from_char_ofs( editor, old_end, &cursor );
2188 move_by = count;
2189 if (old_start != old_end)
2190 --move_by;
2191 }
2192 else
2193 {
2194 cursor_from_char_ofs( editor, old_start, &cursor );
2195 move_by = count;
2196 if (old_start != old_end)
2197 ++move_by;
2198 }
2199 moved = ME_MoveCursorChars(editor, &cursor, move_by, FALSE);
2200 if (count > 0)
2201 {
2202 new_end = old_end + moved;
2203 new_start = new_end;
2204 if (old_start != old_end)
2205 ++moved;
2206 }
2207 else
2208 {
2209 new_start = old_start + moved;
2210 new_end = new_start;
2211 if (old_start != old_end)
2212 --moved;
2213 }
2214 if (delta) *delta = moved;
2215 break;
2216 }
2217 default:
2218 FIXME("unit %d is not supported\n", unit);
2219 return E_NOTIMPL;
2220 }
2221 if (moved == 0)
2222 hr = S_FALSE;
2223 ITextRange_SetStart(range, new_start);
2224 ITextRange_SetEnd(range, new_end);
2225
2226 return hr;
2227}

Referenced by ITextRange_fnMove().

◆ textrange_moveend()

static HRESULT textrange_moveend ( ITextRange range,
ME_TextEditor editor,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2297 of file richole.c.

2298{
2299 LONG old_start, old_end, new_start, new_end;
2300 HRESULT hr = S_OK;
2301
2302 if (!count)
2303 {
2304 if (delta)
2305 *delta = 0;
2306 return S_FALSE;
2307 }
2308
2309 ITextRange_GetStart(range, &old_start);
2310 ITextRange_GetEnd(range, &old_end);
2311 switch (unit)
2312 {
2313 case tomCharacter:
2314 {
2316 LONG moved;
2317
2318 cursor_from_char_ofs( editor, old_end, &cursor );
2319 moved = ME_MoveCursorChars(editor, &cursor, count, TRUE);
2320 new_start = old_start;
2321 new_end = old_end + moved;
2322 if (new_end < new_start)
2323 new_start = new_end;
2324 if (delta)
2325 *delta = moved;
2326 break;
2327 }
2328 case tomStory:
2329 if (count < 0)
2330 new_start = new_end = 0;
2331 else
2332 {
2333 new_start = old_start;
2334 ITextRange_GetStoryLength(range, &new_end);
2335 }
2336 if (delta)
2337 {
2338 if (new_end < old_end)
2339 *delta = -1;
2340 else if (new_end == old_end)
2341 *delta = 0;
2342 else
2343 *delta = 1;
2344 }
2345 break;
2346 default:
2347 FIXME("unit %d is not supported\n", unit);
2348 return E_NOTIMPL;
2349 }
2350 if (new_end == old_end)
2351 hr = S_FALSE;
2352 ITextRange_SetStart(range, new_start);
2353 ITextRange_SetEnd(range, new_end);
2354
2355 return hr;
2356}

Referenced by ITextRange_fnMoveEnd(), and ITextSelection_fnMoveEnd().

◆ textrange_movestart()

static HRESULT textrange_movestart ( ITextRange range,
ME_TextEditor editor,
LONG  unit,
LONG  count,
LONG delta 
)
static

Definition at line 2241 of file richole.c.

2242{
2243 LONG old_start, old_end, new_start, new_end;
2244 HRESULT hr = S_OK;
2245
2246 if (!count)
2247 {
2248 if (delta)
2249 *delta = 0;
2250 return S_FALSE;
2251 }
2252
2253 ITextRange_GetStart(range, &old_start);
2254 ITextRange_GetEnd(range, &old_end);
2255 switch (unit)
2256 {
2257 case tomCharacter:
2258 {
2260 LONG moved;
2261
2262 cursor_from_char_ofs( editor, old_start, &cursor );
2263 moved = ME_MoveCursorChars(editor, &cursor, count, FALSE);
2264 new_start = old_start + moved;
2265 new_end = old_end;
2266 if (new_end < new_start)
2267 new_end = new_start;
2268 if (delta)
2269 *delta = moved;
2270 break;
2271 }
2272 default:
2273 FIXME("unit %d is not supported\n", unit);
2274 return E_NOTIMPL;
2275 }
2276 if (new_start == old_start)
2277 hr = S_FALSE;
2278 ITextRange_SetStart(range, new_start);
2279 ITextRange_SetEnd(range, new_end);
2280
2281 return hr;
2282}

Referenced by ITextRange_fnMoveStart(), ITextSelection_fnMove(), and ITextSelection_fnMoveStart().

◆ textrange_set_font()

static void textrange_set_font ( ITextRange range,
ITextFont font 
)
static

Definition at line 491 of file richole.c.

492{
494 HRESULT hr;
495 LONG value;
496 BSTR str;
497 FLOAT f;
498
499#define CHARFORMAT_SET_B_FIELD(mask, value) \
500 if (hr == S_OK && value != tomUndefined) { \
501 fmt.dwMask |= CFM_##mask; \
502 if (value == tomTrue) fmt.dwEffects |= CFE_##mask; \
503 } \
504
505 /* fill format data from font */
506 memset(&fmt, 0, sizeof(fmt));
507 fmt.cbSize = sizeof(fmt);
508
510 hr = ITextFont_GetAllCaps(font, &value);
512
514 hr = ITextFont_GetBold(font, &value);
516
518 hr = ITextFont_GetEmboss(font, &value);
520
522 hr = ITextFont_GetHidden(font, &value);
524
526 hr = ITextFont_GetEngrave(font, &value);
528
530 hr = ITextFont_GetItalic(font, &value);
532
534 hr = ITextFont_GetOutline(font, &value);
536
538 hr = ITextFont_GetProtected(font, &value);
539 CHARFORMAT_SET_B_FIELD(PROTECTED, value);
540
542 hr = ITextFont_GetShadow(font, &value);
544
546 hr = ITextFont_GetSmallCaps(font, &value);
547 CHARFORMAT_SET_B_FIELD(SMALLCAPS, value);
548
550 hr = ITextFont_GetStrikeThrough(font, &value);
551 CHARFORMAT_SET_B_FIELD(STRIKEOUT, value);
552
554 hr = ITextFont_GetSubscript(font, &value);
556
558 hr = ITextFont_GetSuperscript(font, &value);
559 CHARFORMAT_SET_B_FIELD(SUPERSCRIPT, value);
560
562 hr = ITextFont_GetUnderline(font, &value);
563 CHARFORMAT_SET_B_FIELD(UNDERLINE, value);
564
565#undef CHARFORMAT_SET_B_FIELD
566
568 hr = ITextFont_GetAnimation(font, &value);
569 if (hr == S_OK && value != tomUndefined) {
570 fmt.dwMask |= CFM_ANIMATION;
571 fmt.bAnimation = value;
572 }
573
575 hr = ITextFont_GetBackColor(font, &value);
576 if (hr == S_OK && value != tomUndefined) {
577 fmt.dwMask |= CFM_BACKCOLOR;
578 if (value == tomAutoColor)
579 fmt.dwEffects |= CFE_AUTOBACKCOLOR;
580 else
581 fmt.crBackColor = value;
582 }
583
585 hr = ITextFont_GetForeColor(font, &value);
586 if (hr == S_OK && value != tomUndefined) {
587 fmt.dwMask |= CFM_COLOR;
588 if (value == tomAutoColor)
589 fmt.dwEffects |= CFE_AUTOCOLOR;
590 else
591 fmt.crTextColor = value;
592 }
593
595 hr = ITextFont_GetKerning(font, &f);
596 if (hr == S_OK && f != tomUndefined) {
597 fmt.dwMask |= CFM_KERNING;
598 fmt.wKerning = points_to_twips(f);
599 }
600
602 hr = ITextFont_GetLanguageID(font, &value);
603 if (hr == S_OK && value != tomUndefined) {
604 fmt.dwMask |= CFM_LCID;
605 fmt.lcid = value;
606 }
607
608 if (ITextFont_GetName(font, &str) == S_OK) {
609 fmt.dwMask |= CFM_FACE;
610 lstrcpynW(fmt.szFaceName, str, ARRAY_SIZE(fmt.szFaceName));
612 }
613
614 hr = ITextFont_GetPosition(font, &f);
615 if (hr == S_OK && f != tomUndefined) {
616 fmt.dwMask |= CFM_OFFSET;
617 fmt.yOffset = points_to_twips(f);
618 }
619
620 hr = ITextFont_GetSize(font, &f);
621 if (hr == S_OK && f != tomUndefined) {
622 fmt.dwMask |= CFM_SIZE;
623 fmt.yHeight = points_to_twips(f);
624 }
625
626 hr = ITextFont_GetSpacing(font, &f);
627 if (hr == S_OK && f != tomUndefined) {
628 fmt.dwMask |= CFM_SPACING;
629 fmt.sSpacing = f;
630 }
631
632 hr = ITextFont_GetWeight(font, &value);
633 if (hr == S_OK && value != tomUndefined) {
634 fmt.dwMask |= CFM_WEIGHT;
635 fmt.wWeight = value;
636 }
637
638 if (fmt.dwMask)
639 {
641 ME_Cursor from, to;
642 LONG start, end;
643
644 ITextRange_GetStart(range, &start);
645 ITextRange_GetEnd(range, &end);
646
648 cursor_from_char_ofs( services->editor, end, &to );
649 ME_SetCharFormat( services->editor, &from, &to, &fmt );
650 }
651}
small capitals from c petite p scientific f SUBSCRIPT
Definition: afcover.h:86
OLECHAR * BSTR
Definition: compat.h:2293
#define CHARFORMAT_SET_B_FIELD(mask, value)
static FLOAT points_to_twips(FLOAT value)
Definition: richole.c:405
#define HIDDEN
Definition: fatfs.h:184
GLfloat f
Definition: glext.h:7540
#define f
Definition: ke_i.h:83
#define CFM_OFFSET
Definition: richedit.h:359
#define CFM_WEIGHT
Definition: richedit.h:354
#define CFM_SPACING
Definition: richedit.h:353
#define CFM_BACKCOLOR
Definition: richedit.h:357
#define CFM_KERNING
Definition: richedit.h:352
#define CFM_LCID
Definition: richedit.h:356
#define CFM_SIZE
Definition: richedit.h:362
#define CFM_ANIMATION
Definition: richedit.h:350
#define CFM_FACE
Definition: richedit.h:360
#define CFM_COLOR
Definition: richedit.h:361
float FLOAT
Definition: typedefs.h:69

Referenced by ITextRange_fnSetFont(), and ITextSelection_fnSetFont().

◆ textrange_setend()

static HRESULT textrange_setend ( const struct text_services services,
LONG  value,
LONG start,
LONG end 
)
static

Definition at line 1762 of file richole.c.

1763{
1764 int len;
1765
1766 if (value == *end)
1767 return S_FALSE;
1768
1769 if (value < *start) {
1770 *start = *end = max(0, value);
1771 return S_OK;
1772 }
1773
1774 len = ME_GetTextLength( services->editor );
1775 *end = value > len ? len + 1 : value;
1776 return S_OK;
1777}

Referenced by ITextRange_fnSetEnd(), and ITextSelection_fnSetEnd().

◆ textrange_setstart()

static HRESULT textrange_setstart ( const struct text_services services,
LONG  value,
LONG start,
LONG end 
)
static

Definition at line 1714 of file richole.c.

1715{
1716 int len;
1717
1718 if (value < 0)
1719 value = 0;
1720
1721 if (value == *start)
1722 return S_FALSE;
1723
1724 if (value <= *end) {
1725 *start = value;
1726 return S_OK;
1727 }
1728
1729 len = ME_GetTextLength(services->editor);
1730 *start = *end = value > len ? len : value;
1731 return S_OK;
1732}

Referenced by ITextRange_fnSetStart(), and ITextSelection_fnSetStart().

◆ textrange_startof()

static HRESULT textrange_startof ( ITextRange range,
LONG  unit,
LONG  extend,
LONG delta 
)
static

Definition at line 2065 of file richole.c.

2066{
2067 HRESULT hr;
2068 LONG start, end;
2069 LONG moved;
2070
2071 ITextRange_GetStart(range, &start);
2072 ITextRange_GetEnd(range, &end);
2073
2074 switch (unit)
2075 {
2076 case tomCharacter:
2077 {
2078 moved = 0;
2079 if (extend == tomMove) {
2080 if (start != end) {
2081 ITextRange_SetEnd(range, start);
2082 moved = -1;
2083 }
2084 }
2085 if (delta)
2086 *delta = moved;
2087 hr = moved ? S_OK : S_FALSE;
2088 break;
2089 }
2090 default:
2091 FIXME("unit %d is not supported\n", unit);
2092 return E_NOTIMPL;
2093 }
2094 return hr;
2095}

Referenced by ITextRange_fnStartOf(), and ITextSelection_fnStartOf().

◆ textranges_update_ranges()

static void textranges_update_ranges ( struct text_services services,
LONG  start,
LONG  end,
enum range_update_op  op 
)
static

Definition at line 292 of file richole.c.

293{
295
297 switch (op)
298 {
300 /* range fully covered by deleted range - collapse to insertion point */
301 if (range->start >= start && range->end <= end)
302 range->start = range->end = start;
303 /* deleted range cuts from the right */
304 else if (range->start < start && range->end <= end)
305 range->end = start;
306 /* deleted range cuts from the left */
307 else if (range->start >= start && range->end > end) {
308 range->start = start;
309 range->end -= end - start;
310 }
311 /* deleted range cuts within */
312 else
313 range->end -= end - start;
314 break;
315 default:
316 FIXME("unknown update op, %d\n", op);
317 }
318 }
319}
UINT op
Definition: effect.c:236

Referenced by ITextRange_fnSetText(), and ITextSelection_fnSetText().

◆ twips_to_points()

static FLOAT twips_to_points ( LONG  value)
inlinestatic

Definition at line 400 of file richole.c.

401{
402 return value * 72.0 / 1440;
403}

Referenced by get_textfont_prop_for_pos(), and test_ITextFont().

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( richedit  )

Variable Documentation

◆ ocst

const IOleClientSiteVtbl ocst
static
Initial value:
= {
}
static HRESULT WINAPI IOleClientSite_fnGetContainer(IOleClientSite *iface, IOleContainer **ppContainer)
Definition: richole.c:1029
static ULONG WINAPI IOleClientSite_fnAddRef(IOleClientSite *iface)
Definition: richole.c:983
static HRESULT WINAPI IOleClientSite_fnQueryInterface(IOleClientSite *me, REFIID riid, LPVOID *ppvObj)
Definition: richole.c:961
static HRESULT WINAPI IOleClientSite_fnShowObject(IOleClientSite *iface)
Definition: richole.c:1040
static HRESULT WINAPI IOleClientSite_fnSaveObject(IOleClientSite *iface)
Definition: richole.c:1008
static HRESULT WINAPI IOleClientSite_fnRequestNewObjectLayout(IOleClientSite *iface)
Definition: richole.c:1060
static HRESULT WINAPI IOleClientSite_fnOnShowWindow(IOleClientSite *iface, BOOL fShow)
Definition: richole.c:1050
static ULONG WINAPI IOleClientSite_fnRelease(IOleClientSite *iface)
Definition: richole.c:991
static HRESULT WINAPI IOleClientSite_fnGetMoniker(IOleClientSite *iface, DWORD dwAssign, DWORD dwWhichMoniker, IMoniker **ppmk)
Definition: richole.c:1018

Definition at line 1070 of file richole.c.

Referenced by CreateOleClientSite().

◆ olestvt

const IOleInPlaceSiteVtbl olestvt
static
Initial value:
=
{
}
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnContextSensitiveHelp(IOleInPlaceSite *iface, BOOL fEnterMode)
Definition: richole.c:1116
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnUIActivate(IOleInPlaceSite *iface)
Definition: richole.c:1137
static ULONG STDMETHODCALLTYPE IOleInPlaceSite_fnAddRef(IOleInPlaceSite *iface)
Definition: richole.c:1089
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnDeactivateAndUndo(IOleInPlaceSite *iface)
Definition: richole.c:1181
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnUIDeactivate(IOleInPlaceSite *iface, BOOL fUndoable)
Definition: richole.c:1160
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnQueryInterface(IOleInPlaceSite *iface, REFIID riid, void **ppvObj)
Definition: richole.c:1083
static ULONG STDMETHODCALLTYPE IOleInPlaceSite_fnRelease(IOleInPlaceSite *iface)
Definition: richole.c:1095
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnInPlaceDeactivate(IOleInPlaceSite *iface)
Definition: richole.c:1167
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnDiscardUndoState(IOleInPlaceSite *iface)
Definition: richole.c:1174
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnGetWindowContext(IOleInPlaceSite *iface, IOleInPlaceFrame **ppFrame, IOleInPlaceUIWindow **ppDoc, LPRECT lprcPosRect, LPRECT lprcClipRect, LPOLEINPLACEFRAMEINFO lpFrameInfo)
Definition: richole.c:1144
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnScroll(IOleInPlaceSite *iface, SIZE scrollExtent)
Definition: richole.c:1153
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnPosRectChange(IOleInPlaceSite *iface, LPCRECT lprcPosRect)
Definition: richole.c:1188
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnCanInPlaceActivate(IOleInPlaceSite *iface)
Definition: richole.c:1123
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnGetWindow(IOleInPlaceSite *iface, HWND *window)
Definition: richole.c:1101
static HRESULT STDMETHODCALLTYPE IOleInPlaceSite_fnOnInPlaceActivate(IOleInPlaceSite *iface)
Definition: richole.c:1130

Definition at line 1195 of file richole.c.

Referenced by CreateOleClientSite().

◆ re_ole_vtbl

const IRichEditOleVtbl re_ole_vtbl
Initial value:
=
{
}
static HRESULT WINAPI IRichEditOle_fnConvertObject(IRichEditOle *iface, LONG iob, REFCLSID class, LPCSTR user_type)
Definition: richole.c:948
static HRESULT WINAPI IRichEditOle_fnSaveCompleted(IRichEditOle *iface, LONG iob, LPSTORAGE lpstg)
Definition: richole.c:1376
static HRESULT WINAPI IRichEditOle_fnQueryInterface(IRichEditOle *iface, REFIID riid, LPVOID *ppvObj)
Definition: richole.c:911
static HRESULT WINAPI IRichEditOle_fnGetClipboardData(IRichEditOle *iface, CHARRANGE *lpchrg, DWORD reco, LPDATAOBJECT *lplpdataobj)
Definition: richole.c:1245
static HRESULT WINAPI IRichEditOle_fnGetClientSite(IRichEditOle *iface, IOleClientSite **clientsite)
Definition: richole.c:1232
static HRESULT WINAPI IRichEditOle_fnGetObject(IRichEditOle *iface, LONG iob, REOBJECT *lpreobject, DWORD dwFlags)
Definition: richole.c:1277
static ULONG WINAPI IRichEditOle_fnAddRef(IRichEditOle *iface)
Definition: richole.c:918
static LONG WINAPI IRichEditOle_fnGetLinkCount(IRichEditOle *iface)
Definition: richole.c:1269
static LONG WINAPI IRichEditOle_fnGetObjectCount(IRichEditOle *iface)
Definition: richole.c:1326
static HRESULT WINAPI IRichEditOle_fnInsertObject(IRichEditOle *iface, REOBJECT *reo)
Definition: richole.c:1359
static HRESULT WINAPI IRichEditOle_fnActivateAs(IRichEditOle *iface, REFCLSID rclsid, REFCLSID rclsidAs)
Definition: richole.c:932
static HRESULT WINAPI IRichEditOle_fnSetHostNames(IRichEditOle *iface, LPCSTR lpstrContainerApp, LPCSTR lpstrContainerObj)
Definition: richole.c:1392
static HRESULT WINAPI IRichEditOle_fnImportDataObject(IRichEditOle *iface, LPDATAOBJECT lpdataobj, CLIPFORMAT cf, HGLOBAL hMetaPict)
Definition: richole.c:1342
static HRESULT WINAPI IRichEditOle_fnInPlaceDeactivate(IRichEditOle *iface)
Definition: richole.c:1351
static HRESULT WINAPI IRichEditOle_fnSetDvaspect(IRichEditOle *iface, LONG iob, DWORD dvaspect)
Definition: richole.c:1385
static HRESULT WINAPI IRichEditOle_fnContextSensitiveHelp(IRichEditOle *iface, BOOL fEnterMode)
Definition: richole.c:940
static HRESULT WINAPI IRichEditOle_fnSetLinkAvailable(IRichEditOle *iface, LONG iob, BOOL fAvailable)
Definition: richole.c:1401
static HRESULT WINAPI IRichEditOle_fnHandsOffStorage(IRichEditOle *iface, LONG iob)
Definition: richole.c:1334
static ULONG WINAPI IRichEditOle_fnRelease(IRichEditOle *iface)
Definition: richole.c:925

Definition at line 1408 of file richole.c.

Referenced by create_text_services().

◆ text_doc2old_vtbl

const ITextDocument2OldVtbl text_doc2old_vtbl

Definition at line 4469 of file richole.c.

Referenced by create_text_services().

◆ textfont_prop_masks

const DWORD textfont_prop_masks[][2]
static
Initial value:
= {
{ CFM_LCID },
{ CFM_FACE },
{ CFM_SIZE },
}
#define CFM_PROTECTED
Definition: richedit.h:336
#define CFE_SMALLCAPS
Definition: richedit.h:416
#define CFM_STRIKEOUT
Definition: richedit.h:335
#define CFM_SMALLCAPS
Definition: richedit.h:338
#define CFE_STRIKEOUT
Definition: richedit.h:409
#define CFE_OUTLINE
Definition: richedit.h:419
#define CFE_HIDDEN
Definition: richedit.h:418
#define CFE_BOLD
Definition: richedit.h:406
#define CFM_SHADOW
Definition: richedit.h:342
#define CFM_IMPRINT
Definition: richedit.h:344
#define CFE_ALLCAPS
Definition: richedit.h:417
#define CFE_ITALIC
Definition: richedit.h:407
#define CFM_OUTLINE
Definition: richedit.h:341
#define CFE_SUPERSCRIPT
Definition: richedit.h:413
#define CFM_EMBOSS
Definition: richedit.h:343
#define CFM_SUBSCRIPT
Definition: richedit.h:348
#define CFE_IMPRINT
Definition: richedit.h:422
#define CFM_HIDDEN
Definition: richedit.h:340
#define CFE_UNDERLINE
Definition: richedit.h:408
#define CFE_SUBSCRIPT
Definition: richedit.h:412
#define CFM_ITALIC
Definition: richedit.h:333
#define CFE_PROTECTED
Definition: richedit.h:410
#define CFE_EMBOSS
Definition: richedit.h:421
#define CFM_BOLD
Definition: richedit.h:332
#define CFE_SHADOW
Definition: richedit.h:420
#define CFM_UNDERLINE
Definition: richedit.h:334
#define CFM_ALLCAPS
Definition: richedit.h:339
#define CFM_SUPERSCRIPT
Definition: richedit.h:349

Definition at line 171 of file richole.c.

Referenced by get_textfont_prop_for_pos(), and set_textfont_prop().

◆ textfontvtbl

ITextFontVtbl textfontvtbl
static

Definition at line 3411 of file richole.c.

Referenced by create_textfont().

◆ textparavtbl

ITextParaVtbl textparavtbl
static

Definition at line 3953 of file richole.c.

Referenced by create_textpara().

◆ tid_ids

const IID* const tid_ids[]
static
Initial value:
=
{
&IID_ITextDocument,
&IID_ITextRange,
&IID_ITextSelection,
&IID_ITextFont,
&IID_ITextPara,
}
#define IID_NULL
Definition: guiddef.h:98

Definition at line 67 of file richole.c.

Referenced by get_typeinfo().

◆ trvt

const ITextRangeVtbl trvt
static

Definition at line 2666 of file richole.c.

Referenced by CreateITextRange().

◆ tsvt

const ITextSelectionVtbl tsvt
static

Definition at line 5554 of file richole.c.

Referenced by text_selection_create().

◆ typeinfos

ITypeInfo* typeinfos[LAST_tid]
static

Definition at line 76 of file richole.c.

Referenced by get_typeinfo(), and release_typelib().

◆ typelib

ITypeLib* typelib
static

Definition at line 55 of file richole.c.