Class AboutDialog

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants

public class AboutDialog extends JDialog
A dialog that displays information about the demonstration application.
See Also:
  • Field Details

    • PREFERRED_SIZE

      public static final Dimension PREFERRED_SIZE
      The preferred size for the frame.
    • STANDARD_BORDER

      public static final Border STANDARD_BORDER
      The default border for the panels in the tabbed pane.
    • resources

      private ResourceBundle resources
      Localised resources.
    • application

      private String application
      The application name.
    • version

      private String version
      The application version.
    • info

      private String info
      Other info about the application.
    • contributors

      private List contributors
      A list of contributors.
    • licence

      private String licence
      The licence.
  • Constructor Details

    • AboutDialog

      public AboutDialog(String title, ProjectInfo project)
      Constructs an about frame.
      Parameters:
      title - the frame title.
      project - information about the project.
    • AboutDialog

      public AboutDialog(Frame owner, String title, ProjectInfo project)
      Creates a non-modal dialog without a title with the specifed Frame as its owner.
      Parameters:
      owner - the Frame from which the dialog is displayed.
      title - the title,
      project - the project.
    • AboutDialog

      public AboutDialog(Dialog owner, String title, ProjectInfo project)
      Creates a non-modal dialog without a title with the specifed Dialog as its owner.
      Parameters:
      owner - the Dialog from which the dialog is displayed.
      title - the title.
      project - the project.
  • Method Details

    • init

      private void init(String title, String application, String version, String info, Image logo, String copyright, String licence, List contributors, ProjectInfo libraries)
      Constructs an 'About' frame.
      Parameters:
      title - the frame title.
      application - the application name.
      version - the version.
      info - other info.
      logo - an optional logo.
      copyright - the copyright notice.
      licence - the licence.
      contributors - a list of developers/contributors.
      libraries - a list of libraries.
    • getPreferredSize

      public Dimension getPreferredSize()
      Returns the preferred size for the about frame.
      Overrides:
      getPreferredSize in class Container
      Returns:
      the preferred size.
    • createTabs

      private JTabbedPane createTabs(ProjectInfo info)
      Creates a tabbed pane containing an about panel and a system properties panel.
      Parameters:
      info - project information.
      Returns:
      a tabbed pane.
    • createAboutPanel

      private JPanel createAboutPanel(ProjectInfo info)
      Creates a panel showing information about the application, including the name, version, copyright notice, URL for further information, and a list of contributors.
      Parameters:
      info - project info.
      Returns:
      a panel.
    • createLicencePanel

      private JPanel createLicencePanel()
      Creates a panel showing the licence.
      Returns:
      a panel.