Udostępnij za pośrednictwem


CDocument Members

Base Class Members

CObject Members

CCmdTarget Members

Construction

CDocument

Constructs a CDocument object.

Operations

AddView

Attaches a view to the document.

BeginReadChunks

Initializes chunk reading.

ClearChunkList

Clears the chunk list.

FindChunk

Looks for a chunk with specified GUID.

GetAdapter

Returns a pointer to object implementing IDocument interface.

GetDocTemplate

Returns a pointer to the document template that describes the type of the document.

GetFirstViewPosition

Returns the position of the first in the list of views; used to begin iteration.

GetNextView

Iterates through the list of views associated with the document.

GetPathName

Returns the path of the document's data file.

GetThumbnail

Called to create a bitmap to be used by thumbnail provider to display thumbnail.

GetTitle

Returns the document's title.

InitializeSearchContent

Called to initialize search content for Search Handler.

IsModified

Indicates whether the document has been modified since it was last saved.

IsSearchAndOrganizeHandler

Tells whether this instance of CDocument object was created for Search & Organize handler.

LoadDocumentFromStream

Called to load document data from stream.

ReadNextChunkValue

Reads next chunk value.

RemoveChunk

Removes a chunk with specified GUID

RemoveView

Detaches a view from the document.

SetChunkValue

Sets a chunk value.

SetModifiedFlag

Sets a flag indicating that you have modified the document since it was last saved.

SetPathName

Sets the path of the data file used by the document.

SetTitle

Sets the document's title.

UpdateAllViews

Notifies all views that document has been modified.

Public Data Members

m_bGetThumbnailMode

Specifies that CDocument object was created by dllhost for thumbnails. Should be checked in CView::OnDraw.

m_bPreviewHandlerMode

Specifies that CDocument object was created by prevhost for Rich Preview. Should be checked in CView::OnDraw.

m_bSearchMode

Specifies that CDocument object was created by indexer or other search application.

m_clrRichPreviewBackColor

Specifies background color of Rich Preview window. This color is set by host.

m_clrRichPreviewTextColor

Specifies foreground color of Rich Preview window. This color is set by host.

m_lfRichPreviewFont

Specifies text font for Rich Preview window. This font information is set by host.

Overridables

CanCloseFrame

Advanced overridable; called before closing a frame window viewing this document.

ClearPathName

Clears the path of the document object.

DeleteContents

Called to perform cleanup of the document.

GetFile

Returns a pointer to the desired CFile object.

OnBeforeRichPreviewFontChanged

Called before Rich Preview font is changed.

OnChangedViewList

Called after a view is added to or removed from the document.

OnCloseDocument

Called to close the document.

OnCreatePreviewFrame

Called by the framework when it needs to create a preview frame for Rich Preview.

OnDocumentEvent

Called by the framework in response to a document event.

OnDrawThumbnail

Override this method in a derived class to draw content of thumbnail.

OnLoadDocumentFromStream

Called by the framework when it needs to load the document data from stream.

OnNewDocument

Called to create a new document.

OnOpenDocument

Called to open an existing document.

OnPreviewHandlerQueryFocus

Directs the preview handler to return the HWND from calling the GetFocus Function.

OnPreviewHandlerTranslateAccelerator

Directs the preview handler to handle a keystroke passed up from the message pump of the process in which the preview handler is running.

OnRichPreviewBackColorChanged

Called when Rich Preview background color has changed.

OnRichPreviewFontChanged

Called when Rich Preview font has changed.

OnRichPreviewSiteChanged

Called when Rich Preview site has changed.

OnRichPreviewTextColorChanged

Called when Rich Preview text color has changed.

OnSaveDocument

Called to save the document to disk.

OnUnloadHandler

Called by the framework when the preview handler is being unloaded.

PreCloseFrame

Called before the frame window is closed.

ReleaseFile

Releases a file to make it available for use by other applications.

ReportSaveLoadException

Advanced overridable; called when an open or save operation cannot be completed because of an exception.

SaveModified

Advanced overridable; called to ask the user whether the document should be saved.

Mail Functions

OnFileSendMail

Sends a mail message with the document attached.

OnUpdateFileSendMail

Enables the Send Mail command if mail support is present.

See Also

Reference

CDocument Class

Hierarchy Chart