PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Programmation & Conception > comp.lang.ruby > [ANN] update Ruby/Tk for Ruby(1.9|1.8) and Tcl/Tk8.5
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
[ANN] update Ruby/Tk for Ruby(1.9|1.8) and Tcl/Tk8.5

Réponse
 
LinkBack Outils de la discussion
Vieux 29/03/2008, 08h02   #1
Hidetoshi NAGAI
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut [ANN] update Ruby/Tk for Ruby(1.9|1.8) and Tcl/Tk8.5

Hi,

I committed updates of Ruby/Tk on SVN trunk and ruby_1_8.
Now, almost all part of Ruby/Tk will work with Ruby 1.9.
It's a large change (e.g. the diff-file from previous Ruby 1.8 release
has over 20,000 lines) to support Tcl/Tk8.5 features.
Probably, it has some (many?) bugs.
If you find bugs or have feature request, please send it on this ML.

The most important change is "default widget set is switchable
between standard Tk and Ttk (Tile) extension".

As default, for example, TkButton denotes Tk::Button which is a
standard Tk widget. But after calling "Tk.default_widget_set = :Ttk",
TkButton denotes Tk::Tile::TButton which is a Ttk (Tile) widget.
And calling "Tk.default_widget_set = :Tk", TkButton denotes a
standard Tk widget again.
It means that you can use Ttk widgets on your old Ruby/Tk script.

Of course, supported options of each Ttk widgets are different from
standard Tk widgets. If you use such options (e.g. activeforeground)
on your script, Ttk widgets raise exception about unknown options.

So, I implemented a little danger method:
"TkConfigMethod.__set_IGNORE_UNKNOWN_CONFIGURE_OPT ION__!(mode)".
If mode is true, "configure" method ignores unknown options.
Although it may raise other troubles, it increases the number of
scripts which work with Ttk widgets.

To try this feature, I added an example "ttk_wrapper.rb" in
"ext/tk/sample" directory.
Please see the usage by "ruby ttk_wrawwper.rb -h"
For example, "ruby ttk_wrapper.rb -t blue tkhello.rb" shows you
a "tkhello.rb" example window but styled by "blue" theme.

I'm very sorry, but this change will not be included into ruby
1.8.7 release. I'm late for the release schedule of 1.8.7.
If you want it for your ruby 1.8, please get it from SVN.
--
Hidetoshi NAGAI (nagai@ai.kyutech.ac.jp)

  Réponse avec citation
Vieux 30/03/2008, 19h09   #2
Hidetoshi NAGAI
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: [ANN] update Ruby/Tk for Ruby(1.9|1.8) and Tcl/Tk8.5

Hi,

From: Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp>
Subject: [ANN] update Ruby/Tk for Ruby(1.9|1.8) and Tcl/Tk8.5
Date: Sat, 29 Mar 2008 16:02:07 +0900
Message-ID: <20080329.160205.74727689.nagai@ai.kyutech.ac.jp >
> I committed updates of Ruby/Tk on SVN trunk and ruby_1_8.


If you use Tcl/Tk stubs (--enable-tcltk-stubs),
latest comitted version of tcltkilb seems to cause SEGV.
I'm very sorry, but please don't use Tcl/Tk stubs until
the bug will be fixed.
--
Hidetoshi NAGAI (nagai@ai.kyutech.ac.jp)

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 23h05.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 1,24968 seconds with 10 queries