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

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

VCL Components<br />

You can set this property to false, but by the time the component is placed, it is already too<br />

late and you will have to change the font manually to the font you want for the component.<br />

The Tag Property<br />

The Tag property is noth<strong>in</strong>g more than a 4-byte variable set aside for your use. You can use<br />

the Tag property to store any data that your component might need. The data stored might<br />

be a po<strong>in</strong>ter to another class, an <strong>in</strong>dex value, or any number of other possibilities. Us<strong>in</strong>g the<br />

Tag property would probably be considered an advanced programm<strong>in</strong>g technique.<br />

Other Common Properties<br />

Table 8.1 lists other common properties that are frequently used. These properties don’t<br />

require as much explanation, so I just listed them here for your reference. Not all components<br />

have each of the properties listed.<br />

Table 8.1. Additional component properties.<br />

Property Description<br />

BorderStyle Can be bsS<strong>in</strong>gle or bsNone. Use bsNone when you want the component<br />

to blend <strong>in</strong> with the background.<br />

Caption Sets the component’s caption. Many components do not have<br />

captions, so for those components the Caption property is not<br />

exposed.<br />

Ctl3D Indicates whether the control should be drawn with a 3D border. If<br />

BorderStyle is set to bsNone, this property has no effect.<br />

Height Sets the component’s height.<br />

HelpContext The HelpContext property is used to associate an <strong>in</strong>dex number <strong>in</strong> a<br />

help file with a particular component.<br />

Left Sets the x coord<strong>in</strong>ate of the component.<br />

PopupMenu Specifies the pop-up menu that will be displayed when the user clicks<br />

the secondary mouse button.<br />

TabOrder For w<strong>in</strong>dowed components. Sets this component’s position <strong>in</strong> the tab<br />

order.<br />

TabStop For w<strong>in</strong>dowed components. Indicates that this component can be<br />

tabbed <strong>in</strong>to. Sett<strong>in</strong>g this property to false removes the component<br />

from the tab order.<br />

281<br />

cont<strong>in</strong>ues<br />

8

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

Saved successfully!

Ooh no, something went wrong!