view release on metacpan or search on metacpan
bin/mdi_editor view on Meta::CPAN
use warnings;
use Tk;
#########################################
# First define the content manager. a content manager handles the basic tasks like loading, saving,
# displaying and modifying files. The content manager does the actual work.
package TextManager;
use base qw(Tk::Derived Tk::AppWindow::BaseClasses::ContentManager);
Construct Tk::Widget 'TextManager';
require Tk::TextUndo;
sub Populate {
my ($self,$args) = @_;
$self->SUPER::Populate($args);
my $text = $self->Scrolled('TextUndo',
-scrollbars => 'ose',
)->pack(-expand => 1, -fill => 'both');
bin/simple_editor view on Meta::CPAN
use warnings;
use Tk;
#########################################
# First define the content manager. a content manager handles the basic tasks like loading, saving,
# displaying and modifying files. The content manager does the actual work.
package TextManager;
use base qw(Tk::Derived Tk::AppWindow::BaseClasses::ContentManager);
Construct Tk::Widget 'TextManager';
require Tk::TextUndo;
sub Populate {
my ($self,$args) = @_;
$self->SUPER::Populate($args);
my $text = $self->Scrolled('TextUndo',
-scrollbars => 'ose',
)->pack(-expand => 1, -fill => 'both');
lib/Tk/AppWindow.pm view on Meta::CPAN
Tk::AppWindow - An application framework based on Tk
=cut
use strict;
use warnings;
use Carp;
use vars qw($VERSION);
$VERSION="0.22";
use base qw(Tk::Derived Tk::MainWindow);
Construct Tk::Widget 'AppWindow';
use File::Basename;
require Tk::AppWindow::BaseClasses::Callback;
require Tk::Balloon;
require Tk::DynaMouseWheelBind;
require Tk::FilePicker;
require Tk::QuickForm;
require Tk::YAMessage;
use Tk::PNG;
lib/Tk/AppWindow/BaseClasses/ContentManager.pm view on Meta::CPAN
=cut
use strict;
use warnings;
use Carp;
use vars qw($VERSION);
$VERSION="0.20";
use Tk;
use base qw(Tk::Derived Tk::Frame);
Construct Tk::Widget 'ContentManager';
use File::Basename;
=head1 SYNOPSIS
#This is useless
require Tk::AppWindow::BaseClasses::ContentManager;
my $handlerplug = $app->ContentManager->pack;
#This is what you should do
package MyContentHandler
use base qw(Tk::Derived Tk::AppWindow::BaseClasses::ContentManager);
Construct Tk::Widget 'MyContentHandler';
=head1 DESCRIPTION
This is an opaque base class to help you create a content manager for your application.
It is Tk::Frame based and you can inherit it as a Tk mega widget;
The methods below are used by the extensions MDI and SDI. It is for you to make
them do the right stuff by overriding them.
lib/Tk/AppWindow/CookBook.pod view on Meta::CPAN
use warnings;
################################################################
# First define the content manager. a content manager handles #
# the basic tasks like loading, saving, displaying and #
# modifying files. The content manager does the actual work. #
################################################################
package ImageManager;
use base qw(Tk::Derived Tk::AppWindow::BaseClasses::ContentManager);
Construct Tk::Widget 'ImageManager';
require Tk::Pane;
require Tk::Photo;
use Tk::PNG;
use File::Basename;
use MIME::Base64;
use Imager;
#Determining which image types we can use;
my %photoext = ();
lib/Tk/AppWindow/CookBook/ContentManager.pod view on Meta::CPAN
=back
=head1 A SIMPLE TEXT CONTENT MANAGER
package TextManager;
use strict;
use warnings;
use base qw(Tk::Derived Tk::AppWindow::BaseClasses::ContentManager);
Construct Tk::Widget 'TextManager';
require Tk::TextUndo;
sub Populate {
my ($self,$args) = @_;
$self->SUPER::Populate($args);
my $text = $self->Scrolled('TextUndo',
-scrollbars => 'ose',
lib/Tk/AppWindow/PluginsForm.pm view on Meta::CPAN
Tk::AppWindow::PluginsForm - Load and unload plugins.
=cut
use strict;
use warnings;
use vars qw($VERSION);
$VERSION = '0.07';
use base qw(Tk::Derived Tk::Frame);
Construct Tk::Widget 'PluginsForm';
require Tk::LabFrame;
require Tk::Pane;
use Data::Compare;
=head1 DESCRIPTION
This package is a L<Tk::Frame> based megawidget.
t/200-Tk-AppWindow-Ext-Settings.t view on Meta::CPAN
package MyLabel;
use strict;
use warnings;
use base qw(Tk::Derived Tk::Label);
Construct Tk::Widget 'MyLabel';
sub Apply {
print "Apply\n";
}
package main;
use strict;
use warnings;
use lib './t/lib';
t/lib/Alternative/NameSpace.pm view on Meta::CPAN
=head1 DESCRIPTION
This is for testing only. Yes, you read me, for TESTING. Didn't you hear me say? TESTING! TESTING! TESTING!
=cut
use strict;
use warnings;
use Carp;
use base qw(Tk::Derived Tk::AppWindow);
Construct Tk::Widget 'NameSpace';
sub Populate {
my ($self,$args) = @_;
$self->geometry('800x600+150+150');
my %opts = (
-extensions => [qw[Art Daemons ToolBar StatusBar MenuBar SideBars Selector Settings Plugins]],
-namespace => 'Alternative::NameSpace',
t/lib/TestTextManager.pm view on Meta::CPAN
package TestTextManager;
use Tk;
use base qw(Tk::Derived Tk::AppWindow::BaseClasses::ContentManager);
Construct Tk::Widget 'TestTextManager';
require Tk::TextUndo;
sub Populate {
my ($self,$args) = @_;
$self->SUPER::Populate($args);
my $text = $self->Scrolled('TextUndo',
)->pack(-expand => 1, -fill => 'both');
$self->CWidg($text);
t/lib/Tk/AppWindow/Ext/Dummy.pm view on Meta::CPAN
#package MyLabel;
#
#use strict;
#use warnings;
#
#use base qw(Tk::Derived Tk::Label);
#Construct Tk::Widget 'PluginsForm';
#
#sub Apply {
# print "Apply\n";
#}
#
#package main;
package Tk::AppWindow::Ext::Dummy;
t/lib/Tk/AppWindow/Ext/TestPlugin.pm view on Meta::CPAN
#package MyLabel;
#
#use strict;
#use warnings;
#
#use base qw(Tk::Derived Tk::Label);
#Construct Tk::Widget 'PluginsForm';
#
#sub Apply {
# print "Apply\n";
#}
#
#package main;
package Tk::AppWindow::Ext::TestPlugin;