=========================================================================== ObjectWindows for C++ =========================================================================== This file contains important information about ObjectWindows for C++, an application framework that will ease the development of applications for Windows. For the latest information about ObjectWindows for C++, the accompanying example programs, and documentation, read this entire file. Note There are many changes and enhancements to ObjectWindows in this release, to better support Windows 3.1. For more details, see OWL31.DOC. Features ======================================================= ObjectWindows for C++ includes the following important features: ------------------ DDVTs provide a simple alternative to the traditional Dynamic Dispatch method of writing a window procedure to responding to Virtual Tables Windows messages. Typically, a window procedure (DDVTs) consists of a lengthy switch statement with a case for ------------------ every Windows message to which you require a response. By using DDVTs, you respond to a Windows message by writing a member function of the C++ class associated with your window. Using DDVTs, your derived classes will not be encumbered with virtual table entries for all windows messages handled by the derived class and all base classes. DDVTs encode only the changed virtual member functions to keep virtual tables small. ------------------ ObjectWindows includes support for streamable Support for (persistent) objects. The stream manager lets you save streamable objects objects either in memory or file streams so that they ------------------ persist beyond their normal lifespan. ------------------ The Borland Windows Custom Control Library (BWCC.DLL) Borland custom provided with this release allows you to build your own controls Windows programs using the fancy dialog boxes and ------------------ controls provided with such Borland Windows products as the Resource Workshop, Turbo Pascal for Windows, Turbo C++ for Windows, and Borland C++ for Windows. ------------------ ObjectWindows provides the ability to produce your own Dynamic-link ObjectWindows DLLs and use classes and functions from libraries (DLLs) these DLLs in your ObjectWindows applications. ------------------ In addition to OWL31.DLL, this version includes dynamic link library versions of BWCC (Borland Windows Custom Controls), and BC30RTL (the Borland C++ run-time libraries within a DLL). More information on these appears below. ------------------ We provide Help files containing reference information Online Help on the ObjectWindows and Streamable classes. The Help ------------------ files are provided in two formats: one that is compatible with THELP and the DOS IDE and one that is compatible with the Windows Help engine (WINHELP). ------------------ To significantly improve the performance of dynamic Global heap heap allocations under Windows, the BC RTL provides new suballocation versions of the farmalloc, farfree, farrealloc, and ------------------ farcalloc functions which suballocate Windows global heap blocks. To take advantage of these functions, you need only use 'new' and 'delete' as usual. Important ======================================================= information ------------------ The User's Guide includes a step-by-step tutorial that ObjectWindows quickly introduces readers to many of the important User's Guide features of ObjectWindows and gets them off to a good ------------------ start in ObjectWindows programming. In OWL\DOC, you will also find a file, OWLDLL.DOC, that contains a new chapter on using and building dynamic link libraries. The BWCC-OWL.DOC file in OWL\DOC, and BWCCAPI.RW and BWCCSTYL.RW files in BORLANDC\DOC contain information on using the Borland Custom Controls with ObjectWindows. If you have any questions that are not answered in the manuals, check out this file and the HELPME!.DOC file, which discuss questions and problems that ObjectWindows programmers may encounter. ------------------ The Borland Windows Custom Control Library (BWCC.DLL) Borland custom is provided with this release, along with its import controls library (BWCC.LIB). To use BWCC, you must specify the ------------------ Windows class name of any control you want to use in your resource files. Whether you use BWCC from an ObjectWindows program or not, you will have to ensure that BWCC.DLL is dynamically loaded along with your program. The suggested way to do this is to update your program to make a call to BWCCGetVersion (defined in BORLANDC\INCLUDE\BWCC.H) from somewhere within your program. This will cause an imported reference to BWCC.DLL which will, in turn, cause the Windows loader to load BWCC.DLL along with your program (if it is not already loaded). The CHECKERS and TTT (TicTacToe) games in the OWL\EXAMPLES directory use the Borland Windows Custom Controls. See the files BWCC-OWL.DOC in the OWL\DOC subdirectory and BWCCAPI.RW and BWCCSTYL.RW files in BORLANDC\DOC for more information on using the Borland Custom Controls. ------------------ If you use DLLs, remember that they must be located in DLL support a directory in your path (eg, C:\BORLANDC\BIN or ------------------ C:\WINDOWS) or in the directory of the .EXE which invokes them. By default, the INSTALL program will place OWL31.DLL, BC30RTL.DLL, and TCLASS31.DLL in your BORLANDC\BIN directory and BWCC.DLL in your WINDOWS\SYSTEM directory. If you want to build the example programs to use the statically linked libraries rather than OWL31.DLL (the default for the makefile in OWL\EXAMPLES), you should define the USESTATIC macro on the make command line: make -DUSESTATIC If you are using OWL31.DLL, or any ObjectWindows DLL that you have built, you must use large model for both the DLLs and the EXEs that use them. Also, if you link your program to you use OWL31.DLL, then it should also be linked to use BC30RTL.DLL and TCLASS31.DLL; CRTLDLL.LIB and TCLASDLL.LIB are their import libraries. If you want to build your own DLLs with ObjectWindows, we recommend that you check out the USECDLL and CALLDLL example programs. The USECDLL example program demonstrates the use of a cooperating ObjectWindows EXE and DLL using an object interface (that is, shared classes). The CALLDLL example program shows an ObjectWindows EXE making a call into an ObjectWindows DLL using a functional interface. The USECDLL2 shows a non-OWL EXE calling into an ObjectWindows DLL. If you want to define your own shared classes, define the _CLASSDLL macro in the Defines text box of the Options|Compiler|Code Generation dialog box or on the compiler command line to signify that the module being compiled will use classes in a DLL or will pass classes into a DLL. Other macros, notably _CLASSTYPE, _EXPORT, and _FAR, will check to see if _CLASSDLL has been defined. Use the _EXPORT macro (defined in OWL\INCLUDE\OWLDEFS.H) in the definitions of your shared classes. It will expand into either '_CLASSTYPE' (when compiling an .EXE file) or '_export' (when compiling a .DLL module). Typical usage might be: _CLASSDEF(TMyClass) class _EXPORT TMyClass { // whatever... }; The _CLASSTYPE macro (defined in BORLANDC\INCLUDE\_DEFS.H) expands into either "huge", "far", or "near" as appropriate. If the __...
mek4test