-
-
10 Jun 2011 01:41:41 UTC
- Distribution: Gtk2-Ex-History
- Module version: 8
- Source (raw)
- Browse (raw)
- Changes
- Homepage
- How to Contribute
- Issues
- Testers (1059 / 1 / 1)
- Kwalitee
Bus factor: 1- 87.50% Coverage
- License: open_source
- Perl: v5.8.0
- Activity
24 month- Tools
- Download (52.88KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
and 1 contributors-
Kevin Ryde
- Dependencies
- Glib::Ex::ConnectProperties
- Glib::Ex::FreezeNotify
- Glib::Ex::ObjectBits
- Glib::Ex::SignalBits
- Glib::Ex::SignalIds
- Glib::Object::Subclass
- Gtk2
- Gtk2::Ex::Dashes::MenuItem
- Gtk2::Ex::MenuView
- Gtk2::Ex::TreeModelBits
- Gtk2::Ex::Units
- Gtk2::Ex::WidgetEvents
- Locale::Messages
- Locale::TextDomain
- Test::Weaken::Gtk2
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
Gtk2::Ex::History::Menu -- menu of "back" or "forward" history items
SYNOPSIS
use Gtk2::Ex::History::Menu; my $my_menu = Gtk2::Ex::History::Menu->new (history => $my_history, way => 'forward');
OBJECT HIERARCHY
Gtk2::Ex::History::Menu
is a subclass ofGtk2::Ex::MenuView
, though that's only really an implementation detail and the suggestion is not to rely on more than <Gtk2::Menu>.Gtk2::Widget Gtk2::Container Gtk2::MenuShell Gtk2::Menu Gtk2::Ex::MenuView Gtk2::Ex::History::Menu
DESCRIPTION
A
Gtk2::Ex::History::Menu
presents a menu of either the "back" or "forward" choices from aGtk2::Ex::History
object. This menu is shown byGtk2::Ex::History::Button
andGtk2::Ex::History::MenuToolButton
. Selecting an item makes the History go back or forward to that item.+--------------------+ | --- --- --- --- | | Thing last visited | | The thing before | | An old thing | +--------------------+
The dashed tearoff item opens a
Gtk2::Ex::History::Dialog
. If there's no items to go "back" or "forward" then that tearoff is all that's in the menu.FUNCTIONS
$histmenu = Gtk2::Ex::History::Menu->new (key => value, ...)
-
Create and return a new history menu. Optional key/value pairs set initial properties as per
Glib::Object->new
. Thehistory
property should be set to say what to display, andway
for back or forward.my $menu = Gtk2::Ex::History::Menu->new (history => $my_history, way => 'forward');
$histmenu = Gtk2::Ex::History::Menu->new_popup (key => value, ...)
-
Create and popup a new history menu. The key/value parameters set initial properties, plus an additional
event => Gtk2::Gdk::Event object or undef
If the event has
button
andtime
fields then they're used for the menu popup, and if thewindow
field is set then that gives the screen (Gtk2::Gdk::Screen
) the menu pops up on. For example,sub my_button_press_handler { my ($self, $event) = @_; Gtk2::Ex::History::Menu->new_popup (history => $my_history, way => 'back', event => $event); return Gtk2::EVENT_PROPAGATE; # other handlers }
PROPERTIES
history
(Gtk2::Ex::History
object, defaultundef
)-
The history object to display.
way
(enumGtk2::Ex::History::Way
, default 'back')-
The direction to display, either "back" or "forward".
SEE ALSO
Gtk2::Ex::History, Gtk2::Ex::History::Button, Gtk2::Ex::History::MenuToolButton, Gtk2::Ex::History::Dialog, Gtk2::Ex::MenuView, Gtk2::Ex::Dashes::MenuItem
HOME PAGE
http://user42.tuxfamily.org/gtk2-ex-history/index.html
LICENSE
Gtk2-Ex-History is Copyright 2010, 2011 Kevin Ryde
Gtk2-Ex-History is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.
Gtk2-Ex-History is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with Gtk2-Ex-History. If not, see http://www.gnu.org/licenses/.
Module Install Instructions
To install Gtk2::Ex::History, copy and paste the appropriate command in to your terminal.
cpanm Gtk2::Ex::History
perl -MCPAN -e shell install Gtk2::Ex::History
For more information on module installation, please visit the detailed CPAN module installation guide.