org.w3c.rdfpic.ui
Class SchemaTabbedPane

java.lang.Object
  |
  +--java.awt.Component
        |
        +--java.awt.Container
              |
              +--javax.swing.JComponent
                    |
                    +--javax.swing.JTabbedPane
                          |
                          +--org.w3c.rdfpic.ui.SchemaTabbedPane

public class SchemaTabbedPane
extends javax.swing.JTabbedPane
implements RdfDataProvider, SchemaListener, ImgListener

Displays a tabbed pane for editing values of fields for an image. Each Tab corresponds to a schema. Within that tab, there are a number of rows. Each row corresponds to a field of that schema. To the left will be the name of the field, to the right an editable MemComboBox for entering values. Between the name and field is a checkbox - if it is checked, the value is persistent. That means that when a new file is loaded, the previous value remains selected. This is useful, as a large number of photo's might be made by the same photographer in the same location with the same camera. Regardless of whether or not the values are persistent, all old values can be recalled as they are stored in the MemComboBox.

This class is an RdfDataProvider.

See Also:
Serialized Form

Inner classes inherited from class javax.swing.JTabbedPane
javax.swing.JTabbedPane.AccessibleJTabbedPane, javax.swing.JTabbedPane.ModelListener
 
Inner classes inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent, javax.swing.JComponent.IntVector, javax.swing.JComponent.KeyboardBinding, javax.swing.JComponent.KeyboardState
 
Inner classes inherited from class java.awt.Component
java.awt.Component.AWTTreeLock
 
Field Summary
(package private)  java.util.TreeMap builtinMap
           
(package private)  RdfPicCore core
           
(package private)  javax.swing.JComboBox[][] dialog
           
(package private) static java.awt.Font font
           
(package private)  javax.swing.JCheckBox[][] persistent
           
(package private)  javax.swing.JScrollPane[] tabs
           
 
Fields inherited from class javax.swing.JTabbedPane
changeEvent, changeListener, haveRegistered, model, pages, tabPlacement, uiClassID
 
Fields inherited from class javax.swing.JComponent
_bounds, accessibleContext, alignmentX, alignmentY, ANCESTOR_USING_BUFFER, ancestorNotifier, autoscroller, border, changeSupport, clientProperties, flags, HAS_FOCUS, IS_DOUBLE_BUFFERED, IS_OPAQUE, IS_PAINTING_TILE, IS_PRINTING, IS_PRINTING_ALL, KEYBOARD_BINDINGS_KEY, listenerList, maximumSize, minimumSize, NEXT_FOCUS, paintImmediatelyClip, paintingChild, preferredSize, readObjectCallbacks, REQUEST_FOCUS_DISABLED, tmpRect, TOOL_TIP_TEXT_KEY, ui, uiClassID, UNDEFINED_CONDITION, vetoableChangeSupport, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Container
component, containerListener, containerSerializedDataVersion, dispatcher, layoutMgr, maxSize, ncomponents, serialVersionUID
 
Fields inherited from class java.awt.Component
actionListenerK, adjustmentListenerK, appContext, assert, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, changeSupport, componentListener, componentListenerK, componentOrientation, componentSerializedDataVersion, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, hasFocus, height, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, name, nameExplicitlySet, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, RIGHT_ALIGNMENT, serialVersionUID, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowListenerK, x, y
 
Constructor Summary
SchemaTabbedPane(RdfPicCore core)
           
 
Method Summary
 void addBuiltin(java.lang.String predName, CboxMaker cboxMaker)
          Adds a CboxMaker to use when when a specified predicate is encountered as builtin.
 void addingSchema()
          Called when a schema is added.
private  void createPane(int schemaIndex)
           
 void disablingSchema(int schemaIndex)
           
 void enablingSchema(int schemaIndex)
           
 void hasJumped(java.lang.String errMsg)
          Is called when the load is finished.
 void imgVUpdate()
          Is called when the vector of images has changed.
 void isJumping(int newindex)
          Is called when a load request is put.
(package private)  void lockInput()
           
private  void make()
           
 void remake()
           
 void removeBuiltin(java.lang.String predName)
           
 void setVal(int schemaIndex, int predicateIndex, java.lang.String val)
           
 java.lang.String valOf(int schemaIndex, int predicateIndex)
           
 
Methods inherited from class javax.swing.JTabbedPane
add, add, add, add, add, addChangeListener, addTab, addTab, addTab, createChangeListener, fireStateChanged, getAccessibleContext, getBackgroundAt, getBoundsAt, getComponentAt, getDisabledIconAt, getForegroundAt, getIconAt, getModel, getSelectedComponent, getSelectedIndex, getTabCount, getTabPlacement, getTabRunCount, getTitleAt, getToolTipText, getUI, getUIClassID, indexOfComponent, indexOfTab, indexOfTab, insertTab, isEnabledAt, paramString, remove, removeAll, removeChangeListener, removeTabAt, setBackgroundAt, setComponentAt, setDisabledIconAt, setEnabledAt, setForegroundAt, setIconAt, setModel, setSelectedComponent, setSelectedIndex, setTabPlacement, setTitleAt, setUI, updateUI, writeObject
 
Methods inherited from class javax.swing.JComponent
_paintImmediately, , addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, adjustPaintFlags, alwaysOnTop, bindingForKeyStroke, checkIfChildObscuredBySibling, computeVisibleRect, computeVisibleRect, contains, createToolTip, enableSerialization, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getAlignmentX, getAlignmentY, getAutoscrolls, getBorder, getBounds, getClientProperties, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getFlag, getGraphics, getHeight, getInsets, getInsets, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getVisibleRect, getWidth, getX, getY, grabFocus, hasFocus, isDoubleBuffered, isFocusCycleRoot, isFocusTraversable, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, keyboardBindings, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paintWithBuffer, print, printAll, processComponentKeyEvent, processFocusEvent, processKeyBinding, processKeyBindings, processKeyBindingsForAllComponents, processKeyEvent, processMouseMotionEvent, putClientProperty, readObject, rectangleIsObscured, rectangleIsObscuredBySibling, registerKeyboardAction, registerKeyboardAction, registerWithKeyboardManager, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDoubleBuffered, setEnabled, setFlag, setFont, setForeground, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPaintingChild, setPreferredSize, setRequestFocusEnabled, setToolTipText, setUI, setVisible, shouldDebugGraphics, superProcessMouseMotionEvent, unregisterKeyboardAction, unregisterWithKeyboardManager, update
 
Methods inherited from class java.awt.Container
addContainerListener, addImpl, applyOrientation, countComponents, deliverEvent, dispatchEventImpl, dispatchEventToSelf, doLayout, eventEnabled, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getCursorTarget, getLayout, getMouseEventTarget, getWindow, initIDs, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPrint, list, list, locate, minimumSize, nextFocus, paintComponents, postProcessKeyEvent, postsOldMouseEvents, preferredSize, preProcessKeyEvent, printComponents, printHeavyweightComponents, printOneComponent, processContainerEvent, processEvent, proxyEnableEvents, proxyRequestFocus, remove, removeContainerListener, setCursor, setFocusOwner, setLayout, transferFocus, updateCursor, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, areInputMethodsEnabled, bounds, checkImage, checkImage, coalesceEvents, constructComponentName, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getInputContext, getInputMethodRequests, getIntrinsicCursor, getLocale, getLocation, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getToolkit, getToolkitImpl, getTreeLock, getWindowForObject, gotFocus, handleEvent, hide, imageUpdate, inside, isDisplayable, isEnabled, isEnabledImpl, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processInputMethodEvent, processMouseEvent, remove, removeComponentListener, removeFocusListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setDropTarget, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

font

static java.awt.Font font

dialog

javax.swing.JComboBox[][] dialog

persistent

javax.swing.JCheckBox[][] persistent

tabs

javax.swing.JScrollPane[] tabs

core

RdfPicCore core

builtinMap

java.util.TreeMap builtinMap
Constructor Detail

SchemaTabbedPane

public SchemaTabbedPane(RdfPicCore core)
Method Detail

imgVUpdate

public void imgVUpdate()
Description copied from interface: ImgListener
Is called when the vector of images has changed. For example the active image has a new index, or an image has been added/removed/rearranged.
Specified by:
imgVUpdate in interface ImgListener

addBuiltin

public void addBuiltin(java.lang.String predName,
                       CboxMaker cboxMaker)
Adds a CboxMaker to use when when a specified predicate is encountered as builtin.

removeBuiltin

public void removeBuiltin(java.lang.String predName)

valOf

public java.lang.String valOf(int schemaIndex,
                              int predicateIndex)
Specified by:
valOf in interface RdfDataProvider

setVal

public void setVal(int schemaIndex,
                   int predicateIndex,
                   java.lang.String val)
Specified by:
setVal in interface RdfDataProvider

remake

public void remake()

make

private void make()

createPane

private void createPane(int schemaIndex)

disablingSchema

public void disablingSchema(int schemaIndex)
Specified by:
disablingSchema in interface SchemaListener

enablingSchema

public void enablingSchema(int schemaIndex)
Specified by:
enablingSchema in interface SchemaListener

addingSchema

public void addingSchema()
Description copied from interface: SchemaListener
Called when a schema is added.
Specified by:
addingSchema in interface SchemaListener

lockInput

void lockInput()

isJumping

public void isJumping(int newindex)
Description copied from interface: ImgListener
Is called when a load request is put. (not from load-thread).
Specified by:
isJumping in interface ImgListener
Tags copied from interface: ImgListener
Parameters:
newindex - Index of the file being loaded.

hasJumped

public void hasJumped(java.lang.String errMsg)
Description copied from interface: ImgListener
Is called when the load is finished. (from load-thread).
Specified by:
hasJumped in interface ImgListener
Tags copied from interface: ImgListener
Parameters:
errMsg - null on success, explanation on error.