From: Bernardo Innocenti Date: Mon, 17 Dec 2007 11:34:45 +0000 (+0100) Subject: Add image thumbnails. X-Git-Tag: v3.0~44 X-Git-Url: https://codewiz.org/gitweb?a=commitdiff_plain;h=9f2fe21749316eaf332c37b6f6fbbc12237dd1cf;p=geekigeeki.git Add image thumbnails. --- diff --git a/geekigeeki.css b/geekigeeki.css index d311c49..0255a72 100755 --- a/geekigeeki.css +++ b/geekigeeki.css @@ -331,6 +331,31 @@ pre.notice { border: 1px solid #8cacbb; } +/* thumbnails */ +div.thumb { + float: right; + border: 1px solid #ccc; + padding: 3px !important; + margin: 10px; + margin-bottom: .5em; + background-color: #f9f9f9; + text-align: center; +} + +div.thumb a img { + border: 1px solid #ccc; +} + +div.thumb div.caption { + border: none; + overflow: hidden; + font-size: 94%; + line-height: 1.4em; + padding: .3em 0 .1em 0; + text-align: center; +} + + /* Styles for search word highlighting */ @media screen { .searchword0 { background: #ff9 } diff --git a/geekigeeki.py b/geekigeeki.py index d8d984a..cd92c54 100755 --- a/geekigeeki.py +++ b/geekigeeki.py @@ -397,7 +397,7 @@ class PageFormatter: if macro: return apply(macro, (name, descr)) elif img_re.match(name): - return '%s' % (name, name, descr) + return '
%s
%s
' % (name, name, descr, descr) else: if img_re.match(descr): descr = ''