GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Gtk2::Ex::Dialogs::Message(3) User Contributed Perl Documentation Gtk2::Ex::Dialogs::Message(3)

Gtk2::Ex::Dialogs::Message - Provides a simple message dialog.

 use Gtk2::Ex::Dialogs::Message ( destroy_with_parent => TRUE,
                                  modal => TRUE,
                                  no_separator => FALSE );

 # do some stuff like creating your app's main $window then,
 # to ensure that all messages use the right parent, set it:
 $Gtk2::Ex::Dialogs::Message::parent_window = $window;

 # now popup a new dialog ( blocking the main loop if there is one )
 new_and_run
  Gtk2::Ex::Dialogs::Message ( title => "Dialog Title",
                               text => "This is a simple message" );

 # now popup a somwhat useful dialog that doesn't block any main loop
 # but on the other side of the coin, if there is no main loop the
 # dialog will be completely unresponsive.
 new_show
  Gtk2::Ex::Dialogs::Message ( title => "Uhm",
                               text => "Use when there is a main loop." );

This module provides a simple dialog api that wraps Gtk2::Dialog objectively. The objective is a clean and simple message dialog (only an "OK" button).

All public methods (and the entire class) support the following options:
title => STRING
The title of the dialog window. Defaults to an empty string.
text => STRING
The text to be displayed. This is the core purpose of the module and is the only mandatory argument.
icon => /path/to/image || stock-id || Gtk2::Gdk::Pixbuf || Gtk2::Image
The dialog-sized image to place to the left of the text. Note: there are five aliased stock-ids which correspond to the five gtk-dialog-* ids, "warning", "question", "info", "error" and "authentication". Defaults to no icon being created at all.
parent_window => Gtk2::Window
Reference to the main application window.
destroy_with_parent => BOOL
When the parent_window is destroyed, what do we do? Defaults to FALSE.
modal => BOOL
Does this message make the parent_window freeze while the message exists. Defaults to FALSE.
no_separator => BOOL
Draw the horizontal separator between the content area and the button area below. Defaults to FALSE.

OBJECT = new ( OPTIONS | STRING )
Create a new Gtk2::Dialog with only an "OK" button, some text and an optional icon to the left of the text. The icon can be any of the following: a stock-id string, a Gtk2::Image, Gtk2::Gdk::Pixbuf or the full path to an image. Return a Gtk2::Ex::Dialogs::Message object. In the special case of being passed only one argument, all options are set to defaults and the one argument is used as the text option.
new_and_run ( OPTIONS )
Supports all the same arguments as new(). This will create a new Gtk2::Ex::Dialogs::Message, show_all(), run() and then destroy the dialog immediately.
new_and_show ( OPTIONS )
Supports all the same arguments as new(). This will create a new Gtk2::Ex::Dialogs::Message, show_all() and process any pending gtk events. This functionality is only of any practical use when there is a Gtk2 main loop running. If there is no main loop running the dialog will be visible but completely unresponsive to the end-user.

 Gtk2::Dialog
 Gtk2::MessageDialog
 Gtk2::Ex::Dialogs
 Gtk2::Ex::Dialogs::ChooseDirectory
 Gtk2::Ex::Dialogs::ChooseFile
 Gtk2::Ex::Dialogs::ChoosePreviewFile
 Gtk2::Ex::Dialogs::ErrorMsg
 Gtk2::Ex::Dialogs::Message

Please report any bugs to the mailing list.

 http://opendoorsoftware.com/lists/gtk2-ex-list
 gtk2-ex-list@opendoorsoftware.com

 Kevin C. Krinke, <kckrinke@opendoorsoftware.com>
 James Greenhalgh, <jgreenhalgh@opendoorsoftware.com>

 Gtk2::Ex::Dialogs::Message - Provides a simple message dialog.
 Copyright (C) 2005 Open Door Software Inc. <ods@opendoorsoftware.com>

 This library is free software; you can redistribute it and/or
 modify it under the terms of the GNU Lesser General Public
 License as published by the Free Software Foundation; either
 version 2.1 of the License, or (at your option) any later version.

 This library 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
 Lesser General Public License for more details.

 You should have received a copy of the GNU Lesser General Public
 License along with this library; if not, write to the Free Software
 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
2006-01-11 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.