com.lowagie.rups.controller
Class RupsController

java.lang.Object
  extended by java.util.Observable
      extended by com.lowagie.rups.controller.RupsController
All Implemented Interfaces:
PageSelectionListener, EventListener, TreeSelectionListener

public class RupsController
extends Observable
implements TreeSelectionListener, PageSelectionListener

This class controls all the GUI components that are shown in the RUPS application: the menu bar, the panels,...


Field Summary
protected  JSplitPane masterComponent
          Contains all other components: the page panel, the outline tree, etc.
protected  RupsMenuBar menuBar
          The JMenuBar for the RUPS application.
protected  PdfFile pdfFile
          The Pdf file that is currently open in the application.
protected  PdfReaderController readerController
          Object with the GUI components for iText.
 
Constructor Summary
RupsController(Dimension dimension)
          Constructs the GUI components of the RUPS application.
 
Method Summary
 Component getMasterComponent()
          Getter for the master component.
 RupsMenuBar getMenuBar()
          Getter for the menubar.
 int gotoPage(int pageNumber)
          Goes to a specific page number in a document.
 void notifyObservers(Object obj)
           
 void valueChanged(TreeSelectionEvent evt)
           
 
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, setChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

pdfFile

protected PdfFile pdfFile
The Pdf file that is currently open in the application.


readerController

protected PdfReaderController readerController
Object with the GUI components for iText.

Since:
iText 5.0.0 (renamed from reader which was confusing because reader is normally used for a PdfReader instance)

menuBar

protected RupsMenuBar menuBar
The JMenuBar for the RUPS application.


masterComponent

protected JSplitPane masterComponent
Contains all other components: the page panel, the outline tree, etc.

Constructor Detail

RupsController

public RupsController(Dimension dimension)
Constructs the GUI components of the RUPS application.

Method Detail

getMenuBar

public RupsMenuBar getMenuBar()
Getter for the menubar.


getMasterComponent

public Component getMasterComponent()
Getter for the master component.


notifyObservers

public void notifyObservers(Object obj)
Overrides:
notifyObservers in class Observable
See Also:
Observable.notifyObservers(java.lang.Object)

valueChanged

public void valueChanged(TreeSelectionEvent evt)
Specified by:
valueChanged in interface TreeSelectionListener
See Also:
TreeSelectionListener.valueChanged(javax.swing.event.TreeSelectionEvent)

gotoPage

public int gotoPage(int pageNumber)
Description copied from interface: PageSelectionListener
Goes to a specific page number in a document.

Specified by:
gotoPage in interface PageSelectionListener
Returns:
the resulting page number. Can be different from pageNumber if pageNumber doesn't exist.
See Also:
PageSelectionListener.gotoPage(int)

Hosted by Hostbasket