Re: Gtk2::FileFilter by mime type
- From: Emmanuele Bassi <ebassi gmail com>
- To: gtk-perl-list gnome org
- Subject: Re: Gtk2::FileFilter by mime type
- Date: Fri, 27 Nov 2009 13:39:56 +0000
On Thu, 2009-11-26 at 02:28 -0800, Zettai Muri wrote:
Hi All,
I am trying to use the following filters:
my $sound_filter = Gtk2::FileFilter->new;
$sound_filter->add_mime_type("audio/*");
my $image_filter = Gtk2::FileFilter->new;
$image_filter->add_mime_type("image/*");
Because I read here:
http://library.gnome.org/devel/gtk/stable/gtk-gtkfilefilter.html#gtk-file-filter-add-mime-type that
'GtkFileFilter allows wildcards for the
subtype of a mime type, so you can e.g. filter for image/*.'
Is this also possible with the Perl bindings?
yes, and it works fine.
At the moment, when my file chooser opens and I navigate to a directory where I have some jpgs I don't see
any files.
If I change my filter to:
$image_filter->add_pattern("*.jpg");
I can see the files.
are you using windows?
windows doesn't have the concept of MIME types.
ciao,
Emmanuele.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]