GUI and ruby

I would like to create an interface GUI with ruby. What I have to use? I would like that the GUI could be used in win, osx and linux. Is there a good interface builder?

ulazar wrote:

I would like to create an interface GUI with ruby. What I have to use? I would like that the GUI could be used in win, osx and linux. Is there a good interface builder?

If you want to design it yourself, I think you can use Ruby/Tk, FoxGUI, wxWidgets and Shoes. A drag-and-drop interface for designing GUI is WideStudio. It takes a little getting used to, but it can do quite a bit of stuff!

Cheers,
Mohit.
11/18/2007 | 5:46 PM.

I had a similar question regarding which library to use. After talking
to people and reading various posts and articles I reached a
conclusion that I have to choose between Tk and GTK2. Tk+Ruby seems to
have more resources on the web but GTK2+Ruby looks better and
apparently is more easily customizable (custom drawn widgets was
easier to create). I've personally chosen GTK2.

Check this out:
http://ruby-gnome2.sourceforge.jp/hiki.cgi

Regarding a good interface builder I have much less experience. I code
the interface definitions myself.

FireAphis

···

On Nov 18, 11:17 am, ulazar <ula...@XXXtin.it> wrote:

I would like to create an interface GUI with ruby. What I have to use? I
would like that the GUI could be used in win, osx and linux. Is there a
good interface builder?

I suggest you check out wxRuby. There are several interface builders - free and commercial. DialogBlocks w/ the wxWidgets XRC resource systems seems to be liked.

HTH

Alec

···

In message <DqT%i.172462$%k.312379@twister2.libero.it>, ulazar <ulazar@XXXtin.it> writes

I would like to create an interface GUI with ruby. What I have to use? I would like that the GUI could be used in win, osx and linux. Is there a good interface builder?

--
Alec Ross

ulazar wrote:

I would like to create an interface GUI with ruby. What I have to use? I
would like that the GUI could be used in win, osx and linux. Is there a
good interface builder?

I had good success with qtruby. I had been using qt 3.5.x and kdevelop.
Although my focus was entirely on linux it also seems to also run on win
and osx.

Regards
Werner

Glade. Ruby + Gtk2 + glade make UIs a breeze.

-jh

···

On Sun, 18 Nov 2007 03:52:25 -0800 (PST) FireAphis <FireAphis@gmail.com> wrote:

On Nov 18, 11:17 am, ulazar <ula...@XXXtin.it> wrote:
> I would like to create an interface GUI with ruby. What I have to use? I
> would like that the GUI could be used in win, osx and linux. Is there a
> good interface builder?

I had a similar question regarding which library to use. After talking
to people and reading various posts and articles I reached a
conclusion that I have to choose between Tk and GTK2. Tk+Ruby seems to
have more resources on the web but GTK2+Ruby looks better and
apparently is more easily customizable (custom drawn widgets was
easier to create). I've personally chosen GTK2.

Check this out:
http://ruby-gnome2.sourceforge.jp/hiki.cgi

Regarding a good interface builder I have much less experience. I code
the interface definitions myself.

FireAphis wrote:

I would like to create an interface GUI with ruby. What I have to use? I
would like that the GUI could be used in win, osx and linux. Is there a
good interface builder?

I had a similar question regarding which library to use. After talking
to people and reading various posts and articles I reached a
conclusion that I have to choose between Tk and GTK2. Tk+Ruby seems to
have more resources on the web but GTK2+Ruby looks better and
apparently is more easily customizable (custom drawn widgets was
easier to create). I've personally chosen GTK2.

Check this out:
http://ruby-gnome2.sourceforge.jp/hiki.cgi

Regarding a good interface builder I have much less experience. I code
the interface definitions myself.

FireAphis

If I am to lazy to write it myself (particually a problem with C++... hehe) I
usually use QT Designer to create the GUI and make use of tools from qtruby to
convert it into Ruby code (rather then C++). Test it and when it's 'good
enough' I start work on prototyping the implementation code.

I like GTK+ programs but I have never used it for programming beyond tutorials
in C though. So I wouldn't know much about how GTK+ works with Ruby.

Cheers.

···

On Nov 18, 11:17 am, ulazar <ula...@XXXtin.it> wrote:

--
    
Email and shopping with the feelgood factor!
55% of income to good causes. http://www.ippimail.com

Hello --

···

On 18/11/2007, Jonathan Hudson <jh+ruby-lang@daria.co.uk> wrote:

Glade. Ruby + Gtk2 + glade make UIs a breeze.

I don't mind Tk -- that has the advantage of being in the core, too.

-- Thomas Adam

Shoes although quiet new, looks like a really fun GUI toolkit to use.
http://code.whytheluckystiff.net/shoes/
And the code is compatible for all three platforms you require.

···

On Nov 18, 2007 9:30 PM, Terry Poulin <bigboss64@ippimail.com> wrote:

FireAphis wrote:
> On Nov 18, 11:17 am, ulazar <ula...@XXXtin.it> wrote:
>> I would like to create an interface GUI with ruby. What I have to use?
I
>> would like that the GUI could be used in win, osx and linux. Is there a
>> good interface builder?
>
> I had a similar question regarding which library to use. After talking
> to people and reading various posts and articles I reached a
> conclusion that I have to choose between Tk and GTK2. Tk+Ruby seems to
> have more resources on the web but GTK2+Ruby looks better and
> apparently is more easily customizable (custom drawn widgets was
> easier to create). I've personally chosen GTK2.
>
> Check this out:
> http://ruby-gnome2.sourceforge.jp/hiki.cgi
>
> Regarding a good interface builder I have much less experience. I code
> the interface definitions myself.
>
> FireAphis
>
>

If I am to lazy to write it myself (particually a problem with C++...
hehe) I
usually use QT Designer to create the GUI and make use of tools from
qtruby to
convert it into Ruby code (rather then C++). Test it and when it's 'good
enough' I start work on prototyping the implementation code.

I like GTK+ programs but I have never used it for programming beyond
tutorials
in C though. So I wouldn't know much about how GTK+ works with Ruby.

Cheers.

--

Email and shopping with the feelgood factor!
55% of income to good causes. http://www.ippimail.com

Yeah. Actually that is its biggest advantage. You have to download a
bunch of libraries from different sources to make Gtk2 run with ruby.
It took me a while to configure all the components correctly (well, in
my case I needed some more libraries than usually required). Tk on the
other hand is already there, ready to be used. If your GUI is small
and practical Tk is excellent.

FireAphis

···

On Nov 18, 2:06 pm, Thomas Adam <thomas.ada...@gmail.com> wrote:

Hello --

On 18/11/2007, Jonathan Hudson <jh+ruby-l...@daria.co.uk> wrote:

> Glade. Ruby + Gtk2 + glade make UIs a breeze.

I don't mind Tk -- that has the advantage of being in the core, too.

-- Thomas Adam

Does it have good support for Mac OS X PPC? I know that it works on Intel, but last time I checked, PPC was still non functional.

···

On Nov 18, 2007, at 11:06 PM, Piyush Ranjan wrote:

Shoes although quiet new, looks like a really fun GUI toolkit to use.
http://code.whytheluckystiff.net/shoes/
And the code is compatible for all three platforms you require.

apt-get ruby-gnome (ubuntu et al)

pkg_add -r ruby18-gnome2-all.tgz (FreeBSD)

wget / unzip
http://ruby-gnome2.sourceforge.jp/?News_20070212_1#Same+as+ruby-gtk2-0.16.0-1-i386-msvcrt-1.8.zip
(win32)

wget / dpkg -i
http://maemo.rubyx.co.uk/ruby-maemo/Packages/maemo3/armel/ruby1.8-maemo_0.3.0-1_maemo3_armel.deb
(maemo / Nokia N800 / N810)

Granted it's possibly somewhat harder for OSX, partially due to the old
GTK installed by default.

OTOH, one time I tried to track down all the Tk dependencies for
Win32 .... maybe that's also fixed now.

Anyway, personal prejudices aside, there's a pretty good comparison of
UI toolkits at <http://kylecordes.com/2007/03/31/ruby-gui-toolkits/&gt;

-jonathan

···

On Sun, 18 Nov 2007 04:18:32 -0800 (PST) FireAphis <FireAphis@gmail.com> wrote:

On Nov 18, 2:06 pm, Thomas Adam <thomas.ada...@gmail.com> wrote:
> Hello --
>
> On 18/11/2007, Jonathan Hudson <jh+ruby-l...@daria.co.uk> wrote:
>
> > Glade. Ruby + Gtk2 + glade make UIs a breeze.
>
> I don't mind Tk -- that has the advantage of being in the core, too.
>
> -- Thomas Adam

Yeah. Actually that is its biggest advantage. You have to download a
bunch of libraries from different sources to make Gtk2 run with ruby.
It took me a while to configure all the components correctly (well, in
my case I needed some more libraries than usually required). Tk on the
other hand is already there, ready to be used. If your GUI is small
and practical Tk is excellent.

There are PPC/universal builds. But unless you test it yourself you
can't tell if it's good enough :wink:

Thanks

Michal

···

On 19/11/2007, thefed <fedzor@gmail.com> wrote:

On Nov 18, 2007, at 11:06 PM, Piyush Ranjan wrote:

> Shoes although quiet new, looks like a really fun GUI toolkit to use.
> http://code.whytheluckystiff.net/shoes/
> And the code is compatible for all three platforms you require.
>

Does it have good support for Mac OS X PPC? I know that it works on
Intel, but last time I checked, PPC was still non functional.

Jonathan Hudson wrote:

Anyway, personal prejudices aside, there's a pretty good comparison of
UI toolkits at <http://kylecordes.com/2007/03/31/ruby-gui-toolkits/&gt;

...which is already dated. Some GUI toolkits have evolved alot during the last half-year.

I would recommend that you try the latest versions of all the toolkits and see which of them is most likely to fit your needs.

Best regards,

Jari Williamsson

I've used shoes and straight GTK2 for for ruby. Both are great
options, but I lean more towards GTK (sorry why). Mind you I've done
only the simplest of guis for my ruby stuff so far :slight_smile:

I've never used glade with it though... Can you use the standard
glade interface designer for ruby-glade apps?

--Kyle

Hello,

Kyle Schmitt schrieb:

I've never used glade with it though... Can you use the standard
glade interface designer for ruby-glade apps?

yes you can, the Glade Interface Designer creates standard
.glade-XML-files which can be used by all(?) GTK implementations such as
the ruby one. For the ruby one you can simply "click" your design and
chose the events and afterwards you can use the script
"ruby-glade-create-template" which is included into the ruby gnome2
package to create a default ruby file with included .glade file and
Gettext support. The events are predefined as methods so you only have
to type in what should be done when clicking a button for example.
In my opinion thats really easy!

Janek

···

--
Besuch doch auch meine Websites
http://blog.jbbr.net/ | Mein Blog
http://php4you.de/ | Webseite zum Thema PHP

Very nice. I'll have to try that for my next project!

Thanks.
--Kyle

···

On Nov 19, 2007 12:11 PM, Janek Thomaschewski <janek@php4you.de> wrote:

Hello,

Kyle Schmitt schrieb:
> I've never used glade with it though... Can you use the standard
> glade interface designer for ruby-glade apps?

yes you can, the Glade Interface Designer creates standard
.glade-XML-files which can be used by all(?) GTK implementations such as
the ruby one. For the ruby one you can simply "click" your design and
chose the events and afterwards you can use the script
"ruby-glade-create-template" which is included into the ruby gnome2
package to create a default ruby file with included .glade file and
Gettext support. The events are predefined as methods so you only have
to type in what should be done when clicking a button for example.
In my opinion thats really easy!

Janek