0

I want to have an interface that allows to draw links between boxes and save the results (box1 is connected to box2, 3 to 4 and so on) as shown in the picture below:

enter image description here

I do not really know where to start or even if something like this already exists or if it is possible - so I am grateful for any comment on the subject?

petermeissner
  • 12,234
  • 5
  • 63
  • 63
  • 1
    There is nothing in `gWidgets` here. You might look at the canvas widget in tcltk. Others will send you to javascript, e.g., the canvas widget within a webpage. – jverzani Jun 13 '13 at 14:18

1 Answers1

1

The HTkIdentify function in the TeachingDemos package allows you to interactively drag labels to new locations (and part of the return is the coordinates of the new locations) with a line between the point and the label. Visually I think this is similar to what you are asking for. It uses the tcltk package rather than gwidgets. You could modify the code to draw your boxes as above (rather than a data based scatterplot), then based on the final locations of the "labels" you would determine which box was connected to.

Greg Snow
  • 48,497
  • 6
  • 83
  • 110
  • puh, informative as this answer is, I think this is way to much afford -- I was looking for something more within a already existing framework like those widgets. I do not want to draw something I want to connect boxes put I suppose this idea is not common enough for a out of the box solution. – petermeissner Jun 18 '13 at 13:57