Documentation of 'jv.project.PgGeometry_Menu' Java class
PgGeometry_Menu ("JavaView Reference Manual")
"JavaView? v5.03.003"
jv.project

Class PgGeometry_Menu

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.awt.event.ItemListener, java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.EventListener, java.util.List, java.util.RandomAccess, PsUpdateIf
    Direct Known Subclasses:
    PgPointSet_Menu, PgPointSet_Menu


    public class PgGeometry_Menu
    extends PsMethodMenu
    Add specific menu items to 'method' menu in control panel to invoke methods from menu. For example, each geometry may have a menu class derived PgGeometry_Menu which adds additional menu items and sub menus. When the geometry is the current geometry in the viewer, then its set of method menus is added to the menu bar of the control window.

    Each geometry may add a set of menu items to submenus of the 'method' menu.

    Usage:
    In the init() method add new menu entries as follows:

                    addMenu("Menu-Name");
                    addMenuItem("Menu-Name", "Menu-Item-Name");
     
    The submenu is created if it does not exist. Catch menu events in the applyMethod(String name) using:
                    if (name.equals("Menu-Item-Name"))
                            // invoke method related with "Menu-Item-Name".
     
    See Also:
    PsMethodMenu, Serialized Form
    Author:
    Konrad Polthier
    Version:
    20.12.01, 2.20 revised (ep) Internationalization.
    12.12.01, 2.10 revised (kp) Showing of bndbox and center enabled.
    18.07.99, 2.00 revised (kp) Method calls changed and PsMenu replaced with standard java.awt.Menu.
    00.00.98, 1.00 created (kp)
    • Constructor Detail

      • PgGeometry_Menu

        public PgGeometry_Menu()
    • Method Detail

      • init

        public void init(PsObject anObject)
        Description copied from class: PsMethodMenu
        Register the target geometry, and subclasses should register all menu items and submenus.
        Overrides:
        init in class PsMethodMenu
        Parameters:
        anObject - argument used by subclasses to specify object on which action shall be executed.
      • applyMethod

        public boolean applyMethod(java.lang.String aMethod)
        Description copied from class: PsMethodMenu
        Invoke action determined by current string. This method returns false, and should be overwritten by subclasses.
        Overrides:
        applyMethod in class PsMethodMenu
      • getViewer

        public PvViewerIf getViewer()
        Get viewer which enables access to displays and inspectors.
        Since:
        JavaView 2.45
        See Also:
        setViewer(PvViewerIf)
        Version:
        11.11.02, 1.00 created (kp)
      • setViewer

        public void setViewer(PvViewerIf viewer)
        Set viewer enable access to displays and inspectors.
        Since:
        JavaView 2.45
        See Also:
        getViewer()
        Version:
        11.11.02, 1.00 created (kp)
"JavaView? v5.03.003"

"

The software JavaView? is copyright protected. All Rights Reserved.
"

You see the box below because you did not login.