[Home]
[Contents]
[Prev]
[Next]
Workspaces, which are among the IDDE's most useful features, are window configurations used for particular tasks. To create a workspace, you name and save the exact arrangement of windows on your screen. Any time you need to perform a similar task, you can instantly open that workspace, with the windows organized the way you want them. For more information on workspaces, refer to More about Projects and Workspaces.
Projects speed development time because they let you recompile only the source files that have changed, or whose header files have changed, since the last time the project was built. For example, if your program has five source files and you have changed one of them since the last build, only that file is recompiled when you build the project. (You can, however, choose to recompile all the files.) The project management system does this by automatically analyzing the dependencies of the source files and constructing or updating the makefile each time the project is built.
The IDDE stores information about a project on disk as a project file with a .prj extension. Among other information, this file includes a list of the source files contained in a project. When you build the project, the IDDE constructs a makefile (.mak)— or updates the existing makefile— based on the files the project contains. Project options are stored in an option set file (.opn) that is referenced in the project file. The option set file can be loaded into another project, making it easy to transfer all option settings from one project to another.
[Figure 3-1 ProjectExpress Project Name page]
Select the directory in which you want to create the project from the Directories listbox, or click on New Directory to make a new directory for this project. Enter the name of the new project in the Project Name textbox.
If you select Use AppExpress to create new application, then click on Finish, AppExpress will start. AppExpress is discussed in Generating an Application Framework.
[Figure 3-2 ProjectExpress Project Type page]
After the project is created, you can modify these settings by choosing Settings from the Project menu. These options are discussed in more detail in More about Projects and Workspaces.
[Figure 3-3 ProjectExpress Project Edit page]
If you are creating a new project, you do not need to do anything on this page. After the project is created, you can open a similar dialog box by choosing Edit from the Project menu (see the section "Adding and deleting project files" later in this chapter).
[Figure 3-4 ProjectExpress Initial Settings page]
To define a macro on the compiler command line, enter the macro in the Defines textbox (for example, COLOR=1). Separate multiple macro definitions with semicolons. Type any #include file search paths you want on the compiler command line in the Include Directories textbox. Type any directories to be excluded from parsing in the Browser Exclude Directories textbox. (For more information about parsing, see Defining Classes and Their Hierarchies.
In general, you can leave these fields blank. You may change these options later by choosing Settings from the Project menu.
After the project is set up the way you want, click on Finish to create the new project.
IDDE lets you work with only one project at a time. If you're already working with a project when you open a new one, the IDDE closes the project in process.
An additional method for opening existing projects is to choose one from the list of projects at the bottom of the Project menu. Projects are added to this menu as they're opened or created. This makes it easier for you to switch back and forth between projects as you work.
[Figure 3-5 Edit Project dialog box]
The Project Files listbox contains the files in your project.
After you click OK, the IDDE checks your project for dependencies and creates a makefile. While checking for dependencies, the IDDE adds the additional files it needs to build your project. For example, it adds all the header files that your source files reference with the #include directive.
[Figure 3-6 Project window]
You can double-click on the name of a source file in the right pane to open that file for editing in a Source window. (See Editing Program Code, for a description of text editing functions.)
You can see the current project's subprojects, or open a subproject, by double-clicking on the project name in the left pane.
The icon to the left of each filename indicates certain properties of the file. If the icon is blue, the file was explicitly added to the project; if the icon is gray, the file is included in the project by a dependency relationship or by parsing.
The icon next to each filename contains different information during debugging. An asterisk indicates that the module contains debug information. A "T" at the right of the icon indicates that tracing is enabled in the module. Dots indicate that the module contains breakpoints: a green dot indicates enabled breakpoints, and a red dot indicates disabled breakpoints.
First, choose Open from the Project menu. In the "List files of type" listbox, choose Import Make. When you open a Microsoft or Borland makefile, the IDDE lets you work with it as you would a Digital Mars C++ project.
To build the project with the original Microsoft or Borland makefile, use the Make page under the Build tab in the Project Settings dialog box (see More about Project Build Settings) to call the original makefile or batch file.
[Figure 3-7 Workspace toolbox]