Getting started with full sized apps... how?

L

Lloyd Linklater

Ok. First, I should say that I think highly of the Ruby language. I
have written cool snippets and life is good. I should say that I have
developed in many languages currently focused on Delphi.

Now, when I write an app, I make an interface that has things for the
user to see with buttons to push and keep him playing happily. I find
that, without a regular interface, I am somewhat at a loss for making
usable applications. I am not any more interested in a purely command
line approach now than I was when i was writing batch files to do it all
for me.

That having been said, I am not finding the golden path to making
wonderful ruby apps with no easy interface. Even practicing with the
language is problematic as I never seem to write methods longer than a
couple dozen lines and that doth not an app make.

So, as someone that wants to get as much mileage out of ruby as everyone
else seems to be getting, where do I start? What kinds of things are
being done by those that say that their apps are all but running the
universe itself?

Where to I go to get a start on the larger side of ruby?

Thanks for any advice you can offer.
 
L

Lloyd Linklater

Jason said:
I guess the best advice one can give is to ask questions. Give yourself
a
project that you know will make you dive into more of the language's
features and don't be afraid to admit that you don't know.

Well, therein lies the rub. If I were to start with something in a new
language, say Delphi for the sake of argument, I might make a form, put
an edit box for user name and a push button, and say hello to the name
in the box. With something like that, I can build and make anything I
can dream up in the language.

I see nothing analogous in ruby (yet). I do not want to have command
line prompts that get ever more convoluted as the app progresses. I
need help finding the forest (the app). Trees (snippets and methods), I
can make.
 
M

Morton Goldberg

Now, when I write an app, I make an interface that has things for the
user to see with buttons to push and keep him playing happily. I find
that, without a regular interface, I am somewhat at a loss for making
usable applications. I am not any more interested in a purely command
line approach now than I was when i was writing batch files to do
it all
for me.

Pick one of Ruby GUI libraries and go with it. Currently, I'm using
Ruby/Tk, which has it pluses and minuses, but does the job. But the
are quite a few others out there to choose from.
That having been said, I am not finding the golden path to making
wonderful ruby apps with no easy interface. Even practicing with the
language is problematic as I never seem to write methods longer than a
couple dozen lines and that doth not an app make.

Can't agree with this sentiment. Long methods do not an application
make. Applications are made by choosing the appropriate class
libraries, implementing a set of classes that model the problem
domain, providing the appropriate behavior to objects instantiated
from those classes by implementing methods (usually short) which are
highly leveraged on the class libraries. My methods tend to average
well under your "couple dozen lines".

Regards, Morton
 
B

Bira

So you're talking about IDEs and form builders? If you want to work with a
GUI, I'd suggest getting wxRuby: http://wxruby.rubyforge.org/wiki/wiki.pl

There's no drag-and-drop WYSIWYG editor that I know of, but you really don't
need one, and it doesn't facilitate learning how to use the language
effectively.

Well, if you use GTK as your GUI library, there's Glade. You can build
an interface with Glade and them hook it up to a Ruby program using
ruby-libglade2.
 
M

Morton Goldberg

Where to I go to get a start on the larger side of ruby?

You might get some ideas from Ruby Quizzes 5, 104, and 129. The
participants in these quizzes implemented modest but complete
applications using a variety of UI techniques, both GUI and CL. I
mention these particular quizzes because I'm familiar with them.
There may be (and probably are) other quizzes that qualify as
complete applications by your standards.

http://www.rubyquiz.com/index.html

Regards, Morton

P.S. You might consider Rails.
 
J

John Joyce

Indeed you should consider the web interface of Rails, GUI
interfaces: tk, wx,
even bridges RubyCocoa (write OS X apps in Ruby) for which there must
be a Windows analog.
Delphi is really not a language as much as a framework around a
language, isn't it?
 
L

Lloyd Linklater

Morton said:
Can't agree with this sentiment. Long methods do not an application
make. Applications are made by choosing the appropriate class
libraries, implementing a set of classes that model the problem
domain, providing the appropriate behavior to objects instantiated
from those classes by implementing methods (usually short) which are
highly leveraged on the class libraries. My methods tend to average
well under your "couple dozen lines".

Well, I agree and I should clarify, therefore. The methods I write that
are a couple dozen lines or less are as far as I have ever taken ruby.
Applications require lots of such things stitched together into a whole.
Methods should be as terse as possible and, in the case of something
lengthy, they should be broken into smaller "bite sized" chunks which
makes things go better overall.

John said:
Delphi is really not a language as much as a framework around a
language, isn't it?

Well, as Borland was pretty much the only real supporter of Pascal,
they, that is to say Anders H., did whatever he wanted with the language
making it unique. However, with the advent of the new management of
CodeGear, what you say is even more true as there is a Delphi for PHP
and they will be releasing a Ruby IDE in the near future.

This is what I was looking for. Thanks all! I will get on this ASAP.
:)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,051
Latest member
CarleyMcCr

Latest Threads

Top