Package: libapache-gallery-perl
Version: 0.99-svn050921-1
Severity: wishlist
This wonderful patch does what I have wanted for some time: when
GalleryUnderscoresToSpaces is set, it works for file names too, rather
than for dir names only. The patch works for me, but does not include
the required changes to the docs in Gallery.pm. the man page and the
README.
--- Gallery.pm.orig 2005-09-16 10:52:59.000000000 +0200
+++ Gallery.pm.pot 2006-01-18 17:32:00.000000000 +0100
@@ -354,11 +354,13 @@ sub handler {
$filetype = "unknown";
}
+ my $filetitle = $file;
+ $filetitle =~ s/_/ /g if
$r->dir_config('GalleryUnderscoresToSpaces');
$tpl_vars{FILES} .=
$templates{file}->fill_in(HASH =>
{%tpl_vars,
FILEURL => uri_escape($fileurl, $escape_rule),
ALT => "Size: $size Bytes",
-
FILE => $file,
+
FILE => $filetitle,
TYPE => $type,
FILETYPE => $filetype,
}
@@ -377,8 +379,10 @@ sub handler {
my $cached =
get_scaled_picture_name($thumbfilename, $thumbnailwidth, $thumbnailheight);
my $rotate = readfile_getnum($r,
$imageinfo, $thumbfilename.".rotate");
+ my $filetitle = $file;
+ $filetitle =~ s/_/ /g if
$r->dir_config('GalleryUnderscoresToSpaces');
my %file_vars = (FILEURL =>
uri_escape($fileurl, $escape_rule),
- FILE => $file,
+ FILE => $filetitle,
DATE =>
$imageinfo->{DateTimeOriginal} ? $imageinfo->{DateTimeOriginal} : '', # should
this really be a stat of the file instead of ''?
SRC =>
uri_escape($uri."/.cache/$cached", $escape_rule),
HEIGHT =>
(grep($rotate==$_, (1, 3)) ? $thumbnailwidth : $thumbnailheight),
-- System Information:
Debian Release: testing/unstable
APT prefers testing
APT policy: (990, 'testing'), (500, 'testing-proposed-updates')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.4.30-pre2-pr-hrt-1kHz-1
Locale: LANG=C, [EMAIL PROTECTED] (charmap=ANSI_X3.4-1968) (ignored: LC_ALL set
to C)
Versions of packages libapache-gallery-perl depends on:
ii libapache-request-perl 1.33-1 Generic Apache Request Library
ii libimage-imlib2-perl 1.07-1 perl interface to the imlib2 imagi
ii libimage-info-perl 1.16-2 allows extraction of meta informat
ii libimage-size-perl 2.992-2 determine the size of images in se
ii libtemplate-perl 2.14-1 template processing system written
ii libtext-template-perl 1.44-1.1 Text::Template perl module
ii perl 5.8.7-10 Larry Wall's Practical Extraction
libapache-gallery-perl recommends no packages.
-- no debconf information
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]