TE Edit Control Win32 / Win64 Help
Product page

TTerView Class Interface

The TTerView class interface is provide by the TER_OWLV.H and TER_OWLV.CPP files. These files are included in the OWL.ZIP (OWL32.ZIP for Win32) file. These files are available from our FTP site: ftp.subsystems.com. The OWL.ZIP file also includes a demo program which utilizes this class. Your application module that uses the TTerView class object should include the TER_OWLV.H file. Your application project should include the TER_OWLV.CPP and TER.LIB (ter30BC.LIB for Win32) files. Also the ter32.dll and txml2.dll files must be available in the current directory or a directory included in the path statement.

TTerView is a class derived from the TView and TWindow classes provided by Borland's OWL library. Your application's view class should be derived from the TTerView class.

The TTerView class provides functions to invoke the editor menu commands. The editor command ids are included in the TER_CMD.H file. Another file, TER_OWLV.RCH, includes the ids to create the menu items in the Borland resource workshop. The TTerView class also provides the serialization functions.

Other than invoking menu commands, your application uses the DLL functions described in the 'Application Interface Functions' to communicate with the editor.

Class Member Function Description

CTerView:

Initialize internal variables.

CTerView();

EditStyles:

Returns the editor attribute bits.

WORD EditStyles();

Remarks: This function is called by the 'TTerView::PerformCreate' function to modify the editor window style bits. By default, the function returns TER_WORD_WRAP, TER_VSCROLL, and TER_BORDER_MARGIN styles. You can override this function to provide other styles. Please refer to the 'Create Window' section in the 'Getting Started' chapter for a list of control style constants.

MenuEnable:

Returns TRUE if a menu item should be enabled.

BOOL MenuEnable(MenuItem);

int MenuItem: // menu item number to test. The MenuItem can be one of the constants defined in the TER_CMD.H file.

Return Value: This function returns TRUE if the menu option is to be enabled.

MenuSelect:

Returns TRUE if a menu item should be checked.

BOOL MenuSelect(MenuItem);

int MenuItem: // menu item number to test. The MenuItem can be one of the constants defined in the TER_CMD.H file.

Return Value: This function returns TRUE if the menu option is to be checked.

TerMenu:

Execute an editor menu command.

void TerMenu(MenuItem)

int MenuItem: // menu item number to test. The MenuItem can be one of the constants defined in the TER_CMD.H file.