… | |
… | |
43 | $viewer->load_image ($_[1]); |
43 | $viewer->load_image ($_[1]); |
44 | }); |
44 | }); |
45 | |
45 | |
46 | Gtk2::CV::Plugin->call (new_schnauzer => $s); |
46 | Gtk2::CV::Plugin->call (new_schnauzer => $s); |
47 | |
47 | |
48 | $s; |
48 | $s |
49 | } |
49 | } |
50 | |
50 | |
51 | sub std_keys { |
51 | sub std_keys { |
52 | my $key = $_[1]->keyval; |
52 | my $key = $_[1]->keyval; |
53 | my $state = $_[1]->state; |
53 | my $state = $_[1]->state; |
… | |
… | |
102 | |
102 | |
103 | $viewer->signal_connect (button3_press_event => sub { |
103 | $viewer->signal_connect (button3_press_event => sub { |
104 | $mainwin->visible |
104 | $mainwin->visible |
105 | ? $mainwin->hide |
105 | ? $mainwin->hide |
106 | : $mainwin->show_all; |
106 | : $mainwin->show_all; |
107 | 1; |
107 | 1 |
108 | }); |
108 | }); |
109 | |
109 | |
110 | Gtk2::CV::Plugin->call (new_imagewindow => $viewer); |
110 | Gtk2::CV::Plugin->call (new_imagewindow => $viewer); |
111 | |
111 | |
112 | $schnauzer = new_schnauzer; |
112 | $schnauzer = new_schnauzer; |
113 | |
113 | |
114 | $mainwin = new Gtk2::Window; |
114 | $mainwin = new Gtk2::Window; |
115 | $mainwin->set_title ("CV"); |
115 | $mainwin->set_title ("CV"); |
116 | $mainwin->add (my $vbox = new Gtk2::VBox); |
116 | $mainwin->add (my $vbox = new Gtk2::VBox); |
117 | $mainwin->signal_connect (delete_event => sub { $mainwin->hide; 1; }); |
117 | $mainwin->signal_connect (delete_event => sub { $mainwin->hide; 1 }); |
118 | |
118 | |
119 | $vbox->add ($schnauzer); |
119 | $vbox->add ($schnauzer); |
120 | $vbox->pack_end (my $frame = new Gtk2::Frame, 0, 0, 0); |
120 | $vbox->pack_end (my $frame = new Gtk2::Frame, 0, 0, 0); |
121 | $frame->add (my $hbox = new Gtk2::HBox 0, 0); |
121 | $frame->add (my $hbox = new Gtk2::HBox 0, 0); |
122 | $hbox->pack_start ((new Gtk2::Label "Info: "), 0, 0, 0); |
122 | $hbox->pack_start ((new Gtk2::Label "Info: "), 0, 0, 0); |
… | |
… | |
169 | |
169 | |
170 | This algorithm is quite unprecise - it doesn't make a difference between |
170 | This algorithm is quite unprecise - it doesn't make a difference between |
171 | files, device nodes, symlinks and the like, and filetype detection is done |
171 | files, device nodes, symlinks and the like, and filetype detection is done |
172 | using the file extension only. |
172 | using the file extension only. |
173 | |
173 | |
|
|
174 | =item * queuing for all time-consuming background tasks |
|
|
175 | |
|
|
176 | All tasks, such as unlinking files or generating thumbnails, that can be |
|
|
177 | done in the background will be done so - no waiting required, even when |
|
|
178 | changing directories. |
|
|
179 | |
174 | =item * use of asynchronous I/O |
180 | =item * use of asynchronous I/O |
175 | |
181 | |
176 | CV tries to use asynchronous I/O whereever it makes sense, for example |
182 | CV tries to use asynchronous I/O whereever it makes sense, for example |
177 | while scanning directories, waiting for stat data or unlinking files. This |
183 | while scanning directories, waiting for stat data, unlinking files or |
178 | usually decreases scanning times for large directories a bit (especially |
184 | generating thumbnails. This usually decreases scanning times for large |
179 | on RAID devices and over NFS). |
185 | directories a bit (especially on RAID devices and over NFS) and makes CV |
|
|
186 | much more interactive. |
180 | |
187 | |
181 | =item * fast image loading |
188 | =item * fast image loading |
182 | |
189 | |
183 | The time span between the user issuing a command and displaying the new |
190 | The time span between the user issuing a command and displaying the new |
184 | image should be as small as possible. CV uses optimized (especially |
191 | image should be as small as possible. CV uses optimized (especially |