Unit AMLed |
TLed version 1.0 copyright © 1997 by Alexander Meeder (ameeder@dds.nl) This is a visual component to simulate a LED. You may use it for free but I do not guarantee anything properties: * About -> read-only property which shows some info. about this version and programmer * Alignment -> default 'laCenter', other options (laBottom, laCenter, laLeft, laRight, laTop) * BorderColor -> default 'clGreen', this property is only used when Ctl3D is false * BorderStyle -> default 'bsRaised', this porperty is only used when Ctl3D is true * BorderWidth -> default value 2 (value must be between 1 and 5, use for the best results with LedShape = lsRndRect or lsRound a value of 2 or higher, with BorderWidth of 1 the led isn't drawn right * Caption -> default value 'Led' * Ctl3D -> same as other controls, default is true (draws phong when LedShape = lsRndRect or lsRound) * Cursor -> same as other controls * Font -> same as other controls * Height -> height of LED-control (Attention: not the height of the LED) default value 42 * Hint -> same as other controls * Interval -> interval of internal timer (0 to MaxInt), default 0. To save resources there is no Timer created when value is 0. * LedHeight -> default value 10, (value must be between 5 and 100) * LedOn -> boolean, default false. Read/Write property (exampl. Led1.LedOn := not Led1.LedOn) * LedShape -> default lsRect, you have three choices lsRect, lsRndRect and lsRound * LedWidth -> default value 25, (value must be between 5 and 100) * Left -> same as other controls * Margin -> default value 3, margin between LED and caption (value must be between 1 and 10) * Name -> same as other controls, default value Ledxx - where xx unique identifier * OffColor -> default is clGreen * OnColor -> default is clLime * PhongSize -> default 2, value must be between 1 and 5 * ShowHint -> same as other controls, default value false * Tag -> same as other controls * Top -> same as other controls * Width -> same as other controls, default value 66 events: * OnChange -> when Led-status changes this event occur, to determine if Led is 'on' or 'off' you can use 'IsOn'-parameter (true=on / false=off) If you have suggestions about TLed or make changes, please mail me: ameeder@dds.nl
Classes |
TAboutProperty -
TLed -
Functions |
Register -
Types |
TBorderStyle
TBrdrWidth
TInterval
TLedDimension
TLedShape
TMargin
TMyAlignment
TOnOff
Constants |
Variables |
Functions |
Types |
TBorderStyle = (bsRaised, bsLowered);
TBrdrWidth = 1..5
TInterval = 0..MaxInt
TLedDimension = 5..50
TLedShape = (lsRect, lsRndRect, lsRound);
TMargin = 1..10
TMyAlignment = (laLeft, laRight, laCenter, laTop, laBottom);
TOnOff = procedure (Sender : TObject; IsOn : Boolean) of object
Constants |
Variables |