The Project Manager Window

TABLE 9.1. THE PROJECT GROUP CONTEXT MENU ITEMS.

Add New Project

Opens the Object Repository so that you can choose a new target. Targets include applications, DLLs, forms, data modules, components, or any other object available from the Object Repository.

Add Existing Project

Opens a project file from disk and adds it to the project group.

Save Project Group

Saves the project group. Project groups have a .bpg extension.

Save Project Group As

Saves the project group with a new name.

View Project Group Source

Displays the project group source. The project group source is a special file (a makefile) that contains references to all projects within the project group.

Toolbar

Toggles the Project Manager toolbar on and off.

Status Bar

Toggles the Project Manager status bar on and off.

Dockable

Specifies whether the Project Manager is dockable.

NOTE: The Toolbar, Status Bar, and Dockable menu items appear on each of the Project Manager context menus. I won't mention them again when I discuss the other Project Manager context menus.

The Project Context Menu

The project context menu is displayed when you right-click a project node in the Project Manager. Table 9.2 lists the context menu items specific to the project context menu.

TABLE 9.2. THE PROJECT CONTEXT MENU ITEMS.

Item

Description

Add

Opens the Add to Project dialog box so that you can add a file to the project. The same as choosing Project|Add to Project from the main menu or from the Delphi toolbar.

Remove File

Opens the Remove From Project dialog box so that you can remove a file from the project. The same as choosing Project|Remove from Project from the main menu or from the Delphi toolbar.

Save

Saves the project. The same as choosing File|Save from the Delphi main menu.

Options

Displays the Project Options dialog box for this project. The same as choosing Project|Options from the Delphi main menu.

Activate

Makes this project the active project.

Compile

Compiles this project. The difference between compile and build was discussed on Day 4.

Build

Builds this project.

View Source

Displays the project source file. The same as choosing Project|View Source from the Delphi main menu.

Close

Closes this project and all its files. If the project is part of a saved project group, the project node icon will be grayed out. The project is still part of the group but is not open in the IDE. If the project is part of the default project group, the project is closed and removed from the default group.

Remove Project

Removes this project from the project group. The project is not deleted from your hard drive, just removed from the project group. Same as clicking the Remove Selected Project button on the Project Manager toolbar.

Build Sooner

Moves the project up in the project tree. Projects are built from the top of the Project Manager down.

Build Later

Moves the project down in the project tree.

NOTE: The Project Manager context menus are even more diverse than represented in this section. The project context menus contain additional items if the project is a Batch File or a Package project. The differences are not significant, so I won't go over those additional menu items.

The Unit Context Menu

The unit context menu is displayed when you right-click a unit node in the Project Manager. Table 9.3 lists the unit context menu items.

TABLE 9.3. THE UNIT CONTEXT MENU ITEMS.

Item

Description

Open

Displays the unit in the Code Editor (for standalone units) or Form Designer (if the unit has an associated form).

Remove From Project removes the unit from the project. The Project Manager does not prompt you to remove the unit and there is no undo for this action. You an always add the unit back to the project if you remove a unit by accident.

Save

Saves the unit. The same as choosing File|Save from the Delphi main menu.

Save As

Opens the Save As dialog box so that you can save the unit with a new name. The same as choosing File|Save As from the Delphi main menu.

The File Context Menu

The file context menu is displayed when you right-click a node other than the project group node, a project node, or a unit node (usually a .pas or .dfm file). This context menu has only one item. The Open menu item displays the selected node in either the Code Editor or the Form Designer, depending on the type of the selected node.

The Project Manager Toolbar and Keyboard Commands

In addition to the Project Manager context menus, the Project Manager has a toolbar to make working with the Project Manager easier. The Project Manager toolbar contains three buttons:

  • The Add New Project button displays the Object Repository so that you can add a new project to the project group. This is the same as clicking the Add New Project menu item from the project context menu.
  • The Remove Selected Project button removes the selected project from the project group. Use this button only to remove an entire project, not to remove a particular form or file from a project.
  • The Activate Selected Project button makes the selected target the active project.

Keyboard commands include the Delete key and the Insert key. When you press Delete, the selected node is removed. If a project node is selected, the project is removed from the project group. If a unit node is selected, the unit is removed from the project to which the unit belongs. The Insert key behaves exactly the same as choosing Add to Project from the project context menu.

TIP: The Project Manager toolbar buttons can be either large or small. By default, the Project Manager toolbar buttons are small. You can change the toolbar button size by dragging the bottom of the toolbar either up (to show the small buttons) or down (to show the large buttons).

Project Management Made Easy

Project Management Made Easy

What you need to know about… Project Management Made Easy! Project management consists of more than just a large building project and can encompass small projects as well. No matter what the size of your project, you need to have some sort of project management. How you manage your project has everything to do with its outcome.

Get My Free Ebook


Post a comment