Tk.update

Please is anyone able to guide me to what I am missing ? tk update seems to have vanished from the Ruby versions after Ruby 1.8.1 eg tktext.update tkentry.update etc. I have an older app complaining about this.

art

Hi,

···

From: karibou <me@privacy.net>
Subject: tk.update
Date: Tue, 27 Jul 2004 00:21:52 +0900
Message-ID: <2mklm1Fo00tdU1@uni-berlin.de>

Please is anyone able to guide me to what I am missing ? tk update seems
to have vanished from the Ruby versions after Ruby 1.8.1 eg
tktext.update tkentry.update etc. I have an older app complaining about
this.

The 'update' method calls Tcl/Tk's 'update' command.
The command does NOT depend on a widget. So, I think, it isn't
proper that widget objects have the 'update' instance method.
If you add the following definition to Tk module or TkWindow class,
your applications will work.
--------------------------------------------
  def update(idle=nil)
    Tk.update(idle)
    self # maybe useful
  end
--------------------------------------------
I'll add the definition to Tk module for backward compatibility.
But I don't recommend you to use this method.
--
                                  Hidetoshi NAGAI (nagai@ai.kyutech.ac.jp)

Hi,

Trying to compile the stabe snapshot (28.7.) of ruby with gcc 3.4.1
produces this error:

    make[1]: Entering directory `/home/mccramer/tmp/ruby/ext/stringio'
    gcc -fPIC -O3 -mtune=athlon-xp -mcpu=athlon-xp -mfpmath=sse -funroll-loops -fforce-addr -falign-functions=4 -mpreferred-stack-boundary=2 -msse -m3dnow -mmmx -fPIC -I. -I/home/mccramer/tmp/ruby -I/home/mccramer/tmp/ruby -I/home/mccramer/tmp/ruby/ext/stringio -c stringio.c
    gcc -shared -L"/home/mccramer/tmp/ruby" -o stringio.so stringio.o -lruby -ldl -lcrypt -lm -lc
    make[1]: Leaving directory `/home/mccramer/tmp/ruby/ext/stringio'
    compiling tcltklib
    /home/mccramer/tmp/ruby/lib/mkmf.rb:500:in `find_library': wrong argument type String (expected Proc) (TypeError)
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:496:in `checking_for'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:465:in `postpone'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:170:in `open'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:170:in `postpone'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:166:in `open'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:166:in `postpone'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:465:in `checking_for'
            from /home/mccramer/tmp/ruby/lib/mkmf.rb:496:in `find_library'
            from /home/mccramer/tmp/ruby/ext/tcltklib/extconf.rb:221
            from ./ext/extmk.rb:77:in `load'
            from ./ext/extmk.rb:77:in `extmake'
            from ./ext/extmk.rb:224
            from ./ext/extmk.rb:221:in `glob'
            from ./ext/extmk.rb:221
    make: *** [all] Error 1
    [ruby/] :gcc --version
    gcc (GCC) 3.3.4
    Copyright (C) 2003 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions. There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

What did I wrong here ?

Ruby.use!
Meino

Hidetoshi NAGAI wrote:

Hi,

From: karibou <me@privacy.net>
Subject: tk.update
Date: Tue, 27 Jul 2004 00:21:52 +0900
Message-ID: <2mklm1Fo00tdU1@uni-berlin.de>

Please is anyone able to guide me to what I am missing ? tk update seems to have vanished from the Ruby versions after Ruby 1.8.1 eg tktext.update tkentry.update etc. I have an older app complaining about this.

The 'update' method calls Tcl/Tk's 'update' command. The command does NOT depend on a widget. So, I think, it isn't proper that widget objects have the 'update' instance method. If you add the following definition to Tk module or TkWindow class, your applications will work. --------------------------------------------
  def update(idle=nil)
    Tk.update(idle)
    self # maybe useful
  end
--------------------------------------------
I'll add the definition to Tk module for backward compatibility. But I don't recommend you to use this method.

Thank you that is helpfull, I see I will need to re-think the code now.

Hi,

···

In message "Compiling problems" on 04/07/28, Meino Christian Cramer <Meino.Cramer@gmx.de> writes:

Trying to compile the stabe snapshot (28.7.) of ruby with gcc 3.4.1
produces this error:

It was caused by a bug in the snapshot. I fixed the bug today.

              matz.

Hi Matz,

Thanks a lot! :slight_smile:

I will download the stable snashot of 2007-07-29...is
that ok?

Ruby.use!
Meino

···

From: matz@ruby-lang.org (Yukihiro Matsumoto)
Subject: Re: Compiling problems
Date: Wed, 28 Jul 2004 22:28:54 +0900

Hi,

In message "Compiling problems" > on 04/07/28, Meino Christian Cramer <Meino.Cramer@gmx.de> writes:

> Trying to compile the stabe snapshot (28.7.) of ruby with gcc 3.4.1
> produces this error:

It was caused by a bug in the snapshot. I fixed the bug today.

              matz.