Unit ElpsPanl

Standard defines for all Delphi Free Stuff components } {-----------------------------------------------------------------------------} { TEllipsisPanel v1.13 } {-----------------------------------------------------------------------------} { A panel that can shorten the caption text, replacing it with '...' when } { it does not fit the available space. Also provided is a generic function } { that will "ellipsify" a string. This function can be used to produce } { other components like TEllipsisPanel, such as TEllipsisLabel. } { Copyright 1998, Brad Stowers. All Rights Reserved. } { This component can be freely used and distributed in commercial and private } { environments, provied this notice is not modified in any way. It may be } { redistributed provided the entire archive file is included, the contents } { are not modified, and there is no charge for it other than nomial handling } { fees. Contact me directly for modifications to this agreement. } {-----------------------------------------------------------------------------} { Feel free to contact me if you have any questions, comments or suggestions } { at bstowers@pobox.com. } { The lateset version will always be available on the web at: } { http://www.pobox.com/~bstowers/delphi/ } { See ElpsPanl.txt for notes, known issues, and revision history. } {-----------------------------------------------------------------------------} { Date last modified: May 28, 1998 } {-----------------------------------------------------------------------------} { C++Builder 3 requires this if you use run-time packages.

Classes

TEllipsisPanel -

Functions

EllipsifyText -
Register -

Types

TAutoHintOption
TAutoHintOptions

Constants

DEF_AUTOHINTOPTIONS
DFS_COMPONENT_VERSION

Variables


Functions


function EllipsifyText(AsPath: boolean; const Text: string; const Canvas: TCanvas; MaxWidth: integer): string;


procedure Register;


Types


TAutoHintOption = (ahEnabled, ahWindowOnly, ahOnEllipsis);

TAutoHintOptions = set of TAutoHintOption
ahEnabled - Enable auto hint (set hint when caption too big. } { ahWindowOnly - Don't generate applicatoin events, only the popup hint. } { Basically, it sticks an '|' on the end of the hint string. } { ahOnEllipsis - When Caption too big, Hint is set to Caption. When Caption } { fits, Hint is set to last value assigned to it, either in } { IDE or code. For example, you set Hint = "My hint" and the } { panel has to use "..." when it displayes the caption } { "Some Text String". The hint would pop up as "Some Text } { String". You then resize and the entire caption can be } { displayed in the panel. The hint would then be "My hint".

Constants

DEF_AUTOHINTOPTIONS = [ahEnabled, ahWindowOnly, ahOnEllipsis]

DFS_COMPONENT_VERSION = 'TEllipsisPanel v1.13'


Variables