12.12.2012 Views

Teach Yourself Borland C++ in 14 Days - portal

Teach Yourself Borland C++ in 14 Days - portal

Teach Yourself Borland C++ in 14 Days - portal

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

396 Day 11<br />

Table 11.2. cont<strong>in</strong>ued<br />

Item Shortcut Description<br />

Show Execution Po<strong>in</strong>t none Displays the program execution po<strong>in</strong>t<br />

<strong>in</strong> the Code Editor. Scrolls the source<br />

code w<strong>in</strong>dow if necessary. Only works<br />

when program execution is paused.<br />

Program Pause none Pauses program execution as soon as<br />

the execution po<strong>in</strong>t enters the<br />

program’s source code.<br />

Program Reset Ctrl+F2 Closes down the program and returns<br />

to the <strong>C++</strong>Builder IDE.<br />

Inspect none Displays the Inspect dialog box so that<br />

you can enter the name of an object to<br />

<strong>in</strong>spect.<br />

Evaluate/Modify Ctrl+F7 Displays the Evaluate/Modify dialog<br />

box.<br />

Add Watch Ctrl+F5 Displays the Watch Properties dialog<br />

box.<br />

Add Breakpo<strong>in</strong>t none Displays the Edit Breakpo<strong>in</strong>t dialog<br />

box to allow you to add a breakpo<strong>in</strong>t.<br />

You will use these menu items a lot when you are debugg<strong>in</strong>g your programs. You should also<br />

become familiar with the various keyboard shortcuts for the debugg<strong>in</strong>g operations.<br />

Now let’s take a look at breakpo<strong>in</strong>ts and how you use them <strong>in</strong> your program.<br />

Breakpo<strong>in</strong>ts<br />

When you run your program from the <strong>C++</strong>Builder IDE it runs at full speed, stopp<strong>in</strong>g only<br />

where you have set breakpo<strong>in</strong>ts.<br />

A breakpo<strong>in</strong>t is a marker that tells the debugger to pause program execution when<br />

that po<strong>in</strong>t <strong>in</strong> the program is reached.<br />

NEW TERM<br />

Sett<strong>in</strong>g and Clear<strong>in</strong>g Breakpo<strong>in</strong>ts<br />

To set a breakpo<strong>in</strong>t, click <strong>in</strong> the editor w<strong>in</strong>dow’s gutter to the left of the l<strong>in</strong>e on which you<br />

want to pause program execution. A stop sign icon appears <strong>in</strong> the gutter, and the entire l<strong>in</strong>e

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!