Learning Shoes - Have some questions!

Hello All,

I recently started playing with Shoes to learn it during my Ruby
learning journey.
It appears to be easy, although the current doc is not what a beginner
like I would prefer.
googling around I found a nice website,
http://shoes-tutorial-note.heroku.com/, which has some nice simple
samples programs, just what beginners, like I, need.
On my learning, I heavely borrowed from a program, simple-calc.rb,
listed on the tutorial mentioned above. I hope the developer of this
pgm does not get upset.
I have some questions which I would like help with.

First, should I post Shoes questions to shoes@librelist.org or should
my questions go to ruby-talk@ruby-lang.org? or Both? I tried
subscribing to shoes@librelist.org but it was impossible!
I am attaching my image so you can analyze it and comment on it. The
image was rejected by the ruby forum. I can send it to whoever would
like to see it to comment on it.

1 - When placing a number of buttons, such as the ones found in a
calculator, how can I tell Shoes to place them on the center of the
pane, without having to specify margin?

       flow :width => "100%", :margin => 58 do
               %w(7 8 9 + sin 4 5 6 - cos 1 2 3 * sinh tan cot 0 ln /
cosh Exp log
tanh = Mod n! sqrt x*2 x*y % e Pi Clr Ce).each do |btn|
                       button btn, :width => 46, :height => 46 do
                               method = case btn
                                       when /[0-9]/; 'press_'+btn
                                       when '+'; 'press_add'
                                       when '-'; 'press_sub'
                                       when '*'; 'press_times'
                                       when '/'; 'press_div'
                                       when '='; 'press_equals'

        ect, etc, etc
                               end # case
                       end # button do
               end # each do
       end # flow

2 - I am using a stack do with nothing inside (between the do and the
end) to keep items within a flow one on top of the other, is there a
different way to do this?
       flow :margin => 6 do
               radio; para strong("512b BK")
               radio; para strong("1K BK")
               radio; para strong("MB")
               radio; para strong("GB")
               radio; para strong("TB")

               stack do
               # I am using this as a way to stack up groups.
               # There might be a much better way!
               end

               radio; para strong("Deg")
               radio; para strong("Rad")
               radio; para strong("Grad")
               radio; para strong("DEC")
               radio; para strong("HEX")
               radio; para strong("BIN")
       end # flow

3 - I tried to use the Pi symbol and the square root (√) symbol and
other symbols as caption/lable for the corresponding buttons, but I
got an errors or the wrong thing displayed. Is there a way to
accomplish this?

4 - It looks like I can achieve the same function with para and
caption. What is the difference between the two?

5 - How can I reduce the space between flows?

Thank you for your help!

···

--
Ruby Student

I recently started playing with Shoes to learn it during my Ruby
learning journey.
It appears to be easy, although the current doc is not what a beginner
like I would prefer.

Hey, thanks for trying out Shoes! What would make the documentation better
for you?

I hope the developer of this

pgm does not get upset.

I have some questions which I would like help with.

Absolutely not. Feedback is the only way that things get better.

First, should I post Shoes questions to shoes@librelist.org or should

my questions go to ruby-talk@ruby-lang.org? or Both?

You're free to post questions to both, but you'll get better help from
shoes@librelist.org. I try to pay attention to ruby-talk, but sometimes I
miss threads. I read everything on the shoes-specific list. I don't think
I've seen any of the other core team members post to Ruby-talk, either.

I tried

subscribing to shoes@librelist.org but it was impossible!

Could you elaborate more on what you mean by 'it was impossible?' or is that
what's in this image you're talking about? feel free to mail it to me
off-list.

1 - When placing a number of buttons, such as the ones found in a

calculator, how can I tell Shoes to place them on the center of the

pane, without having to specify margin?

Does this help? http://shoes.heroku.com/manual/Styles.html#:align

2 - I am using a stack do with nothing inside (between the do and the

end) to keep items within a flow one on top of the other, is there a

different way to do this?

I'm not sure of exactly what you're asking. Maybe a screenshot would help?

3 - I tried to use the Pi symbol and the square root (√) symbol and

other symbols as caption/lable for the corresponding buttons, but I

got an errors or the wrong thing displayed. Is there a way to

accomplish this?

Are you using Shoes 2 or Shoes 3? They use 1.8 and 1.9, respectively, and so
there might be some encoding issues based on which one you're using.

4 - It looks like I can achieve the same function with para and

caption. What is the difference between the two?

I am not sure, off the top of my head.

5 - How can I reduce the space between flows?

I'm not sure about this one, either...

···