Hi, been doing Jruby for server side purposes however I now have a
project which entails a desktop GUI and mobile app. I do like Apache
Flex but want to keep especially client side domain logic in Ruby and
thus I’m thinking about evaluating Jruby for GUI building. I’ve read the
books but i would appreciate if somebody would be kind enough to remind
me which of the Jruby guy frameworks is most amenable to using Gui
design tools and in particular the GUI design tool within Jetbrains
IDEA.
Hi, well I figured so but my point is that instead of following the
Swing API I was hoping to a perhaps more productive frameworks e.g.
MonkeyBars but I believe that those frameworks require you to layout by
hand. So if I do want to use a GUI design tool it seems I just have to
follow the Swing API. As you point out thanks to Jruby that api does not
have to be as painful as it would in raw Java. Furthermore,Swing is a
mature and maintained framework which Is important as well.
I would prefer to use Apache Flex for building of thin GUIs but I do
need client side business logic which I would want to maintain in Ruby.
Thus unless I find a convenient bridge between Flex and Jruby locally it
seems I need to revisit the idea of doing Swing for GUI building.
Hi, well I figured so but my point is that instead of following the
Swing API I was hoping to a perhaps more productive frameworks e.g.
MonkeyBars but I believe that those frameworks require you to layout by
hand.
No. Monkeybars was designed to play especially well with compiled Java
Swing code, such as what you can generate using the Netbeans WYSIWYG
editor. I’ve help build quite complex desktop programs with Monkeybars
and making the UI with by-hand Swing code would have been torture.
So long as you follow some basic naming conventions (because of some
dynamic lookups) you are good to go.
You can do the GUI part by hand for Monkeybars if you want.
Sometimes it is is easier to just define the UI using basic Swing and,
say, the MiG layout jar. That was the motivation behind Swingset-NG: to
offer a simple API for basic UI to avoid having to pop open Netbeans or
something just to create an “About” form or something.
The choice is yours either way. Larger programs benefit from using a
GUI editor to generate the Java or .class files to be used with the
Monkeybars controller and model files.
Excellent ! I had read the section on MonkeyBars from one of the Jruby Pragmatic
Bookshelf books a while back but now this is coming up to the front burner. I use
IDEA so would prefer to use their GUI builder. I siuspect that MonkeyBars doesn’t
have any bias for Matisse. I’ll re -read the MonkeyBars section and I guess go
back on to the site to look for examples where the GUI builder output i.e. Swing
compiled output is used.
If you have a direct link or further sources of example code that I could look
at , it would be appreciated.
Excellent ! I had read the section on MonkeyBars from one of the Jruby
Pragmatic Bookshelf books a while back but now this is coming up to the
front burner. I use IDEA so would prefer to use their GUI builder. I
siuspect that MonkeyBars doesn’t have any bias for Matisse. I’ll re
-read the MonkeyBars section and I guess go back on to the site to look
for examples where the GUI builder output i.e. Swing compiled output is
used.
If you have a direct link or further sources of example code that I
could look at , it would be appreciated.
It is the only active JRuby GUI project I am aware of that truly follows the Ruby way while supporting bidirectional data-binding, scaffolding and native-executable packaging (e.g. DMG/PKG on the Mac and EXE/MSI on Windows).
Example syntax:
include Glimmer
shell {
text "Glimmer"
label {
text "Hello, World!"
}
}.open
1 Like
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.