TMessagePanel Readme File

This component is considered freeware and may be used in whatever
fashion you want. I am not responsible for your laziness after
seeing how easy it is to display messages now. Actually, I threw
this component together because I found myself using the same
technique in all my programs.

This freeware component gives you a quick and easy way to display
messages in your applications. Just drop one on a form and you
have a ready made message display system. It's not sophisticated,
fancy or high-priced. It's simple and free.

The concept is simple. Drop the component on the form and
set the fonts for normal messages and for error messages. Then set
the color of the panel that displays the messages for both the
normal and error messages. I tend to use the default values, which
is why they are the default. :) 

To have the message panel size itself and center itself on
the form, just leave the AutoCenter and AutoSize properties set to
true. If you want to control the position and size yourself, then set
them to false and set the PanelTop, PanelLeft, PanelHeight and 
PanelWidth properties. 

Properties of TMessagePanel:

        AutoCenter: 		set to true to let component center itself
        AutoSize: 		set to true to let component size itself based on text
        BevelWidth: 		set the bevel width of the displayed panel
        Boundaries: 		used to control the placement of the message panel
                    		within a certain area of the parent form. If AutoCenter
                    		is true and the boundaries are set, the panel is
                    		centered in this area.
        Color: 		the panel color for normal messages
        Dots: 			string of characters to blink at end of text (default "...")
        DotsInterval: 		seconds to wait between blinking dots
        DotsOn: 		true/false depending on whether to show blinking dots
        ErrorColor: 		the color of the panel for error messages
        ErrorFont: 		the font for error messages
        Font: 			the font for normal messages
        KeepOnPause: 		option to keep existing message after using the pause method
        PanelHeight: 		height of the display panel if manually controlling it
        PanelLeft: 		left side of the panel if manually positioning it
        Margin: 		pixels to provide spacing for messages when AutoSize is true
                			15 is the minimum used when DotsOn is true to ensure enough
                			space between the edges of the panel and the text for the "..."
        MaxPause: 		maximum number of seconds to use when DisplayInfoPause is
                  		used. This keeps you from typing errors in your code and
                  		having a message displayed indefinately. (default 10 seconds)
                  		Set this to zero to ignore the maximum seconds.
        MinWidth: 		minimum width of panel when AutoSize is true (default 300 pixels)
        PanelTop: 		top of the panel when manually controlling it
        PanelWidth: 		width of the panel when manually controlling it

There are only 3 methods to this component (besides the usual Create and OnDestroy):

  DisplayInfo: puts a message on screen until you take it off
  DisplayInfoPause: displays a message for a given amount of
		    seconds
  GetDisplayInfo: returns the current message being displayed

There are also 2 events published:

  OnChange: occurs anytime the message is set or cleared
  OnDestroy: occurs when you free the component and it is destroyed


Here's an example of how easy it is.

1. Create a new application.
2. Drop a TMessagePanel and a button on the form.
3. In the OnClick event for the button, add these lines:

   MessagePanel1.DisplayInfoPause('This is a normal message to display.', 3);
   MessagePanel1.DisplayInfoPause('Here is an error message for you.', 3, true);
   MessagePanel1.DotsOn := true;
   MessagePanel2.DisplayIntoPause('Message text with blinking dots', 3);

4. Run the application and click the button.


Any questions or comments may be directed at me (gently please) at:

Woody
woody.tmw@ih2000.net