Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Multivalent API
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## multivalent.std.ui
Class Multipage

    java.lang.Object
      multivalent.VObject
          multivalent.Behavior
              multivalent.std.ui.Multipage

public class Multipage
extends Behavior

Interface for paginated document types to choose page number (next, previous, first, last, enter number). Common code shared by multipage media adaptors (`edu.berkeley.adaptor.Xdoc`, `tex.dvi.DVI`, `PDF`). Uses `Document.ATTR_PAGE` and `Document.ATTR_PAGECOUNT`.

Version:
  $Revision: 1.8 $ $Date: 2002/03/07 00:56:23 $
See Also:
  `PersonalAnnos`, `MediaAdaptor`

Field Summary
`static java.lang.String` | `MSG_CLOSEPAGE` Close current document page, giving other behaviors a chance to save state before moving to a new page or different document.
`static java.lang.String` | `MSG_FIRSTPAGE` Move to the first page of a multipage document.
`static java.lang.String` | `MSG_GOPAGE` Move to the given page of a multipage document.
`static java.lang.String` | `MSG_LASTPAGE` Move to the last page of a multipage document.
`static java.lang.String` | `MSG_NEXTPAGE` Move to the next page of a multipage document.
`static java.lang.String` | `MSG_OPENEDPAGE` Announce new page of document has been opened.
`static java.lang.String` | `MSG_OPENPAGE` Open a different page of a multipage document as given by the `Document`'s `Document.ATTR_PAGE` attribute.
`static java.lang.String` | `MSG_PREVPAGE` Move to the previous page of a multipage document.
`static java.lang.String` | `MSG_RELOADPAGE` Opens same page.
`static int` | `PAGECOUNT_NOT_APPLICABLE`
`static int` | `PAGECOUNT_UNKNOWN`

Fields inherited from class multivalent.Behavior
`ATTR_BEHAVIOR, name_`

Fields inherited from class multivalent.VObject
`attr_`

Constructor Summary
`Multipage()`

Method Summary
`void` | `buildAfter(Document doc)` Traverses all behaviors from lowest to highest priority, during which tweaks hack their content into the tree,
`boolean` | `eventAfter(java.awt.AWTEvent e, java.awt.Point rel, Node n)` If at bottom of page, Space and PageDown flip to next page.
`void` | `restore(ESISNode n, java.util.Map<java.lang.String,java.lang.Object> attr, Layer layer)` If page given in URL anchor (e.g, `#page=5` or `#page10` or `#page.15`), use that.
`boolean` | `semanticEventAfter(SemanticEvent se, java.lang.String msg)` Implement the following events: previosuPage, nextPage, fistPage, lastPage.
`boolean` | `semanticEventBefore(SemanticEvent se, java.lang.String msg)` Appear in Go menu, doc popup, toolbar.

Methods inherited from class multivalent.Behavior
`buildBefore, checkRep, clipboardAfter, clipboardBefore, createUI, destroy, eventBefore, formatAfter, formatBefore, getBrowser, getDocument, getInstance, getInstance, getLayer, getLogger, getName, getPreference, getRoot, isEditable, paintAfter, paintBefore, putPreference, redo, restoreChildren, save, setName, toString, undo`

Methods inherited from class multivalent.VObject
`attrEntrySetIterator, attrKeysIterator, clearAttributes, getAttr, getAttr, getAttributes, getGlobal, getValue, hasAttributes, putAttr, removeAttr, setAttributes`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### MSG_OPENPAGE

    public static final java.lang.String MSG_OPENPAGE

  Open a different page of a multipage document as given by the `Document`'s `Document.ATTR_PAGE` attribute.

  `"openDocumentPage"`.

  See Also:
    Constant Field Values

### MSG_OPENEDPAGE

    public static final java.lang.String MSG_OPENEDPAGE

  Announce new page of document has been opened.

  `"openedDocumentPage"`: `arg=` xxx

  See Also:
    Constant Field Values

### MSG_CLOSEPAGE

    public static final java.lang.String MSG_CLOSEPAGE

  Close current document page, giving other behaviors a chance to save state before moving to a new page or different document.

  `"closePage"`: `arg=` `Integer` current-page-number

  See Also:
    Constant Field Values

### MSG_RELOADPAGE

    public static final java.lang.String MSG_RELOADPAGE

  Opens same page.

  `"reloadDocumentPage"`.

  See Also:
    Constant Field Values

### MSG_NEXTPAGE

    public static final java.lang.String MSG_NEXTPAGE

  Move to the next page of a multipage document.

  `"nextPage"`.

  See Also:
    Constant Field Values

### MSG_PREVPAGE

    public static final java.lang.String MSG_PREVPAGE

  Move to the previous page of a multipage document.

  `"previousPage"`.

  See Also:
    Constant Field Values

### MSG_FIRSTPAGE

    public static final java.lang.String MSG_FIRSTPAGE

  Move to the first page of a multipage document.

  `"firstDocumentPage"`.

  See Also:
    Constant Field Values

### MSG_LASTPAGE

    public static final java.lang.String MSG_LASTPAGE

  Move to the last page of a multipage document.

  `"lastDocumentPage"`.

  See Also:
    Constant Field Values

### MSG_GOPAGE

    public static final java.lang.String MSG_GOPAGE

  Move to the given page of a multipage document.

  `"goPageNum"`: `arg=` `String` or `Integer` new-page-number

  See Also:
    Constant Field Values

### PAGECOUNT_UNKNOWN

    public static final int PAGECOUNT_UNKNOWN

See Also:
  Constant Field Values

### PAGECOUNT_NOT_APPLICABLE

    public static final int PAGECOUNT_NOT_APPLICABLE

See Also:
  Constant Field Values

Constructor Detail

### Multipage

    public Multipage()

Method Detail

### semanticEventBefore

    public boolean semanticEventBefore(SemanticEvent se,
                                       java.lang.String msg)

  Appear in Go menu, doc popup, toolbar.

  Overrides:
    `semanticEventBefore` in class `Behavior`

### semanticEventAfter

    public boolean semanticEventAfter(SemanticEvent se,
                                      java.lang.String msg)

  Implement the following events: previosuPage, nextPage, fistPage, lastPage.

  Overrides:
    `semanticEventAfter` in class `Behavior`

### buildAfter

    public void buildAfter(Document doc)

  Description copied from class: `Behavior`
  Traverses all behaviors from lowest to highest priority, during which tweaks hack their content into the tree,

  Overrides:
    `buildAfter` in class `Behavior`

### eventAfter

    public boolean eventAfter(java.awt.AWTEvent e,
                              java.awt.Point rel,
                              Node n)

  If at bottom of page, Space and PageDown flip to next page. If at top of page, PageUp flips to bottom of previous page. HOME goes to first page, END goes to last.

  Overrides:
    `eventAfter` in class `Behavior`

### restore

    public void restore(ESISNode n,
                        java.util.Map<java.lang.String,java.lang.Object> attr,
                        Layer layer)

  If page given in URL anchor (e.g, `#page=5` or `#page10` or `#page.15`), use that. Else if PAGE attr already set, store it and set to null, so paginated media adaptor won't try to build.

  Overrides:
    `restore` in class `Behavior`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Multivalent API
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD