RMagicK image.display does not return immediately

I am using RMagicK for Ruby to draw and display images. The problem is
that after:

img = rvg.draw()

control is not returned to the caller immediately. The user has to
manually close the window for the program to continue. How can I bypass
this behavior?