# What is the WxRuby equivalent to Grid in Tk

**URL:** <https://www.ruby-forum.com/t/what-is-the-wxruby-equivalent-to-grid-in-tk/115495>\
**Category:** Ruby\
**Created:** [September 25, 2007, 7:49pm UTC](https://www.ruby-forum.com/t/what-is-the-wxruby-equivalent-to-grid-in-tk/115495 "2007-09-25T19:49:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jayson](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/aeb1de/32.png) [@jayson](https://www.ruby-forum.com/u/jayson)\
**Post date:** [September 25, 2007, 7:49pm UTC](https://www.ruby-forum.com/t/what-is-the-wxruby-equivalent-to-grid-in-tk/115495/1 "2007-09-25T19:49:25Z")

</div>

Hi All,  
What is the equivalent to Grid in Tk, for WxRuby? I see in the  
documentation references to Sizers, but I cant quite figure out how to  
use them, or if this is what I should be using.

Thanks  
Jayson

---

<div class="post-metadata">

**Author:** ![jayson](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/aeb1de/32.png) [@jayson](https://www.ruby-forum.com/u/jayson)\
**Post date:** [September 25, 2007, 8:47pm UTC](https://www.ruby-forum.com/t/what-is-the-wxruby-equivalent-to-grid-in-tk/115495/2 "2007-09-25T20:47:36Z")

</div>

Jayson W. wrote:

> What is the equivalent to Grid in Tk, for WxRuby? I see in the  
> documentation references to Sizers, but I cant quite figure out how to  
> use them, or if this is what I should be using.

I don’t know what Grid does in Tk, but there are two possibilities:

There is Wx::Grid, which is a fancy spreadsheet-like widget for editing  
cells

There are various flavours of Wx::Sizer, which are for creating layouts  
which resize in response to Frames being resized. There’s a GridSizer  
and FlexiGridSizer in there.

There are tutorials for both these on the Wiki:  
[http://wxruby.rubyforge.org/wiki/wiki.pl?WxRuby\_Tutorial](http://wxruby.rubyforge.org/wiki/wiki.pl?WxRuby_Tutorial)

And if you look in your wxruby “samples” directory (in your lib/gems  
tree), there’s also samples of the use of both (look in samples/bigdemo/  
for examples of Sizer use).

The wxruby-users list is a good place to get advice on this sort of q:  
[http://rubyforge.org/mail/?group\_id=35](http://rubyforge.org/mail/?group_id=35)

hth  
alex
