Last modified 14 years ago Last modified on 01/22/09 17:29:43



The Main Window is one of the basic GUI elements.

Task requirements

To create the APP_MAIN_WINDOW, application must provide extension points for:

  • Layout Components
    • Flaps
      • Left Flap
      • Right Flap
      • Bottom Flap
  • Book Desktop
  • Menu Bar
  • Status Bar

Requirements to the task result

The result of this task must be code.

Main Window

App Elements

How to demo

Start the application show the layout, change the layout, stop the application, and then start it again. The new configuration must be preserved.


  • For general information of the design see the specification pages => Specification
  • Status bar is not defined yet and is not clear what it will contain and how it will work. We will leave it for later revisions.
  • Here is simple explanation of the main window of sophie2. We will briefly show how the window is constructed and what are its parts.
  • Implementation details are provided by the following diagrams.
  • The main window of sophie2 is represented by the AppView class. UML Diagram:


  • It consists of left, right and bottom flaps, a books' desktop, a title bar and a menu bar.
    • Here is a hierarchy of the flaps in sophie2:


  • Every flap is attachable and detachable. One can obtain this functionality by using the attach(...) and detach(...) methods.
  • Every flap in sophie2 should extend the base flap class.
  • One should override the attach and detach methods to have e flap of his own.
  • One should also provide a method to add tabs to the flap. Typically the addChildren() method.
  • Here is a diagram of the Book's desktop classes. These are the classes that combined construct the desktop.


  • The JDesktopPane and JScrollPane are Swing classes we extend to add functionalities to serve out needs.
  • The DockableDesktopScroll is a JScrollPane and a Dockable. This gives us the opportunity to add the BookDesktop to the main window.
  • The DesktopPane is added to the DockableDesktopScroll and books are added in it.
    • One can add visual representations of books ( JInternalFrame ).
    • Books can be tiled and cascaded using the tileFrames() and cascadeFrames() methods.
    • Size of the BookDesktop is settable.
  • DesktopManager class is a helper class for the DesktopPane to handle its desktop-like actions.
  • The MenuBar class is responsible for the Menu Bar part of the Main Window. Here is its diagram:


  • Its visual representation is created and items are added.
  • Every item is represented by the MenuMember class. MenuMembers have tool-tips, icons, titles etc. Menus and MenuItems are also MenuMembers depending whether the members of the main menu are sub-menus or items.
  • CheckBoxMenuItem is a menu item with a check box that provides selected() functionality.


Implementation is done according to design. Here is a list of the classes as source code:


User documentation

Give links to the created or modified wiki pages containing the user documentation for this task. Note that user documentation is a kind of help system.

Release documentation

Here you should describe shortly what feature is released

Manual tests

IDs of test cases in our testlink instance

Main tests

Testlink test ids: 745

Related tests

These are already existing test cases(from previous iterations) that won't be chaged but their outcome may change by what is done in this task

Testlink test ids: comma separated list of ids

Reported bugs

Give links to the tickets of the bugs found during testing


  • Analyzing : Tanya, todor - 35 min
    • Review: 3.5 by Pav - 10 mins

The links to the diagrams isn't working.

  • Designing : Peko 4h - done
  • Implementing : Peko 3.5h - done
    • Review: 4 by Pavlina - 20 mins
  • Testing :