[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-perl
Subject: Re: [Kde-perl] PerlQt-3.006
From: Ashley Winters <jahqueel () yahoo ! com>
Date: 2003-02-14 21:16:06
[Download RAW message or body]
--- Stéphane Payrard <stef@payrard.net> wrote:
> On Fri, Feb 14, 2003 at 06:47:16PM +0000, Germain Garand wrote:
> I notice some insconsistency probably in thw way of creating widgets
> (probablt because I am using an unsupported idiom, not ever an
> optimal one).
> Standard Qt widget can be created using $a->constructor while mine
> can't. See file attached
>
> $a = Qt::Application;
> ...
> my $mw = $a->MainWindow();
> ...
> $a->LineEdit($vb); # works
> $a->MyLineEdit($vb); # does not work
There goes the law of unintended consequences. I did *not* expect
people to try that. And, yes, it would be possible to let
custom-created widgets do that as well. *shiver*
In Qt::isa::import, just do something like...
*{"Qt::$caller"} = sub { $caller->new(@_) };
I dunno if I'd accept that patch, though. Give it a try.
> Finally, could the 'use Qt::isa ...' pull the Qt stuff if 'use Qt'
> has
> not already done it.
Umm... try something like this at the very of Qt::isa::import.
Untested, so let me know how it works. :)
goto &Qt::import unless exists &{$caller . "::SLOT"};
Scary stuff, Stéphane
Ashley Winters
__________________________________________________
Do you Yahoo!?
Yahoo! Shopping - Send Flowers for Valentine's Day
http://shopping.yahoo.com
_______________________________________________
Kde-perl mailing list
Kde-perl@mail.kde.org
http://mail.kde.org/mailman/listinfo/kde-perl
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic