# Copyright (c) 1995-1999 Nick Ing-Simmons. All rights reserved.
# This program is free software; you can redistribute it and/or
# modify it under the same terms as Perl itself.
# This module does for images what Tk::Widget does for widgets:
# provides a base class for them to inherit from.
use base
qw(DynaLoader Tk); # but are they ?
$VERSION = '3.014'; # $Id: //depot/Tk8/Tk/Image.pm#14 $
$package->InitClass($widget);
my $leaf = $package->Tk_image;
my $obj = $widget->Tk::image('create',$leaf,@_);
return bless $obj,$package;
# Dynamically loaded image types can install standard images here
# Carry out class bindings (or whatever)
Direct Tk::Submethods ('image' => [qw(delete width height type)]);
sub Tk
::Widget
::imageNames
sub Tk
::Widget
::imageTypes
map("\u$_",$w->image('types',@_));
my $class = (caller(0))[0];
# Hack for broken ->isa in perl5.6.0
delete ${"$class\::"}{'::ISA::CACHE::'} if $] == 5.006;
*{"Tk::Widget::$name"} = sub { $class->new(@_) };
# This is here to prevent AUTOLOAD trying to find it.
# maybe do image delete ???