			Visual Turbo Vision
			 Demo Version 1.32 

Note: This is not realy a demo , it is a subset of the VTV program.
This demo lets you build MenuBar and generate the corresponding sources.


Thank you for trying C.L.I.B. Visual Turbo Vision Demo Version.  
it was specifically designed for users of Borland's 
Turbo Vision  library 1.03 & 2.0.  If you find VTV useful,
we hope that you take advantage of the full VTV, 
which gererate all the source code of the application .

Initialy VTV was written in french , and we are working 
to release an english version in the near futur.
We would be happy to hear from you if you have any 
problem with or would like any other features added or any suggest for documentation.

C.L.I.B
Conception Logiciels International B 
11, Rue Gambetta
42 000  Saint Etienne 
FRANCE
Phone: ( 33 ) 77 33 55 92
Fax: ( 33 ) 77 34 06 72
CIS, ID: 75511,2117


Introduction
------------

Visual Turbo Vision is a case for developping Turbo Vision interfaces.
As easy as clicking mouse buttons you will build with all the part of your application.

Visual Turbo Vision is constituted with the following components:
	- MenuBar editor:
	Lets you  design menubar.
 
	- StatusLine editor:
	Lets you design StatusLine.

	- deskTop editor:
	Lets you paint you background as you want.

	- dialog Box editor:
	You can include in dialogs:
		- backgrounds 
		- buttons
		- check boxes
		- radio buttons
		- input lines
		- labels
		- list boxes
		- vertical & horizontal scrollers
		- static texts

	- Event command handler:
	Lets you define links between commands - dialog boxes, to simulate the future execution of  your                application.
	- destination editor:
	Lets you build new classes and specify  resource name, source and headers files  names.

	- Resource editor:
	Lets  you save or retrieve a design

	- Project editor:
	Lets you define some specific project item.

	- Id Command and Id Help Context Editor:
	Lets you keep coherent all your commands and Help Context values for the application you are building.

System Requirement
------------------

   - Borland C++ ver 3.1 or above with 
   - Borland Turbo Vision for C++ ver 1.03 or above
   - 386 based computer
   - a mouse

Three action to make it work:
-----------------------------

	- right mouse  button double click for editing the instance.
	- right mouse button down  for moving. 
	- shift keyboard pressed and right mouse button down  for resizing .


Note: the term 'Actions' is  about boutons and 'Fields' about input line or list box associated with input line.
	
	


The Application dialog box
--------------------------

Building your application starts here.

	Actions:        
	--------
	Menu Bar : Lets you access the Menu Bar dialog box.     
	About : Lets you access the About dialog box    
	Close : Terminate the application. Note that there isn't any warning for saving design.

The Menu Bar dialog box 
-----------------------

This dialog box lets you create menubars. 
While designing an application you can have multiple menubars 
on the desk put when you want to generate the entire application  sources ,
only the one linked to the TApplication::menubar data member 
will be generated, but you can generate the source for 
each one individually.

	Actions:
	-------
	Create : Lets you create a menubar, 
	if there is no menubar on the desk 
	a link is performed with the TApplication ::menubar data member, 
	otherwise a message will ask you if you want to modify 
	the actual link.After this the Menu Bar Editor dialog box will appear.

	Options : Access to the Menu Bar Options dialog box

	Close : Close the dialog box.


The Menu Bar Editor dialog box
-------------------------------
It lets you edit the menubar . 
Note that some actions are disabled when the menubar is active.

Actions:  
-------
Add Item : Lets you add an instance of TMenuItem with a command 
different from 0. The command 0 is used to create submenus and lines.

Add Sub Menu: Add a sub menu .

Add Line :  Add a line to seperate items.

Delete :  Delete the highlighted item ( menuitem or submenu ).

Delete Line : Delete the line located after the actual highlighted item.

Delete MenuBar : Delete the menuBar. 
Note that a menubar linked to the TApplication::menuBar member 
can't be deleted , you have first to unlink it. 
see the Menu Bar Options dialog box. 
This actions is disabled  while the menu bar is active.

Edit:  Access to the Item dialog box.

>> :  Move the highlighted item.

<< :  Move the highlighted item.

Options :  Access the Menu Bar Options dialog box. 
This action is disabled while menu bar is active.

Close :  Close the dialog box. 
This action is disabled while menu bar is active.



The Item dialog box
-------------------

Lets you edit the menuBar items. 
Depending on the highlighted item some fields and actions can be disabled.

Fields:
-------
Text : Item Text 

Command :  Command number, this field can be affected by the Id Command action.

Key Code :  Key Code associated to the item. 
Just type keyboard to affect it. 
To exit this field use the mouse.

Help Context : Lets you enter the help context number, 
this field can be affected by the Id Help Ctx action..

Param Text:  Used for MenuItem , to perform additional information 
for example desciption of the shortcut, 
It particularity is a right alignment.

Actions:
--------

OK : Confirm the changes and close the dialog box.

Cancel :  Cancel the changes and close the dialog box.

Id Command :  Access the Id Command Editor

Id Help Ctx : Access the Id Help Context Editor



The Menu Bar Options dialog box
-------------------------------

It can be accessed from the MenuBar 
or the Menu Bar Editor dialog box, 
in the first case some actions are disabled.

Actions:
--------
Heap: Show or hide a heapViewer. It can be moved.

Id Command : Access the Id Command Editor.

Id Help Ctx :  Access the Id Help Context Editor.

Link to App : Link or unlink the actual menubar to the TApplication::menuBar 
data member.

Destination : Access to the Destination dialog box. 
Initialy a menubar have the following entries: 
	Class Name : NTMenuBar  
	Resource Name : NTMENU  
	Source Name : NTMENU.CPP
	Include Name : NTMENU.H
Note that in all case the generated menu bar classes 
are descendant from the TMenuBar class.

Source: Generate the source code of the menubar 
according to the specified destinations.

Resources:  Access the Resources dialog box; 
perform save and restore actions of  TPhMenuBar 
instances wich represent menubars of Visual Turbo Vision.

Close: Close the dialog box.



The Destination dialog box
--------------------------
 
Lets you modify the class of actual instance, 
for using the standard classes of Turbo Vision just type 
its name  as writen in the Programmer's Guide of Turbo Vision. 
This latest remark don't apply to all classes.
The extension '.CPP' and '.H' are added to the name typed 
in respectively the fields 'Source Name' and 'Include Name'.

Fields:
------
Class Name : Lets you specify the class name of the instance.

Resource Name : Lets you specify the resource name , 
for saving and restoring the instance.

Source Name :  Lets you specify the file name of the source file.

Include Name :  Lets you specify the file name of the header file.

actions:
--------

OK :  Perform the changes and close the dialog box.

Cancel :  Cancel the changes and close the dialog box.


The Resources dialog box
-------------------------

Lets you save and restore the differents parts of your application.

Fields:
-------
Files : List of  resources files with extension '.PHE'

Resources : List of the resources contained in the selected file.

Resource Name : Name of the resource from wich the dialog box 
have been called. Used  to perform saving action. 
This field can't be modified. See Destination dialog box

Resource Type: Describe the resource type of the Resource Name . 
This field can't be modified.
		Resource Type can have the following text:
			- TPhIdCmds: Resource of Id Command
			- TPhIdHints: Resource of Id Help Context
			- TPhApplication : Resource contening an entire application
			- TPhMenuBar : Resource for MenuBar
			- TPhStatusLine : Resource for StatusLine
			- TPhDialog : Resource for Dialogs

Actions
-------

Open:  Open the selected file or move through directories . 
This action can be performed by double clicking the list file.

Close:  Close the dialog box.

Save: Save the resource from wich the dialog have been 
called with the name contained in the 'Resource Name' field.

Retrieve: Restore the resource wich have been selected in the resource list. 
This action can be performed by double cliking the resource list.

Delete: Delete the selected resource.


The Id Command Editor dialog box
--------------------------------

All Turbo Vision application uses integers  to provide actions.
This dialog box lets you create, edit and choose commands . 

Fields:
-------
Id Command:  The integer value of the command.

Text: Name associated to the Id Command.

Enable : Not used.

Comment:

Actions:
--------
Add Item: Add the item wich have been typed in the fields. 
If an existant item have the same command a message 
will ask you for  overwriting. 
Note that it is not possible to modify the standard 
command of Turbo Vision.

Delete: Delete the highlighted item.

OK:  Close the dialog, and send the command value  
if the dialog have  been called from a dialog editor.

Source: Generate as a  header file the commands.

Destination :  Access the Destination dialog box .

Resources:  Access the Resources dialog box.



The Id Help Context Editotr dialog box
---------------------------------------
 Same as the Id Command Editor dialog box. No need with this version.


About using the Generated source for menu Bar.
---------------------------------------------
---------------------------------------------


The source generated is in two files one called header file (.h) 
and the other the source file (.cpp).

By now we assume that we have generated a new menubar class 
named NTMenuBar that have a header file named 'NTMENU.H' 
and a source file named 'NTMENU.CPP' 
and we have derived a new application 
from the TApplication class named 
NTApplication and its source file is 'NTAPP.CPP'

*********
if you want to link the generated menu in your application:

1- add the source file  ( NTMENU.CPP) to your project file list 
	refer to your compiler to make this operation

2- in the header section, at the top of the file 'NTAPP.CPP'  
add the following declaration to add the header file of the new menubar:

#include "NTMENU.H"

3 - Define the initMenuBar member function like this:

TMenuBar *NTApplication::initMenuBar( TRect r)
{
	return new NTMenuBar( );
}

4- You can now make and run your project. 
Don't worry if some warning appears during compilation process.
you can avoid them just by making the member function between 
#pragma warn -par // disable warning parameter not used
#pragma warn +par // enable warning parameter not used

The new member function will look like:

#pragma warn -par // disable warning parameter not used
TMenuBar *NTApplication::initMenuBar( TRect r)
{
	return new NTMenuBar( );
}
#pragma warn +par // enable warning parameter not used



********
Note if you are using BC4  change all 

#include  <tv.h>
by
#include  <tvision\tv.h>




