9#if !defined(OWL_EDITVIEW_H)
13#if defined(BI_HAS_PRAGMA_ONCE)
44 auto SetDocTitle(LPCTSTR docname,
int index) ->
bool override;
49 auto Create() ->
bool override;
89 return _T(
"Edit View");
104 return static_cast<TWindow*
>(
this);
121 (Doc->NextView(
this) ||
122 Doc->NextView(
nullptr) !=
this ||
Derived from TView and TEditSearch, TEditView provides a view wrapper for the ObjectWindows text edit...
auto SetDocTitle(LPCTSTR docname, int index) -> bool override
Overrides TView::SetDocTitle and forwards the title to its base class, TEditSearch.
bool VnCommit(bool force)
Commits changes made in the view to the document.
void EvNCDestroy()
Used internally by TEditView to manage memory.
bool VnDocClosed(int omode)
Indicates that the document has been closed.
TEditView(TDocument &doc, TWindow *parent=0)
Creates a TEditView object associated with the specified document and parent window.
long GetOrigin() const
Returns the position of the stream buffer at which the edit buffer is stored.
bool VnRevert(bool clear)
Returns a nonzero value if changes made to the view should be erased and the data from the document s...
auto GetViewName() -> LPCTSTR override
put in resource
auto Create() -> bool override
< String-aware overload
static LPCTSTR StaticName()
Returns "Edit View", the descriptive name of the class for the ViewSelect menu.
auto CanClose() -> bool override
Returns a nonzero value if the view can be closed.
bool VnIsDirty()
Returns a nonzero value if changes made to the data in the view have not been saved to the document; ...
void SetOrigin(long origin)
Sets the position of the stream buffer that the edit buffer is stored.
auto GetWindow() -> TWindow *override
Overrides TView::GetWindow and returns this as a TWindow.
bool LoadData()
Reads the view from the stream and closes the file.
bool VnIsWindow(HWND hWnd)
Returns a nonzero value if the window's handle passed in hWnd is the same as that of the view's displ...
virtual bool SetDocTitle(LPCTSTR docname, int index)
Stores the document title.
friend class TDocument
needs access to NextView
TView(TDocument &doc)
Constructs a TView object of the document associated with the view.
virtual LPCTSTR GetViewName()=0
Pure virtual function that returns 0.
virtual TWindow * GetWindow()
Returns the TWindow instance associated with the view, or 0 if no view exists.
TWindow, derived from TEventHandler and TStreamableBase, provides window-specific behavior and encaps...
virtual bool SetDocTitle(LPCTSTR docname, int index)
Default behavior for updating document title is to pass it to parent frame.
virtual bool CanClose()
Use this function to determine if it is okay to close a window.
Definition of class TDocManager.
Definition of class TEditSearch, an edit control that responds to Find, Replace and FindNext menu com...
#define DECLARE_STREAMABLE_OWL(cls, ver)
#define DECLARE_STREAMABLE_INLINES(cls)
TEditSearch(TWindow *parent=nullptr, int id=0, LPCTSTR text=nullptr, int x=0, int y=0, int w=0, int h=0, TModule *module=nullptr)
Constructs a TEditSearch object given the parent window, resource ID, and character string (text).
bool IsModified() const
Returns true if the user has changed the text in the edit control.
Object Windows Library (OWLNext Core).