Add an image to the Tiddly-Title?

599 views
Skip to first unread message

Dirk Zemisch

unread,
Jun 10, 2009, 7:51:39 AM6/10/09
to Tiddl...@googlegroups.com
Hi,

I'm searching for a hint to insert an image (company logo) into the
title of a tiddly (template).

I could not find any ready-to-use solution like for all problems before.
Is there a solution at all?

Thanks in advance.
Dirk
--

Ken Girard

unread,
Jun 10, 2009, 8:18:43 AM6/10/09
to TiddlyWiki
http://tiddlywiki.org/wiki/How_can_use_my_logo_as_the_SiteTitle_but_still_have_text_in_the_html_page_title%3F

Which basically says (in one line)
@@display:none;siteName@@[img[siteName|http://udigrudi.net/imagens/
siteName-logo.png][http://siteName.net/index.html]]

@@display:none;siteName@@ is the title contained in a custom CSS class
so that it doesn't show up. Remove the @@s and display:none; if you
want the words to show.
And this
[img[siteName|http://udigrudi.net/imagens/siteName-logo.png][http://
siteName.net/index.html]]
is standard TW markup for images. More details on it here:
http://www.tiddlywiki.com/#EmbeddedImages

And all of this goes into the SiteTitle & SiteSubTitle tiddlers as
needed.

Ken Girard

Ken Girard

unread,
Jun 10, 2009, 8:50:24 AM6/10/09
to TiddlyWiki
And I just realized you might mean into individual tiddlers...
Which would mean putting it into the ViewTemplate... but in a
different format.

Do you want it in all tiddlers, or just specific ones (Tiddlers tagged
"Logo")?

Ken Girard


On Jun 10, 7:18 am, Ken Girard <ken.gir...@gmail.com> wrote:
> http://tiddlywiki.org/wiki/How_can_use_my_logo_as_the_SiteTitle_but_s...

Dirk Zemisch

unread,
Jun 10, 2009, 10:14:21 AM6/10/09
to Tiddl...@googlegroups.com
Hallo Ken,

Ken Girard <ken.g...@gmail.com> schrieb am 10.06.2009 14:50 Uhr:
> Do you want it in all tiddlers, or just specific ones (Tiddlers tagged
> "Logo")?

I think, you got me right (for all tiddlers). I will test the solution
as soon as I will have some time.

Thanks for the solution!

Regards!
Dirk
--


Eric Shulman

unread,
Jun 10, 2009, 11:15:49 AM6/10/09
to TiddlyWiki
> I'm searching for a hint to insert an image (company logo) into the
> title of a tiddly (template).
>
> I could not find any ready-to-use solution like for all problems before.
> Is there a solution at all?

http://www.TiddlyTools.com/#TiddlerIconsPlugin
http://www.TiddlyTools.com/#TiddlerIconsPluginConfig

After importing the above tiddlers (and doing a "save-and-reload", of
course), add the following macro invocation into the ViewTemplate, so
that icons will be displayed:

<span class='title'>
<span class='floatleft' macro='tiddlerIcons''></span>
<span macro='view title'></span>
</span>

Next, in [[TiddlerIconsPluginConfig]], add entries for the desired
company logos:

merge(config.macros.tiddlerIcons.map, {
tagvalue: ["tooltip","imagefile"],
tagvalue: ["tooltip","imagefile"],
...
tagvalue: ["tooltip","imagefile"] // note: no comma after last
definition
}

Then, simply tag the relevant tiddler with one or more tags listed in
the map, and those images will be displayed next to that tiddler's
title.

note: PNG images referenced directly from within the plugin code or
contained in the default config can be obtained from:
http://www.famfamfam.com/lab/icons/silk/

enjoy,
-e
Eric Shulman
TiddlyTools / ELS Design Studios
Reply all
Reply to author
Forward
0 new messages