||Re: Blinking Text
Mervyn Bick <firstname.lastname@example.org>
||Sat, 8 Jun 2019 13:08:07 +0200
On 2019-06-07 9:11 PM, Mustansir Ghor wrote:
> Dear All
> There was a useful thing in DOS, where we can set string of text to blink in order to draw attention.
> I saw similar thing in string class but I failed to use. Can anybody help on this.
It may have been available in DOS but blinking text was also a source of
much irritation. It's usefulness is a moot point. :-)
In all the years I've been working with computers the only time I ever
considered blinking text to be acceptable was in the SCADA system
controlling and monitoring the Johannesburg electricity grid. Some
alarms indicated problems which needed to be attended to urgently.
These messages were displayed on screen in large red text which
continued blinking until they were acknowledged by the operator. The
times for the alarm and acknowledgment were logged and if it took longer
than a few seconds the operator had some explaining to do. :-(
Using a string's blink() method e.g new string("Blinking text").blink()
wraps the string in HTML <blink> tags <BLINK>Blinking text</BLINK>
As Ken has pointed out, this is only useful in text to be displayed in a
web-browser as the dBASE editor object and the text object don't
recognise the <blink> tag. The tags which are recognised are listed in
the help file under Editor Class.
Some of the other string class methods are, however, usable in a editor
object with the evalTags property set true or in a text object.
form.editor1.value = new
string("Bold,big,italics").bold().big().italics() works as expected.
If you REALLY want blinking text Ronnie's RMblinker.cc can blink any
object on a form. On the other hand setting up a simple custom text
object with a built-in blink was really only a few minutes work.
blink_text.cc is attached. Once you've placed an instance on a form you
can set its various properties just as you would with a normal text object.
class blink_text(parentObj) of TEXT(parentObj) custom
onOpen = class::TEXT_ONOPEN
onClose = class::TEXT_ONCLOSE
height = 1.0
left = 6.0
top = 3.0
width = 12.0
text = "Blink text"
this.timer.enabled = false
this.timer = new Timer( )
this.timer.parent = this
this.timer.onTimer = this.blink
this.timer.interval = 0.5
this.timer.enabled = true
this.parent.visible = not this.parent.visible