[Kde-bindings] Re: kdebindings/qtruby (silent)

Alexander Kellett lypanov at kde.org
Sat Aug 2 13:46:29 UTC 2003


On Wed, Jul 30, 2003 at 01:45:21PM +0100, Richard Dale wrote:
> On Wednesday 30 July 2003 15:03, Alexander Kellett wrote:
> > so, wrt the methods problem (i.e, multiple methods with same
> > name and different signature), is that likely to be fixed
> > soon? (assuming that its not already fixed?) it would be
> > really nice to be able to create popupmenus ;-)
> >
> Yes, it should work - I haven't tried popups yet. If you have a problem, then 
> the method that does the matching is this one in Qt.rb:
> 		def argmatch(methodIds, args, i)

oh. aah. this is fixed with your kde cvs import, 
attached is a app using it. maybe interesting,
doesn't do much yet though :)

> There is some perl code halfway down the method, I haven't converted to ruby 
> yet:
> 
> 				elsif argtype == 's'
> ..
> 				elsif argtype == 'a'
> ..
> 
> So a useful thing to do would be to convert it to ruby - I hadn't got round to 
> reading about how ruby reg exp pattern segmenting works yet.

wow, those regexps are wierd. i'll try to 
figure them out later tomorrow evening, its
just code after all :)

> Yes, top of the to do list, is writing a to do list :). 

hehe ;-)

> The original RubyQt bindings needed both a require and 
> an include, but when I looked at the gtk bindings they 
> just needed a require. 

a interesting. to tell you the truth, i like the
ruby-ish ness of the Qt:: namespace sans the Q prefix
on the objects them selves. it is very nice that the 
PerlQt documentation should prove to be a good beginner 
doc for new qtruby programmers, so, i'd say stick with 
mirroring PerlQt personally.

> Do the slots and signals declarations 'look right'? 

yes. though noticed a bug. you can't have two slots
declarations, can't recall if it overwrites or just
doesn't work at all though.

> <snip some already answered q's>
>
> How do I get the name to appear on the window when a app is running like 
> PerlQt does?

i'll give this a try tomorrow.

> Adapt puic to create a rbuic tool (I was going to do that next I think

juic looks quite well done. haven't checked fully but
seperation between language and "parsing" looks fairly
complete. only problem is, i hate xslt :), but, i'd 
like to learn how to make a simple xslt processor with
ruby. so maybe i'll take a look at writing the ruby 
replacement for bin/juic :)

> Yes, the marshalling code would need another two actions like DCOPtoVALUE and 
> DCOPfromVALUE, and I think it should fit in quite nicely - see handlers.cpp - 
> just bigger case statements. If you look at the class hierachy, nearly 
> everything is a subclass of Marshaller - we'd need new classes called 
> 'SendDCOP' and 'ReceiveDCOP' or similar.

those are actually all marshalled with qtextstream
iirc, so, it should be fairly easy. i'm wondering
how much work it is to get working kde bindings 
using kalyptus/smoke in its current state?

Alex


More information about the Kde-bindings mailing list