[Seaside] Re: Icons in Seaside app

Germán S. Arduino gsa at softhome.net
Wed Apr 14 15:44:34 CEST 2004


Thanks by your response Ben.

I will try asap.

Regards.

"Ben Schroeder" <bschroeder at procro.com> escribió en el mensaje
news:6C84E4708C000E4A874A5B0822A29F0340FF91 at pulse.procro.com...
Hi Germán,

> I want to use icons instead of text links in a Seaside app,
> may be the same
> icons in use in the 3.7 image.
>
> Also wants to be able to show a "tooltip" (aka ballon-help)
> when the mouse
> is over the rendered icon.
>
> Does exist some example about it?

I'm not sure about an example elsewhere, but here's what we did in an app
here recently.  Anything you put inside the second parameter to
anchorWithAction:do: gets linked.  You can show a Squeak Form object as an
HTML image - something like

html
anchorWithAction: [self showCommentsPage]
do:
[html attributes: {#border -> 0}.
html imageWithForm: self class commentsImage].

(commentsImage answers a Form with the comments icon.)

The #border -> 0 avoids showing a link border around the icon on the page.

Tooltips are also easy - just use the 'title' attribute of any element.

html
anchorWithAction: [self showCommentsPage]
do:
[html attributes: {#border -> 0. #title -> 'Show comments'}.
html imageWithForm: self class commentsImage].

Hope this helps,
Ben Schroeder





More information about the Seaside mailing list