VIDE Quick Start Guide
VIDE 1.21 - 28Feb2001
VIDE User Guide
This document is intended to get you started using VIDE as
quickly as possible with your compiler. However, we strongly
recommend that you read the full VIDE
User Guide to get a complete overview of VIDE's capabilities.
If you are seeing this as a result of running the VIDE
installation program, you can now click in the install
window, and finish the installation. This will remain after
the install is complete.
VIDE for Windows with gcc (MinGW/Cygnus)
Installing VIDE for Windows with gcc
top
- Install the compiler
Your first task is to be sure your compiler has been correctly
installed. A good test is to run a Command Window
(Usually Start->Programs->MS-DOS Prompt),
and then enter the command "gcc -v" to display the
version message from the compiler. This should work for
both MinGW and Cygwin versions of gcc. If you don't see
the gcc version message, then you most likely need to add
the gcc directory to your environment path.
- Install VIDE executable
After you download VIDE, install it onto your system. It is
best to install VIDE to the default directory (/Program Files/vide).
The installation will create an entry on the Windows Start menu, but
you may also want to create a desktop icon for VIDE.
- Set environment PATH
In order to use the tools that come with VIDE (e.g., ctags),
the directory you installed VIDE to needs to be on your environment
PATH. (Your compiler must also be included in the PATH.) To
do this on Windows 98, you must edit the file C:\AUTOEXEC.BAT.
You should find a line in it that begins with "PATH=". If you've
installed VIDE in the default location, you can add
"C:\PROGRA~1\VIDE" to the path (note the "PROGRA~1" instead
of "PROGRAM FILES"), separated from other path directories
by a semicolon. On NT and 2000, you use the system settings menu
off the Start menu to change the PATH in the environment.
- Set VIDE options
VIDE has several options that you might want to set to make it
work best for you. Most options are found from the "Options" menu
after you start VIDE.
- The default values from Options->VIDE dialog are generally fine
for gcc.
- You can use Options-> to set various attributes for the editor,
including command set, indentation, and syntax coloring.
- The Options->Font menu allows you to set the monospaced font
of your choice. If you ever find that the cursor in VIDE does
not work properly, it usually means you've re-installed VIDE or
altered the font set on your machine. Simply reselect your font if
this ever happens.
- You can make VIDE the default editor for your
source files by using the Windows command:
Start->Settings->Folder Options->File Types
dialog to associate your source file types (e.g., .c, .h, .cpp) with VIDE.
Your First Project for Windows with gcc
top
VIDE can be used simply as an editor to edit any text
file such as a C++ program or an HTML file. Simply
use the File menu to open a file of your choice.
For a programming project, however, VIDE lets you
create a project that makes working with your program
much easier. The following steps describe how to create
a project, and then how to compile your program.
VIDE has been designed to use the standard tools that
come with your compiler. Before compiling your program,
VIDE will use the project options you've set to generate
a Makefile to be used with the standard gnu make program.
VIDE then runs make to compile your project. For most
cases, you won't need to know the details of how VIDE
generates the makefile.
Create a New Project
The first step is to create a new project by using the
Project->New C++ Project menu command. You will
be prompted for the name of your project. Generally, you
will create your project file in the same directory that
contains your source code.
Once you have selected the project name, you will see a
dialog that lets you define important characteristics of
your project. The options you set in this dialog determine
some important default options used to generate the Makefile.
First, select if you are generating a C or C++ program.
You can mix C and C++, but you would have a C++ project.
Fill in the Target name box. This is the name of the
executable or library file you want to create, including
an appropriate extension (such as .exe).
Next, select the type of application you are building.
Your choices include a "Console Application", which is
one that does not use the Windows GUI API, such as the
standard "Hello, World" app. If you are going to build
a Windows GUI application, select "GUI Application".
This allows you to use the standard Win32 API. Note
that gcc does not include any advanced GUI libraries
such as MFC. If you are using the V GUI library or
OpenGL, check the appropriate box.
Your other options in the New Project dialog box include
if you want to generate a Release version or a Debug
version. (VIDE does not include an automatic option for switching
back and forth between Release and Debug. You can either
create two projects, or manually change the compiler switch
from -g to -O.) Finally, select the compiler. MinGW will
be the default. You also have an option to select the Cygnus
compiler, and to use the -no_cygwin switch.
Use Project Editor to Add Files
After you've made the appropriate selections in the New
Project dialog, the new project will be opened in the
Project Editor. This lets you edit all the properties of
your project. You can come back to the Project Editor at
any time from the Project->Edit menu.
Typically, the first thing you should do is add the source
files included in your project. Select the Files tab
of the Project Editor, and add all the source files
used by your project. (You only add the C/C++ source files,
and not the .h header files.) If your GUI project has any
resource files (.rc), include them, too.
If you don't yet have a source file, you can skip this step
for now, and come back later to add them by re-opening
the Project Editor with the Project->Edit command.
Set Paths
If your project uses any libraries or include files that
aren't on the standard compiler search path, pick the
Paths tab to add these paths. Any paths you include from
this dialog will be added to the makefile. You can also
keep your source, object, and executable files in different
directories if you want, although that is usually not
necessary. It is easiest to keep your project and program
files in the same directory, usually the current directory (.).
Set Defines
If you need to pass any defines to the compiler, pick
the Defines tab. First, add defines to the pool list
(in the form -DFOO or -UFIE), then add those to the
active list. Many programs will not need to use
this feature.
Add Libraries
If you program uses any non-standard libraries
(most of the Windows API libraries are automatically
included by gcc), select the Files tab and add
them to the Linker Flags box. For example, you
could use the common controls library by
adding "-lcomctl32" to the Linker Flags line.
If you get a lot of undefined symbols when you
compile your program, it is likely that you
need to include some library on this line. It
is up to you to understand which libraries your
program needs.
Set Compiler Options
Many programs will compile and run correctly using
the default compiler settings. However, the compiler
has many options that you may want to or need to use.
Add any switches the compiler needs to the Compiler
line of the Files tab dialog.
Close the Project Editor
Once you've add all the source files, and set up
whatever other options you need to, close the
Project Editor. You can edit the Project later from
the Project->Edit tab. When you next
run VIDE, you will need to re-open your project
using the Project->Open command.
Edit your files
After you have created your project, you can
use the VIDE editor to edit any of them as needed.
Build your project
Once you've defined your project and have all the
source files edited and added to the project, you
can compile your program. You can use the "build"
button on the tool bar, or select an option from
the Build menu. Remember that VIDE generates
a standard gnu makefile, and runs gnu make to do
the actual building of your project.
The results of the build are shown in the VIDE
message window. If there are syntax errors in
your source files, you can simply right click
on the error message with the line number to
open that file and go directly to that line.
Fix your syntax error, and try to build again.
At this point, you've now used the basic features
of VIDE. You can read about other VIDE features,
such as using the debugger, in the
VIDE User Guide.
VIDE for Windows with Borland BCC 5.5
Installing VIDE for Windows with Borland BCC
top
VIDE is by default setup to work with the gcc compiler.
For it to work correctly with the Borland BCC compiler, it
is essential that you have set up VIDE for BCC as described
in the following steps. If you don't follow these steps, you
won't be able to successfully compile programs from within VIDE.
- Install the compiler
Your first task is to be sure your compiler has been correctly
installed. A good test is to run a Command Window
(Usually Start->Programs->MS-DOS Prompt),
and then enter the command "bcc32" to display the
help message from the Borland compiler. If you don't see the BCC
help message, then you most likely need to add the BCC bin
directory to your environment path. It is also very important
that you've properly created the .cfg files for the
compiler and the linker. More details about installing BCC
can be found in the full VIDE Borland
help file. That file has some very useful information about
BCC 5.5 that is not clearly explained in the standard BCC 5.5 documents,
so you should be sure to read it carefully.
- Install VIDE executable
After you download VIDE, install it onto your system. It is
best to install VIDE to the default directory (/Program Files/vide).
The installation will create an entry on the Windows Start menu, but
you may also want to create a desktop icon for VIDE.
- Set environment PATH
In order to use the tools that come with VIDE (e.g., ctags),
the directory you installed VIDE to needs to be on your environment
PATH. (Your compiler must also be included in the PATH.) To
do this on Windows 98, you must edit the file C:\AUTOEXEC.BAT.
You should find a line in it that begins with "PATH=". If you've
installed VIDE in the default location, you can add
"C:\PROGRA~1\VIDE" to the path (note the "PROGRA~1" instead
of "PROGRAM FILES"), separated from other path directories
by a semicolon. On NT and 2000, you use the system settings menu
off the Start menu to change the PATH in the environment.
- Set VIDE options
It is essential that you properly set some VIDE options
to make it work correctly with the Borland compiler.
Most options are found from the "Options" menu after you start VIDE.
After you set these options, you must exit from VIDE and
then run it again in order for them to take effect.
- The dialog opened from the Options->VIDE menu contains
the most critical options you must set. First, check the radio
button to select "Borland" as the compiler. Then fill in the
"Compiler root" box with the path to the Borland root directory.
If you installed the Borland compiler to the default location,
this will be "C:\borland\bcc55" (without the final \bin!). Finally,
set the debugger to "td32".
- You can use Options-> to set various attributes for the editor,
including command set, indentation, and syntax coloring.
- The Options->Font menu allows you to set the monospaced font
of your choice. If you ever find that the cursor in VIDE does
not work properly, it usually means you've re-installed VIDE or
altered the font set on your machine. Simply reselect your font if
this ever happens.
- You can make VIDE the default editor for your
source files by using the Windows command:
Start->Settings->Folder Options->File Types
dialog to associate your source file types (e.g., .c, .h, .cpp) with VIDE.
Your First Project for Windows with Borland BCC
top
VIDE can be used simply as an editor to edit any text
file such as a C++ program or an HTML file. Simply
use the File menu to open a file of your choice.
For a programming project, however, VIDE lets you
create a project that makes working with your program
much easier. The following steps describe how to create
a project, and then how to compile your program.
VIDE has been designed to use the standard tools that
come with the Borland compiler. Before compiling your program,
VIDE will use the project options you've set to generate
a Makefile to be used with the standard Borland make program.
VIDE then runs Borland make to build your project. For most
cases, you won't need to know the details of how VIDE
generates the makefile. The makefile generated by VIDE
does use separate runs of BCC32 and ILINK32 which is
different than using BCC32 alone from a command prompt.
Create a New Project
The first step is to create a new project by using the
Project->New C++ Project menu command. You will
be prompted for the name of your project. Generally, you
will create your project file in the same directory that
contains your source code.
Once you have selected the project name, you will see a
dialog that lets you define important characteristics of
your project. The options you set in this dialog determine
some important default options used to generate the Makefile.
First, select if you are generating a C or C++ program.
You can mix C and C++, but you would have a C++ project.
Fill in the Target name box. This is the name of the
executable or library file you want to create, including
an appropriate extension (such as .exe).
Next, select the type of application you are building.
Your choices include a "Console Application", which is
one that does not use the Windows GUI API, such as the
standard "Hello, World" app. If you are going to build
a Windows GUI application, select "GUI Application".
This allows you to use the standard Win32 API. Note
that the free Borland compiler does not include any advanced GUI
libraries such as MFC. If you are using the V GUI library or
OpenGL, check the appropriate box.
Your other options in the New Project dialog box include
if you want to generate a Release version or a Debug
version. (VIDE does not include an automatic option for switching
back and forth between Release and Debug. You can either
create two projects, or manually change the compiler switch
from -v- to -v.) Finally, select the compiler. If you have
properly installed VIDE for the Borland compiler, Borland
will be the default. If Borland is not checked, please
go over the installation instructions again.
Use Project Editor to Add Files
After you've made the appropriate selections in the New
Project dialog, the new project will be opened in the
Project Editor. This lets you edit all the properties of
your project. You can come back to the Project Editor at
any time from the Project->Edit menu.
Typically, the first thing you should do is add the source
files included in your project. Select the Files tab
of the Project Editor, and add all the source files
used by your project. (You only add the C/C++ source files,
and not the .h header files.) If your GUI project has any
resource files (.rc), include them, too.
If you don't yet have a source file, you can skip this step
for now, and come back later to add them by re-opening
the Project Editor with the Project->Edit command.
Set Paths
If your project uses any libraries or include files that
aren't on the standard compiler search path, pick the
Paths tab to add these paths. Any paths you include from
this dialog will be added to the makefile. You can also
keep your source, object, and executable files in different
directories if you want, although that is usually not
necessary. It is easiest to keep your project and program
files in the same directory, usually the current directory (.).
Note that VIDE will automatically include the paths to
the Borland compiler directory. These values will
override any you might have set in the Borland .cfg files,
but are the standard values you will usually need.
Set Defines
If you need to pass any defines to the compiler, pick
the Defines tab. First, add defines to the pool list
(in the form -DFOO or -UFIE), then add those to the
active list. Many programs will not need to use
this feature. VIDE automatically includes the
definitions needed to build executables compatible
with Windows 9x, NT, and 2000. If you want Windows
2000 compatible executables, you will need to change
the default definitions.
Add Libraries
If you program uses any non-standard libraries, select the Files
tab and add them to the Linker Flags box. (This line will already
have some libraries specified.) For example, you could use the
common controls library by adding "-lcomctl32" to the Linker
Flags line. If you get a lot of undefined symbols when you
compile your program, it is likely that you need to include some
library on this line. It is up to you to understand which
libraries your program needs.
Set Compiler Options
Many programs will compile and run correctly using
the default compiler settings. However, the compiler
has many options that you may want to or need to use.
Add any switches the compiler needs to the Compiler
line of the Files tab dialog. See Borland's documentation
(or the VIDE Borland reference) for
details of these switches.
Select the Runtime library
Your program requires a runtime library to run.
The Borland compiler offers you several choices for
the runtime library you use. By default, VIDE
will use the appropriate static runtime libraries
for a console or GUI app (which is the
same as the default the BCC32 command line
interface uses). If you want to use
the Borland DLL versions, you can select the
Advanced tab to change these. More details can
be found in the VIDE Borland reference.
Close the Project Editor
Once you've add all the source files, and set up
whatever other options you need to, close the
Project Editor. You can edit the Project later from
the Project->Edit tab. When you next
run VIDE, you will need to re-open your project
using the Project->Open command.
Edit your files
After you have created your project, you can
use the VIDE editor to edit any of them as needed.
Build your project
Once you've defined your project and have all the
source files edited and added to the project, you
can compile your program. You can use the "build"
button on the tool bar, or select an option from
the Build menu. Remember that VIDE generates
a standard Borland makefile, and runs Borland make to do
the actual building of your project.
The results of the build are shown in the VIDE
message window. If there are syntax errors in
your source files, you can simply right click
on the error message with the line number to
open that file and go directly to that line.
Fix your syntax error, and try to build again.
At this point, you've now used the basic features
of VIDE. You can read about other VIDE features,
such as using the debugger, in the
VIDE User Guide.
VIDE for Linux with gcc
Installing VIDE for Linux with gcc
top
Your First Project for Linux with gcc
top
VIDE can be used simply as an editor to edit any text
file such as a C++ program or an HTML file. Simply
use the File menu to open a file of your choice.
For a programming project, however, VIDE lets you
create a project that makes working with your program
much easier. The following steps describe how to create
a project, and then how to compile your program.
VIDE has been designed to use the standard tools that
come with your compiler. Before compiling your program,
VIDE will use the project options you've set to generate
a Makefile to be used with the standard gnu make program.
VIDE then runs make to compile your project. For most
cases, you won't need to know the details of how VIDE
generates the makefile.
Create a New Project
The first step is to create a new project by using the
Project->New C++ Project menu command. You will
be prompted for the name of your project. Generally, you
will create your project file in the same directory that
contains your source code.
Once you have selected the project name, you will see a
dialog that lets you define important characteristics of
your project. The options you set in this dialog determine
some important default options used to generate the Makefile.
First, select if you are generating a C or C++ program.
You can mix C and C++, but you would have a C++ project.
Fill in the Target name box. This is the name of the
executable or library file you want to create, including
an appropriate extension (such as .a).
The current version of VIDE only provides automatic support
for V GUI projects. If you are using the Athena or Open Motif
version of V, then select one of the two. If you select one of
these two, then the Linker flag box will be filled in with
appropriate options. Otherwise, you will find the
Linker Flags box empty. It is up to you to fill in the appropriate
switches for the library you are going to use.
Note that the X version of VIDE and V assume the use of the new, free
version of Open Motif. Since this is a free, or nearly free
version, of Motif, V and VIDE will no longer be tested with
LessTif or commercial Motif versions. In fact, the Open Motif
version seems to work wonderfully with V - the best Motif version
ever. And it even gets the default decoration colors right under
Gnome!
Your other options in the New Project dialog box include
if you want to generate a Release version or a Debug
version. (VIDE does not include an automatic option for switching
back and forth between Release and Debug. You can either
create two projects, or manually change the compiler switch
from -g to -O.)
Use Project Editor to Add Files
After you've made the appropriate selections in the New
Project dialog, the new project will be opened in the
Project Editor. This lets you edit all the properties of
your project. You can come back to the Project Editor at
any time from the Project->Edit menu.
Typically, the first thing you should do is add the source
files included in your project. Select the Files tab
of the Project Editor, and add all the source files
used by your project. (You only add the C/C++ source files,
and not the .h header files.)
If you don't yet have a source file, you can skip this step
for now, and come back later to add them by re-opening
the Project Editor with the Project->Edit command.
Set Paths
If your project uses any libraries or include files that
aren't on the standard compiler search path, pick the
Paths tab to add these paths. This might include the
path to whatever X library you are using (Motif, Athena,
gtk, etc.). Any paths you include from this dialog will be added
to the makefile. You can also keep your source, object, and
executable files in different directories if you want, although
that is usually not necessary. It is easiest to keep your project
and program files in the same directory, usually the current
directory (.).
Set Defines
If you need to pass any defines to the compiler, pick
the Defines tab. First, add defines to the pool list
(in the form -DFOO or -UFIE), then add those to the
active list. Many programs will not need to use
this feature.
Add Libraries
If you program uses any non-standard (non-C runtime) libraries
(such as your X GUI library), select the Files tab and add them
to the Linker Flags box. For example, you could use the Motif
library by adding "-lXm" to the Linker Flags line.
(Using Motif usually requires several other libraries as
well. Consult the documentation for whatever X library
you are using.) If you get a lot of undefined symbols when you
compile your program, it is likely that you need to include some
library on this line. It is up to you to understand which
libraries your program needs.
Set Compiler Options
Many programs will compile and run correctly using
the default compiler settings. However, the compiler
has many options that you may want to or need to use.
Add any switches the compiler needs to the Compiler
line of the Files tab dialog.
Close the Project Editor
Once you've add all the source files, and set up
whatever other options you need to, close the
Project Editor. You can edit the Project later from
the Project->Edit tab. When you next
run VIDE, you will need to re-open your project
using the Project->Open command.
Edit your files
After you have created your project, you can
use the VIDE editor to edit any of them as needed.
Build your project
Once you've defined your project and have all the source files
edited and added to the project, you can compile your program.
You can use the "build" button on the tool bar, or select an
option from the Build menu. Remember that VIDE generates a
standard gnu makefile, and runs gnu make to do the actual
building of your project.
The results of the build are shown in the VIDE message window. If
there are syntax errors in your source files, you can simply
right click on the error message with the line number to open
that file and go directly to that line. Fix your syntax error,
and try to build again.
At this point, you've now used the basic features of VIDE. You
can read about other VIDE features, such as using the debugger,
in the VIDE User Guide.
Installing VIDE for Sun Java (JDK)
top
Please see the complete
VIDE Java tutorial.
No Warranty top
This program is provided on an "as is" basis, without warranty of
any kind. The entire risk as to the quality and performance of
the program is borne by you.
VIDE Reference Manual
Copyright © 1999-2000, Bruce E. Wampler
All rights reserved.
Bruce E. Wampler, Ph.D.
bruce@objectcentral.com
www.objectcentral.com