Il 19/09/2012 15:18, Stephan Hradek ha scritto:
Hi!
I'm using TiddlyWiki for some days now and really like it. I also started
to tweak a bit the sytlesheets and thought that, maybe, some of you would
like to have a small icon after external links too.
For this, I edited the StyleSheetLayout tiddler, adding the 2 definitions
below. Hope you like it.
where did you find this extremely compact icon? There are more like this
somewhere?
yes I like it, for TiddlyWiki this technique is very useful for small UI
icons, and images because the file doesn't depend from external images
and works even when it's downloaded and used locally.
but you should also explain us the underlying technique.
----
By using the Data URI scheme [1] you can embed images directly into your
HTML and CSS. It works by encoding an image into a base64 string and
place it directly withing an HTML image tag or as a CSS background URL.
The image below is encoded directly into the HTML on the page:
<img alt=""
src="data:image/gif;base64,R0lGODlhEgASAKIGAO7u7ru7u3d3d4iIiKqqqv///////wAAACH5BAEAAAYALAAAAAASABIAAAMgaLrc/jDKSau9OOvNcSBgGEhEYZ4DeQIFkEbEIM9CdyUAOw=="
/>
or declared into a CSS rule:
background-image:
url(data:image/gif;base64,R0lGODlhEgASAKIGAO7u7ru7u3d3d4iIiKqqqv///////wAAACH5BAEAAAYALAAAAAASABIAAAMgaLrc/jDKSau9OOvNcSBgGEhEYZ4DeQIFkEbEIM9CdyUAOw==);
----
Tiddlytools offers a package to "store or link binary files (such as
jpg, gif, pdf or even mp3) within your TiddlyWiki document and then use
them as images or links from within your tiddler content" [2].
Also, I think every OS has it's own command line base64 command to
encode files to base64.
-----
[1] http://www.phpied.com/data-urls-what-are-they-and-how-to-use/
[2] http://www.tiddlytools.com/#AttachFilePackage
regards
--
tiziano de togni
______________________________________
http://tiziano.tiddlyspot.com
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To post to this group, send email to tiddlywiki@googlegroups.com.
To unsubscribe from this group, send email to
tiddlywiki+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/tiddlywiki?hl=en.