How to find out the resolution of the monitor before starting a Ruby-Gnome widget?

Hi,

I wish to set the start-size of my widget to 80% of width and height.

But for this, I need to know the resolution of the computer.

Is this doable?

Found it in the API docu:

x = Gdk::Screen.default
x.width
x.height