Adding background image to JGoView canvas

I want to add a background image to JGoView canvas.

  1. Is this possible?
  2. Does the image need to be added to the view or the JGoDocument
    Thanks!

You have some choices:

  • call JGoView.setBackgroundImage
  • override JGoView.paintBackgroundDecoration
  • create a JGoImage and add it to a layer in your JGoDocument (presumably in the layer that is farthest back!)
    Setting the BackgroundImage property just displays the image at the point (0, 0) of document coordinates. The other choices allow you to move the image around and size it the way you want.
    The first two choices only show the image in the one view; the last one allows the image to be shown in all views on the document.
    In all cases the image will be scrolled and zoomed as the value of as calls to JGoView.setViewPosition and setScale occur.