Link text style -- bug or feature ?
m.schonewille at economy-x-talk.com
Thu Nov 2 17:34:26 CST 2006
First of all, I wonder why one would set the textStyle of an entire
field to link? I would handle the mouseUp message instead. This may
be my own personal view, but it is easier because you can modify a
smaller amount of properties to make it work, it also gives you more
freedom to alter something afterwards.
The docs say about linkClicked: "Sent when the user clicks grouped
text." If you set the style of a field to "bold" and enter text, the
text looks bold, but it isn't. If you request for its style by
entering "put the textStyle of char 1 of fld 1" in the message box,
you should get an empty value returned.
When you click on a text, Revolution doesn't check the textStyle of
the field but the textStyle of the text. Since the textStyle is
empty, the linkClicked message is not sent.
I understand that everybody who doesn't agree will say it is far-
fetched, but I think this is a valid explantion and thus I doubt this
is a bug. Then again, I probably wouldn't mind if this behaviour were
changed, because I won't set the textStyle of a field to link anyway.
Consultancy and Software Engineering
Get your store on-line within minutes with Salery Web Store software.
Download at http://www.salery.biz
>> -------Original Message------- From: Timothy Miller Date:
>> 11/02/06 21:42:05 To: How to use Revolution Subject: Link text
>> style -- bug or feature ? This arises from a question I asked on
>> the forum, then solved on my own, by trial and error. If I set
>> the textstyle of a field to "link," by script or manually, text
>> entered into that field looks like a link. It's blue and
>> underlined. However, it doesn't act like a link. When clicked it
>> sends a mouseUp, not a linkClicked. If I select the text, the
>> "text" menu has a checkmark by "Plain," not by "Link" Maybe it's
>> a bug. If not, I don't understand the point of being able to set
>> the textstyle of a field to "link" and make the text look
>> misleadingly like a link, if it's not a link. The field inspector
>> is ambiguous in this regard. The button that sets the style to
>> "link" is marked with a "G" presumably for group. The tool tip
>> says "Link text" That's ambiguous, too. Does it mean "set the
>> style of text in this field to 'link'"? or does it mean "Link the
>> text in this field"? Maybe linking in this way affects the
>> mousechunk function, and is intended for use with a mouseUp, not
>> with a linkClicked. I haven't investigated that possibility yet.
>> The user dictionary doesn't really settle the matter either. As
>> things stand, it seems that "link" is a textStyle in one context
>> -- if you select text and set the style of the text to link, but
>> not in another -- if you set the textstyle of the field to "link"
>> I alread BZ'd this. I probably should'a asked here first.
>> Comments welcome. Tim
More information about the use-livecode