--------------enig58F8C50638EF55325EC3474E Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Richard Conroy wrote: > On 11/11/06, David Vallner <david / vallner.net> wrote: >> AliasX Neo wrote: >> > Windows users, what do you do to develop GUI's for Ruby? >> > >> >> Handcode / use Python. > > I am curious, but is handcoding Ruby UIs in whatever (Tk by default) > a significant amount of work? > I honestly haven't really tried. Gtk and Tk sort of put me off, since the former seems to lack data binding, and the latter is just weird - I could never get the layout right, and those pretty much the only stable crossplatform GUI toolkits available. > Consider doing the equivalent in Java Swing as a frame of reference? > (painful but do-able). > However, from having used the pre-rewrite wxRuby bindings, it was fairly doable. Blocks-as-callbacks usually seem to hide most of the ugliness you'd see futzing around with Gtk callbacks in C, and most of the frameworks seem to follow roughly the same paradigm of nesting horizontal and vertical layouts / splitters, as opposed to Swing's layout managers. (Of which only the simple ones were meant for human consumption anyway, the messier SpringLayout was to be generated by a form designer since that's where a UI designer would more probably want to use constraints between elements.) > Basically, I like the idea of making simple UIs in Ruby for test tools,nd software that you don't sell. > Maybe Tk, since it's part of the stdlib, even if it has a weird approach to scrolling, and personally I'd go with Wx if the rewrite gets Stable Enough. On Windows, Gtk still looks disappointing, has to be installed, and overall tries to pretend there's a Linux underneath - installing the pre-rewrite Wx was a matter of dropping the wxruby.so into C:\Ruby\lib\ruby\site_ruby\1.8\i386-msvcrt, which scores the people major points in the Just Works category. Also, most of Gtk example code is in C, and their object-oriented C API is... byzantine to say the least, and I find it hard to mentally map into Ruby. This is less of a problem for a C++ based framework. Since Tk bindings almost always seem to involve writing Tcl with an alternate syntax, there's another double-edged sword there. Code examples are easily translated, but at least to me, they look out of place in Ruby. Qt seems more designed to play nicely with the form designer. For larger projects, that's a Good Thing - you can happily let a dedicated UI designer take care of that and the programmers can concentrate on the controlling code. The downside is that while it could be possible to handcode it easily, at least I couldn't find much exhaustive online material as to how. David Vallner --------------enig58F8C50638EF55325EC3474E Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (MingW32) iD4DBQFFWkgsy6MhrS8astoRAnV8AJ9DM6ea5Nz/lCMiKmq8gM9ihVK80wCXSqYC T1SbDa4icJrCJZ6+OhYJWQ
7G -----END PGP SIGNATURE----- --------------enig58F8C50638EF55325EC3474E--