Copyright © 1998-2006 MultiMedia Soft 
Return to index  
 
How to add text to the button 
The simplest way to change a button's text is to use, inside 3D Button Visual Editor, the Texts tab. At run-time each of these properties can be referenced by name.  
As you can see on the image below you can enter up to 9 different texts on the button's surface, each with its own fonts, settings and colors. 
 
Note: The image below has hot links to take you to explanations of the text controls.  
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --  
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --  
 
 
Item name
Description
Corresponding property
 
Available texts
The set of available texts that can be displayed on the button surface: clicking one of these buttons will load the settings that govern the selected text.  
 
 
Caption button
Loads the Caption text settings
 
Left Top button
Loads the Left Top text settings
 
Center Top button
Loads the Center Top text settings
 
Right Top button
Loads the Right Top text settings
 
Left Middle button
Loads the Left Middle text settings
 
Right Middle button
Loads the Right Middle text settings
 
Left Bottom button
Loads the Left Bottom text settings
 
Center Bottom button
Loads the Center Bottom text settings
 
Right Bottom button
Loads the Left Right Bottom text settings
 
The properties TextDescrCaption, TextDescrLT, TextDescrCT, TextDescrRT, TextDescrLM, TextDescrRM, TextDescrLB, TextDescrCB, and TextDescrRB  are internally implemented as a COM object called TextDescriptor: thanks to this object oriented approach, each of these properties have a set of sub-properties that allow a better control of the following text rendering aspects: 
 
Item name
Description
Corresponding property
 
 
 
 
 
Text
The text that will appear over the button: it can be multi-line (press the Enter key each time you need to create a new line of text).
 
Visible
Hides/shows the selected text
 
Offset X
Offset from the default horizontal position
 
Offset Y
Offset from the default vertical position
 
Effect
Enhancement special effect applied to text
 
Factor
Enhancement special effect factor
 
Double space
Applies/removes double space (Available only with Professional edition)
 
Antialias
Applies/removes anti-aliasing to text borders (Not available with Light edition)
 
Transparency
Applies alpha channel transparency to text. (Available only with Professional edition)
 
Rotation angle
Text rotation angle (Available only with Professional edition)
 
Normal Color (Up)
Text color when the button is in Normal state.
 
Mouse over Color
Text color when the mouse is over the button surface: if this color is left undefined the Normal Color will be used. 
The undefined state is represented with the  symbol inside the color box. Once the color has been defined, it can be reset back to the undefined state by double-clicking the relative color box (not the "..." button).
 
Pressed Color (Down)
Text color when the button is in Pressed state: if this color is left "undefined" the Normal Color will be used. 
The undefined state is represented with the  symbol inside the color box. Once the color has been defined, it can be reset back to the undefined state by double-clicking the relative color box (not the "..." button).
 
Disabled Color (all)
Text color when the button is in Disabled state: this property applies to all texts at the same time.
 
Highlight effect color
Color of the highlighted text portion (available when a special effect is applied): if this color is left undefined the color will be calculated automatically. 
The undefined state is represented with the  symbol inside the color box. Once the color has been defined, it can be reset back to the undefined state by double-clicking the relative color box (not the "..." button).
 
Shadow effect color
Color of the shadowed text portion (available when a special effect is applied): if this color is left undefined the color will be calculated automatically. 
The undefined state is represented with the  symbol inside the color box. Once the color has been defined, it can be reset back to the undefined state by double-clicking the relative color box (not the "..." button).
 
Halo effect color
Color used to create a Halo special effect. (Available only with Professional edition)
 
Solid background
Applies/removes a solid background under the text position (Available only with Professional edition)
 
Solid background Color
Color of the solid background, if any (Available only with Professional edition)
 
Background border
Applies/removes a line border around the text position (Available only with Professional edition)
 
Background border Color
Color of the border, if any (Not available with Light edition)
 
Background shadow
Applies/removes a shadow to the text solid background, if any (Available only with Professional edition)
 
Background shadow Color
Color of the shadow, if any (Not available with Light edition)
 
"..." color editing buttons
These buttons will open the color choice dialog box for the corresponding property.
 
 
The Caption text has a couple of further features for better control of text positioning. 
 
Item name
Description
Corresponding property
 
Align
The text alignment (Left, Center and Right).
 
Wordwrap %
Constrains the button surface percentage that will contain the text.
 
Fonts related settings are managed through the use of the following properties: FontTextCaption, FontTextLT, FontTextCT, FontTextRT, FontTextLM, FontTextRM, FontTextLB, FontTextCB and FontTextRB. These properties are implemented using the standard Windows Font object (check the Microsoft documentation or MSDN for details) so each of these properties has a set of standard sub-properties that allow a better control of the following aspects of the font rendering
 
Item name
Description
Corresponding property
 
Font
The font name (also known as typeface or facename): only TrueType (marked with the symbol) and OpenType (marked with the symbol) fonts are supported.
Font.Name
 
Size
The height of the button expressed in points
Font.Size
 
B Bold checkbox
Sets/resets the bold attribute
Font.Bold
 
I Italic checkbox
Sets/resets the italic attribute
Font.Italic
 
U Underline checkbox
Sets/resets the underline attribute
Font.Underline
 
S Strikethrough checkbox
Sets/resets the strikethrough attribute
Font.Strikethrough
 
NOTE: starting from version 8 of the control, you can add further texts through the use of "cells": see the How to manage cells section for details. 
 
 
 
 
 
 
 
 
 
 
 
 
 
Copyright © 1998-2006 MultiMedia Soft 
Return to index