Class PictureFrame

java.lang.Object
PictureFrame

public class PictureFrame extends Object
Class that holds a digital picture and displays it. Copyright Georgia Institute of Technology 2004
  • Constructor Summary

    Constructors
    Constructor
    Description
    A constructor that takes no arguments.
    A constructor that takes a picture to display
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    A method to close a picture frame
    void
    A method to make sure the frame is displayed
    void
    A method to hide the frame
    void
    Method to force the picture frame to repaint (redraw)
    void
    Method to set the picture to show in this picture frame
    void
    Method to set the title for the picture frame
    void
    setVisible(boolean flag)
    A method to set the visible flag on the frame
    void
    A method to update the picture frame image with the image in the picture
    void
    A method to update the picture frame image with the image in the picture and show it

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PictureFrame

      public PictureFrame()
      A constructor that takes no arguments. This is needed for subclasses of this class
    • PictureFrame

      public PictureFrame(DigitalPicture picture)
      A constructor that takes a picture to display
      Parameters:
      picture - the digital picture to display in the picture frame
  • Method Details

    • setPicture

      public void setPicture(Picture picture)
      Method to set the picture to show in this picture frame
      Parameters:
      picture - the new picture to use
    • updateImage

      public void updateImage()
      A method to update the picture frame image with the image in the picture
    • updateImageAndShowIt

      public void updateImageAndShowIt()
      A method to update the picture frame image with the image in the picture and show it
    • displayImage

      public void displayImage()
      A method to make sure the frame is displayed
    • hide

      public void hide()
      A method to hide the frame
    • setVisible

      public void setVisible(boolean flag)
      A method to set the visible flag on the frame
      Parameters:
      flag - the flag to use
    • close

      public void close()
      A method to close a picture frame
    • setTitle

      public void setTitle(String title)
      Method to set the title for the picture frame
      Parameters:
      title - the title to use
    • repaint

      public void repaint()
      Method to force the picture frame to repaint (redraw)