in reply to Advice on writing GUI's in Perl
As far as the gnome extension problem, you need to have the gnome libs installed if you use the gnome widgets. You don't need to run Gnome as your desktop, but it helps for full functionality of the gnome widgets. Otherwise just don't use the gnome widgets.
My favorite gtk library is the gtk-image-viewer at gtk-image-viewer
It allows mouse zooming and panning of images, try that with Tk (and the speed is smooth). Here is a little perl script to use it:
#!/usr/bin/perl ###################################################################### + # Simple image viewing application with mouse zoom and pan. ###################################################################### + use Gtk; use Gtk::ImageViewer; init Gtk; init Gtk::Gdk::Rgb; init Gtk::Gdk::Pixbuf; init Gtk::ImageViewer; if(@ARGV<1){print "Usage: imageview file\n";exit} $window = Gtk::Widget->new("GtkWindow", -type => "-toplevel", -title => "Image viewer", -delete_event => sub { print exit Gtk; } ); $image = Gtk::Widget->new("GtkImageViewer", -parent => $window, ); $file = shift; $pb = new_from_file Gtk::Gdk::Pixbuf($file); $image->set_image($pb); $window->show_all(); main Gtk;
|
|---|