From: nagai@... Date: 2002-06-07T10:34:48+09:00 Subject: Re: tk question Hi, From: MENON Jean-Francois Subject: Re: tk question Date: Thu, 6 Jun 2002 20:38:50 +0900 Message-ID: <3CFF49C1.33CE86EC@meteo.fr> > but I am afraid this does not help me. I want to distribute my app > under gpl for any platform and I can't ask users to modify their ruby's > installation ( in fact it's already difficult to ask them to install > ruby at all :-<) If user's Ruby/Tk returns no error for "TkPackage.require('Tix')", he doesn't need to modify their Ruby. Extract needed classes from Tix.rb included tcltk-ext, and add them to your application. # Of course, need "TkPackage.require('Tix')" after "require 'tk'". :-) If you want to use Balloon, use TixBalloon class. The class-tree of TixBalloon is TkWindow +-- TixInputOnly +-- TixPrimitive +-- TixShell +-- TixBalloon Therefore, add TixInputOnly, TixPrimitive, TixShell, and TixBalloon to your application. Then you can use Balloon widget in your application. e.g. TkButton.new(nil, 'text'=>'hello', 'command'=>proc{print "hello\n"}) {|b| TixBalloon.new(nil, 'initwait'=>200, 'state'=>'balloon') { bind(b, 'balloonmsg'=>'Balloon Help') } pack('fill'=>'x') } Tk.mainloop -- Hidetoshi NAGAI (nagai@ai.kyutech.ac.jp)