UI::Dialog::Backend(3pm) | User Contributed Perl Documentation | UI::Dialog::Backend(3pm) |
NAME
UI::Dialog::Backend - simply a collection of primarily internal methods.
SYNOPSIS
use UI::Dialog::Backend; BEGIN { use vars qw( @ISA ); @ISA = qw( UI::Dialog::Backend ); }
ABSTRACT
UI::Dialog::Backend is simply a collection of primarily internal methods.
DESCRIPTION
While this module is inherited by all UI::Dialog backend modules, this module itself is not meant for direct usage. The "STATE METHODS" and "UTILITY METHODS" documentation is applicable to all backends thus rendering the POD for this class more important to the end-programmer than the usage of the class itself.
EXPORT
INHERITS
BACKEND EXTENSIONS
nautilus
my @paths = $d->nautilus->paths();
- DESCRIPTION
xosd
$d->xosd->line( "a line of text on your screen" );
- DESCRIPTION
notify_send
$d->notify_send->notify_send( "a line of text on your screen" );
- DESCRIPTION
STATE METHODS
attr( )
my $value = $self->attr('listheight'); my $new_value = $d->attr('listheight',5);
- DESCRIPTION
state( )
if ($d->state() eq "OK") { # the last user response was "OK" } else { # something other than an "OK" response }
- DESCRIPTION
ra( )
my @array = $d->ra();
- DESCRIPTION
rs( )
my $string = $d->rs();
- DESCRIPTION
rv( )
my $string = $d->rv();
- DESCRIPTION
CALLBACK FUNCTIONS
PRE
sub CB_PRE { my $widget_args = shift(); print "Caller: ".$args->{'caller'}."\n"; } my $d = new UI::Dialog ( callbacks => { PRE => \&CB_PRE } );
- DESCRIPTION
POST
sub CB_POST { my $widget_args = shift(); my $state = shift(); print "Caller: ".$args->{'caller'}.", State: ".$state."\n"; } my $d = new UI::Dialog ( callbacks => { POST => \&CB_POST } );
- DESCRIPTION
OK
sub CB_OK_FUNC { my $widget_args = shift(); print "Widget caller: ".$args->{'caller'}."\n"; } my $d = new UI::Dialog ( callbacks => { OK => \&CB_OK_FUNC } );
- DESCRIPTION
CANCEL
sub CB_CANCEL { my $widget_args = shift(); print "Caller: ".$args->{'caller'}."\n"; } my $d = new UI::Dialog ( callbacks => { CANCEL => \&CB_CANCEL } );
- DESCRIPTION
ESC
sub CB_ESC { my $widget_args = shift(); print "Caller: ".$args->{'caller'}."\n"; } my $d = new UI::Dialog ( callbacks => { ESC => \&CB_ESC } );
- DESCRIPTION
HELP
sub CB_HELP { my $widget_args = shift(); print "Caller: ".$args->{'caller'}."\n"; } my $d = new UI::Dialog ( callbacks => { HELP => \&CB_HELP } );
- DESCRIPTION
EXTRA
sub CB_EXTRA { my $widget_args = shift(); print "Caller: ".$args->{'caller'}."\n"; } my $d = new UI::Dialog ( callbacks => { EXTRA => \&CB_EXTRA } );
- DESCRIPTION
UTILITY METHODS
beep( )
$d->beep();
- DESCRIPTION
clear( )
$d->clear();
- DESCRIPTION
word_wrap( )
my @wrapped_text = $d->word_wrap($cols,$indent,$sub_indent,@text);
- DESCRIPTION
gen_tempfile_name( )
my $tempfile = $d->gen_tempfile_name();
- DESCRIPTION
gen_random_string( )
my $random_string = $d->gen_random_string(5);
- DESCRIPTION
WIDGET WRAPPER METHODS
These methods are common methods to most backends as they do not have native support for the functionality, yet the functionality is achievable by utilizing existing compatible methods.
fselect( )
my $path = $self->fselect( path => $start_path );
- DESCRIPTION
dselect( )
my $path = $self->dselect( path => $start_path );
- DESCRIPTION
BACKEND METHODS
These methods are only necessary for someone wishing to create more UI::Dialog::Backend:: Modules. These are never needed to be directly used but are none the less documented here for reference purposes.
command_state( )
if ($self->command_state("/some/shell/command")) { #: command succeeded } else { #: command failed }
- DESCRIPTION
command_string( )
my ($rv,$scalar) = $self->command_string("/some/shell/command"); if ($rv >= 1) { #: command failed } else { #: command succeeded print "The command results: ".$scalar."\n"; }
- DESCRIPTION
command_array( )
my ($rv,@array) = $self->command_array("/some/shell/command"); if ($rv >= 1) { #: command failed } else { #: command succeeded foreach my $line_of_output (@array) { print "The command results: ".$line_of_output."\n"; } }
- DESCRIPTION
_pre( )
my $args = $self->_pre(@_);
- DESCRIPTION
_post( )
$self->_post( $args );
- DESCRIPTION
_merge_attrs( )
my $args = $self->_merge_attrs(@_);
- DESCRIPTION
_find_bin( )
my $ZenityBinaryPath = $self->_find_bin('zenity');
- DESCRIPTION
_esc_text( )
my $escaped_text = $self->_esc_text( $raw_text );
- DESCRIPTION
Character -> Escaped " \" ` \` ( \( ) \) [ \[ ] \] { \} } \} $ \$ < \< > \>
_strip_text( )
my $clean_text = $self->_strip_text( $text_with_markup );
- DESCRIPTION
_organize_text( )
my $final_text1 = $self->_organize_text( $text_with_markup ); my $final_text2 = $self->_organize_text( \@text_with_markup );
- DESCRIPTION
_is_bsd( )
if ($self->_is_bsd()) { # do something with BSD specific characteristics } else { # do something with general perl characteristics }
- DESCRIPTION
_list_dir( )
my $menu_list = $self->_list_dir( '/some/path/to/a/directory', [ 'optional', 'prefix', 'items' ] );
- DESCRIPTION
_debug( )
$self->_debug( $debuging_message_string, $debuging_level );
- DESCRIPTION
_error( )
$self->_error( $error_message_string );
- DESCRIPTION
SEE ALSO
- PERLDOC
-
UI::Dialog UI::Dialog::Console UI::Dialog::GNOME UI::Dialog::KDE UI::Dialog::Backend::ASCII UI::Dialog::Backend::CDialog UI::Dialog::Backend::GDialog UI::Dialog::Backend::KDialog UI::Dialog::Backend::Nautilus UI::Dialog::Backend::Whiptail UI::Dialog::Backend::XDialog UI::Dialog::Backend::XOSD UI::Dialog::Backend::Zenity
- MAN FILES
-
dialog(1), whiptail(1), zenity(1), gdialog(1), Xdialog(1), kdialog(1), nautilus(1) and osd_cat(1).
BUGS
Please email the author with any bug reports. Include the name of the module in the subject line.
AUTHOR
Kevin C. Krinke, <kevin@krinke.ca>
COPYRIGHT AND LICENSE
Copyright (C) 2004-2016 Kevin C. Krinke <kevin@krinke.ca> 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
2018-10-27 | perl v5.28.0 |