# Simplification for ruby-gnome2 in general: the use of symbols rather than Gtk:: Enum Structures?

**URL:** <https://www.ruby-forum.com/t/simplification-for-ruby-gnome2-in-general-the-use-of-symbols-rather-than-gtk-enum-structures/242576>\
**Category:** Ruby-Gnome 2\
**Created:** [July 3, 2015, 8:40pm UTC](https://www.ruby-forum.com/t/simplification-for-ruby-gnome2-in-general-the-use-of-symbols-rather-than-gtk-enum-structures/242576 "2015-07-03T20:40:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Detlef\_R](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/58f4c7/32.png) [@Detlef\_R](https://www.ruby-forum.com/u/Detlef_R)\
**Post date:** [July 3, 2015, 8:40pm UTC](https://www.ruby-forum.com/t/simplification-for-ruby-gnome2-in-general-the-use-of-symbols-rather-than-gtk-enum-structures/242576/1 "2015-07-03T20:40:03Z")

</div>

Hi,

I was looking at old ruby-gnome code that I have here  
and see stuff like this:

```
notebook = Gtk::Notebook.new
notebook.set_tab_pos(Gtk::POS_LEFT)

```

However, it occurred to me that knowing Gtk::POS\_LEFT  
seems superfluous.

We are using Ruby, not a lower level language here, so  
I was thinking, this could be this:

```
notebook.set_tab_pos(:left)

```

And internally get mapped to Gtk::POS\_LEFT right?

Now I don’t know if this would be good or bad, so I  
am just making it as a suggestion - perhaps noone  
was thinking about it so far.

I understand that the C API is the main target,  
but I wonder if we could use additional constructs  
to make the code more ruby-like (just as we  
have methods such as set\_foo() and also foo= )
