Microsoft's Visual Studio

Microsoft's Visual Studio

Projects:

A Visual C++ project consists of source code and resources. Data (like bitmaps, etc.) are stored in a resource file using established formats. The linker combines this binary resource file with the C++ compiled output to yield an executable file.

Resources include: bitmaps cursors fonts icons keyboard-accelerator tables (like cntl-C to copy to the clipboard) menu definitions message-table entries dialog box layouts string-table entries version data user-defined data

Resource compiler

An application that creates a binary resource file based on the resourcedefinition file. The resource compiler can also append binary resource data to an executable file and create a resource table in the executable file's header.

resource-definition file (*.rc)

A text file containing descriptions of an application's resources. The resource compiler creates a binary resource file based on the contents of the resource-definition file. Resource-definition files usually have a .RC extension.

resource file (*.res)

A binary file created by the resource compiler that contains an application's resource data. Resource files usually have a .RES extension.

resource object

An object file that consists of the resource file and the resource table. The linker links the resource object to the executable file.

resource table

Data the resource compiler adds to the header of an application's executable file. This data includes the location, name, type, language, and so on, of each resource in the executable file.

Resources:

You can work with resources that were not developed in Visual C++'s development environment or are not part of your current project. For example, you can:

?Work with nested and conditionally included resource files. ?Update existing resources or convert them to Visual C++ format. ?Import or export graphic resources to or from your current resource file. ?Include shared or read-only identifiers (symbols) that can't be modified by the

development environment. ?Include resources in your executable (.exe) file that don't require editing (or that

you don't want to be edited) during your current project, such as resources that are shared between several projects. ?Include resource types not supported by the development environment.

You can open the types of files shown in the following table and edit the resources they contain.

Filename

Description

.rc .res .exe .dll .bmp, .dib, .ico,

and .cur

16- and 32-bit resource script files 16- and 32-bit resource files 16- and 32-bit executable files 16- and 32-bit dynamic link library files Bitmap, icon, and cursor files

Note Resource script files (.rc) are distinguished as being 16- or 32-bit by whether they contain 32-bit resource keywords (such as LANGUAGE, EXSTYLE, or DIALOGEX), not by their underlying file structure. You create a 32-bit .rc file only by adding 32-bit keywords to it.

The environment also works with the files shown in the following table during your resource editing session.

Filename

Description

Resource.h

Header file generated by the development environment; contains symbol definitions.

filename.aps

Binary version of the current resource script file; used for quick loading.

projectname.clw

File containing information about the current project; used by ClassWizard in Visual C++.

projectname.mak projectname.vcp

File containing project build instructions. Project configuration file.

Resource Scripts (.rc)

These a text files that look C++/C-ish. They can contain: Macros (#define and #undef) Conditional compilation (#if, #ifdef, #ifndef, #else, #elif, #endif) Header files (#include) C/C++ comments (/* ... */ and // ) Stringizing operators (#) Token-passing operators (##)

Single line statements: Bitmaps: name BITMAP name.bmp Cursors: name CURSOR name.cur Fonts: name FONT name.fnt Icons: name ICON name.ico Language (like english) Messagetables (used in NT for event logging)

Multiline statements: Accelerators - these are keystrokes that represent shortcuts to specific tasks. name ACCELERATOR BEGIN

................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download