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.

264 Day 7<br />

Exercises<br />

1. Place five edit components on a form and arrange them so that they are stacked<br />

vertically with their left edges aligned.<br />

2. Turn off the Snap to Grid option (choose Tools | Options from the ma<strong>in</strong> menu).<br />

Place five controls of your choice on a form and align their right edges.<br />

3. Place a ListBox component on a blank form and modify it so that it always<br />

occupies the entire client area of the form.<br />

4. Add an About box to the ScratchPad program. Use the Alignment Palette to<br />

quickly align the text labels.<br />

5. Add an Undo item and a menu separator to the speed menu for the ScratchPad<br />

program.<br />

6. Start a new application. Place six edit components on a form <strong>in</strong> random fashion.<br />

Now arrange the tab order so that tabb<strong>in</strong>g proceeds from top to bottom. Run the<br />

program to test the tabb<strong>in</strong>g order.<br />

7. Add speedbar buttons for Cut, Copy, and Paste to the ScratchPad program, as well<br />

as any others you want to add. Assign the menu event handlers for the same<br />

functions to the speed buttons.<br />

8. Add the Ctrl+S keyboard shortcut to the File | Save menu item <strong>in</strong> the ScratchPad<br />

program.<br />

9. Open the Picture Viewer project you created on Day 6, “The <strong>C++</strong>Builder IDE<br />

Explored: Projects and Forms.” Remove all unused menu items.

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

Saved successfully!

Ooh no, something went wrong!