Selecting appropriate widgets -- advice please

I’m planning a fairly simple application to build while learning GNOME &
GTK with Ruby. I could use some help in choosing the appropriate
widgets.

I want to draw several boxes, containing text and joined by lines –
something like a Data F. Diagram or Entity Relation diagram. The user
will be able to create new boxes, edit the text and move them around.
The lines will be redrawn to maintain the relationships. It isn’t unlike
Dia, but will be highly specialised and much simpler.

Which widgets should I use for the “canvas” and the “boxes”? Will I have
to do the D&D myself the hard way? And all my drawing, with everything
in DrawingAreas?


Mike Wilson, Wrexham, North Wales, UK
www.whisperingwind.co.uk

Send instant messages to your online friends


Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net’s Techsay panel and you’ll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

On So, 2006-11-19 at 09:08 +0000, Mike Wilson wrote:

D&D myself the hard way? And all my drawing, with everything in DrawingAreas?

Hi,

most programs use the Gnome::Canvas for tasks like this. But the
Gnome::Canvas in ruby-gnome is not documented at all.

An other possibility is to use Gtk::Layout. On this you can place other
widgets and you can also draw grafics on it. I did it this way from C
for a similar program and it worded well.

Cheers
detlef


Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net’s Techsay panel and you’ll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

Detlef R. wrote:

Which widgets should I use for the “canvas” and the “boxes”? Will I have to do the

I might also suggest taking a look at Cairo [www.cairographics.org] (and
rcairo). It gives you some drawing primitives, but not must else so you
would have to implement most of the interaction yourself. As an
example, I use it in Grism (www.grism.org) to draw the stock charts.

Cheers,
Nick


Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net’s Techsay panel and you’ll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV