From 96a2650cf7261e7427592a2f635c87f4efe5fd92 Mon Sep 17 00:00:00 2001 From: Eugene Crosser Date: Thu, 2 Mar 2006 14:52:24 +0000 Subject: [PATCH] style slideshow --- include/gallery.css | 20 ++++++++++++++++++++ mkgallery.pl | 21 ++++++++++++--------- 2 files changed, 32 insertions(+), 9 deletions(-) diff --git a/include/gallery.css b/include/gallery.css index af7ba23..5778fc0 100644 --- a/include/gallery.css +++ b/include/gallery.css @@ -66,3 +66,23 @@ table.infotable td { border-width: 0px; padding: 0.3ex; } + +table.navi { + background-color: #c0c0c0; + border: 1px solid black; + border-collapse: collapse; + text-align: center; + margin: 0px; + padding: 0px; +} +table.navi td { + border: 1px solid black; + margin: 0px; + padding: 1ex; +} + +table.picframe { + border: 1px solid black; + margin: 10px; + padding: 10px; +} diff --git a/mkgallery.pl b/mkgallery.pl index c61e22c..a6252e6 100755 --- a/mkgallery.pl +++ b/mkgallery.pl @@ -29,7 +29,7 @@ package FsObj; use strict; use Carp; use POSIX qw/getcwd/; -use CGI qw/:html *table *center *div/; +use CGI qw/:html *table *Tr *center *div/; use Image::Info qw/image_info dim/; use Term::ReadLine; use Getopt::Long; @@ -323,7 +323,7 @@ sub makeaux { # slideshow for my $refresh('static', 'slide') { my $fn = sprintf("%s/.html/%s-%s.html",$dn,$name,$refresh); - my $imgsrc = sprintf("../.%s/%s",$sizes[1],$name); + my $imgsrc = '../'.$self->{$sizes[1]}; my $fwdref; my $bakref; if ($nref) { @@ -365,13 +365,16 @@ sub makeaux { ),"\n"; } print $F start_center,"\n", - h1($title), - a({-href=>"../index.html"},"Index")," | ", - a({-href=>$bakref},"<<Prev")," | ", - a({-href=>$toggleref},$toggletext)," | ", - a({-href=>$fwdref},"Next>>"), - p, - img({-src=>$imgsrc}),"\n", + h1($title),"\n", + start_table({-class=>'navi'}),start_Tr,"\n", + td(a({-href=>"../index.html"},"Index")),"\n", + td(a({-href=>$bakref},"<<Prev")),"\n", + td(a({-href=>$toggleref},$toggletext)),"\n", + td(a({-href=>$fwdref},"Next>>")),"\n", + end_Tr, + end_table,"\n", + table({-class=>'picframe'}, + Tr(td(img({-src=>$imgsrc})))),"\n", end_center,"\n", end_html,"\n"; close($F); -- 2.39.2