Copyright© Kambiz R. Khojasteh. All rights reserved.
Get future component updates from http://www.delphiarea.com.
DESCRIPTION
If you would like to display text containing multiple lines on the screen and there is not enough room, TTextFader is your solution. This component shows lines one by one each fading into the next.
KEY PROPERTIES
- Active: Boolean
Toggles text fading on/off.
- Alignment: TAlignment
TAlignment = (taLeftJustify, taRightJustify, taCenter)
Specifies how the text is aligned within the client area of the control.
- Background: TPicture
Contains the background image of the control.
- BackgroundMode: TBackgroundMode
TBackgroundMode = (bmNone, bmTiled, bmStretched, bmCentered)
Determines how the control displays the background image on its client area.
bmNone |
|
Ignores the background image. |
bmTiled |
|
Fills the client area of the control by the background image as tiled. |
bmStretched |
|
Fills the client area of the control by stretching (or shrinking) the background image. |
bmCentered |
|
Draws the background image on the center of the control's client area. |
- FadeDelay: Word
Determines the amount of delay in milliseconds before showing the next frame.
- FadeStep: 1..100
Determines the maximum amount of transparency difference (in percent) between to consequent frames.
- LineDelay: Word
Determines the amount of delay in milliseconds before showing the next line of text.
- LineIndex: Integer
Determines the index of the next line of text that will be displayed.
- Lines: TStrings
Contains the lines of text. You can use the following escape characters inside the text:
\\ |
|
A single backslash |
\n |
|
Line break |
\t |
|
Tab space |
The escape characters are case sensitive.
- RepeatCount: TBorderWidth
Specifies the number of iterations. When the control shows all lines of text for the number of specified iteration, the Active property sets to False automatically.
- RepeatedCount: Integer (Read-only)
Specified the number of times that all the lines has been shown.
- Transparent: Boolean
Specifies whether controls that sit below the control can be seen through it.
- WordWrap: Boolean
Specifies whether the line of text wraps when it is too long for the width of the control.
KEY METHODS
- procedure Reset
Clears the control's client area and restart to show the lines from the first line of the text. This method does not change the value of RepeatedCount property.
KEY EVENTS
- OnComplete: TNotifyEvent
Occurs when the current line of the text has been displayed completely.
- OnMouseEnter: TNotifyEvent
Occurs when the mouse pointer moves over the control.
- OnMouseLeave: TNotifyEvent
Occurs when the mouse pointer moves off from over the control.
GLOBAL ROUTINES
- procedure DrawTiled(Canvas: TCanvas; Rect: TRect; Graphic: TGraphic)
Convers the surface of a rectangle with tiled images of a specified graphic.
- procedure DrawTransparent(dstBitmap, srcBitmap: TBitmap; Transparency: TPercent)
Draws the srcBitmap over the dstBitmap with the specified amount of transparency in percent. Two bitmaps must have same dimensions.
HISTORY
- 1.24 (November 18, 2008)
- Supports for Delphi 2009 added.
- 1.23 (April 7, 2006)
- Added OnMouseEnter and OnMouseLeave events.
- 1.22 (April 7, 2002)
- Now, each line of the text can have line breaks and tab spaces.
- 1.21 (March 8, 2002)
- The transparency bug is fixed.
- 1.20 (February 4, 2001)
- The memory leak is fixed.
- 1.10 (July 28, 2000)
- I forgot to track changes in this release, sorry.
- 1.00 (May 30, 2000)
- Initial release.
ACKNOWLEDGMENT
Special thanks to:
LICENSE
TTextFader component is freeware. You may copy component's files AS LONG AS YOU COPY ALL OF THEM. If you want to change the source code in order to improve the component's features, performance, etc. please send me the new source code so that I can have a look at it. The changed source code should contain descriptions what you have changed, and of course your name. The only thing you MAY NOT CHANGE is the ORIGINAL COPYRIGHT INFORMATION.
DISCLAIMER
TTextFader is provided "AS IS" without any warranty of any kind, either express or implied. The entire risk as to the quality and performance of the software is with you. The author is NOT liable for any DAMAGES resulting from the use and misuse of the component, especially he is NOT liable for DAMAGES that were caused BY ANY VERSION WHICH HAS NOT BEEN PROGRAMMED BY THE AUTHOR HIMSELF.