|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.Panel | +--java.applet.Applet | +--javax.swing.JApplet | +--com.instantbank.lettertemplate.editor.applet.TemplateEditor
Applet for letters template edition. Some of the code has been adapted from the Swing book by Robinson and Vorobiev (Manning Ed).
Inner Class Summary | |
(package private) class |
TemplateEditor.CategoryNameTemplateDialog
Gui that allows to capture/display --fully or partially-- the main attributes of a template: its category, its name, the name of its components. |
(package private) class |
TemplateEditor.ComponentEditor
Actual Editor for the template's components. |
(package private) class |
TemplateEditor.EditorStuff
Contains the widgets that fire external actions on the editors of the template's components: header, body, closing. |
(package private) class |
TemplateEditor.MarginDialog
User dialog that allows to define margins for a template. |
(package private) class |
TemplateEditor.SaveAsComponentDialog
Auxiliary Gui class used to type/choose the name of a component. |
(package private) class |
TemplateEditor.TemplateCodes
Auxiliary class to group basic attributes of a template or a letter component. |
(package private) class |
TemplateEditor.VariableFormatInsertion
Auxiliary class that inserts a format for a variable in the text. |
Inner classes inherited from class javax.swing.JApplet |
javax.swing.JApplet.AccessibleJApplet |
Inner classes inherited from class java.applet.Applet |
java.applet.Applet.AccessibleApplet |
Inner classes inherited from class java.awt.Panel |
java.awt.Panel.AccessibleAWTPanel |
Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.AWTTreeLock |
Field Summary | |
(package private) static java.awt.Color |
backColor
Background color for main widgets in the user interface. |
protected LabelText[] |
basicControls
Array of LabelText containing the controls associated with Template, Header, Body, Closing, Category (in this order), grouped for fast access. |
protected CodeDescription[] |
categories
The set of available template categories. |
static java.lang.String |
DATEDELTA
Name of the attribute that records the date offset of a variable. |
javax.swing.text.DefaultStyledDocument |
docClipboard
Local document clipboard. |
protected TemplateEditor.EditorStuff |
edtStuff
Editor user interface, excluding variables tree. |
protected java.lang.String |
fontName
Font family name |
protected int |
fontSize
Font size |
static java.lang.String |
ICONBYTES
Name of the attribute used to remember the points of insertion of images in the text. |
static java.lang.String |
imgChar
Character to be inserted with an image. |
protected javax.swing.JScrollPane |
jsTree
JScrollPane for variables tree. |
protected javax.swing.JTree |
jtrVariables
Variables tree. |
protected LabelComboCombo |
lbccFont
Widget for font display (family name and size). |
protected LabelCombo |
lbcFormat
Widget for format display. |
protected LabelText |
lbtBody
Label and Text displaying the name of the body. |
protected LabelText |
lbtCategory
Label and Text displaying the category of the template. |
protected LabelText |
lbtClosing
Label and Text displaying the name of the closing. |
protected LabelText |
lbtHeader
Label and Text displaying the name of the header. |
protected LabelText |
lbtPrintType
Label and Text displaying the print type of the template. |
protected LabelText |
lbtTemplate
Label and Text displaying the name of the template. |
protected javax.swing.JPanel |
pnlControl
Upper panel containing controls displaying information related to template name, template type, font, header, body and closing. |
protected javax.swing.JPanel |
pnlRight
Panel containing the right hand side of the user interface. |
private int |
printType
The code of the current print type : LASER, TYPEWRITTER |
protected java.lang.String[] |
printTypes
The known printType names. |
protected TemplateEditorProxy |
proxy
Proxi for communicating with the servlet. |
protected java.lang.String[] |
remoteImages
The list of available images for insertion |
protected TemplateEditor.ComponentEditor |
selectedTed
Editor having the focus. |
protected boolean |
skipUpdate
Indicates if update of the status controls --font, size, format-- must be done. |
(package private) static java.awt.Color |
tabColor
Color for components' tabs: header, body, closing |
protected Template |
template
The Letter Template under edition. |
protected java.util.Hashtable |
templatesNames
The set of template names for all categories with the current printType. |
java.lang.String |
urlbase
Base url of the web server. |
static java.lang.String |
varChar
Character to be inserted with a variable. |
static java.lang.String |
VARCODE
Name of the attribute used to remember the code and points of insertion of loan variables in the text. |
static java.awt.Color |
varColor
Color for visual repesentation of variables |
protected long |
varFormat
Current format of variable. |
static java.lang.String |
VARFORMAT
Name of the attribute that records the format of a variable. |
protected CodeDescription[] |
varFormats
The set of available variable formats. |
VariablesManager |
varManager
The manager of loan variables information. |
Fields inherited from class javax.swing.JApplet |
accessibleContext, rootPane, rootPaneCheckingEnabled |
Fields inherited from class java.applet.Applet |
serialVersionUID, stub |
Fields inherited from class java.awt.Panel |
base, nameCounter |
Fields inherited from class java.awt.Container |
component, containerListener, containerSerializedDataVersion, dbg, dispatcher, layoutMgr, listeningBoundsChildren, listeningChildren, maxSize, ncomponents, printing, printingThreads |
Fields inherited from class java.awt.Component |
actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, changeSupport, componentListener, componentListenerK, componentOrientation, componentSerializedDataVersion, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, graphicsConfig, hasFocus, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, name, nameExplicitlySet, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, privateKey, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowListenerK, x, y |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
TemplateEditor()
|
Method Summary | |
private javax.swing.JTree |
buildTree()
Constructs the Variables tree. |
void |
goHome()
Exit to home page |
void |
init()
Initializes the user interface |
private boolean |
isValidName(java.lang.String name)
Verifies if its argument has the right syntax for template and letter components names. |
private void |
refreshStatusGui(Template templ)
Shows the basic status of a Template in the upper controls of the GUI (except for the Category). |
private java.lang.String |
shortenUrl(java.lang.String url,
int ncomp)
Deletes a number of components at the end of the url |
Methods inherited from class javax.swing.JApplet |
addImpl, createRootPane, createRootPaneException, getAccessibleContext, getContentPane, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isRootPaneCheckingEnabled, paramString, processKeyEvent, remove, setContentPane, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update |
Methods inherited from class java.applet.Applet |
destroy, getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus, start, stop |
Methods inherited from class java.awt.Panel |
|
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, adjustListeningChildren, applyOrientation, checkGD, countComponents, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventImpl, dispatchEventToSelf, doLayout, eventEnabled, findComponentAt, findComponentAt, findComponentAt, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, getWindow, initIDs, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, nextFocus, numListening, paint, paintComponents, paintHeavyweightComponents, postProcessKeyEvent, postsOldMouseEvents, preferredSize, preProcessKeyEvent, print, printComponents, printHeavyweightComponents, processContainerEvent, processEvent, proxyEnableEvents, proxyRequestFocus, readObject, remove, removeAll, removeContainerListener, removeNotify, setFocusOwner, setFont, transferFocus, validate, validateTree, writeObject |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, areInputMethodsEnabled, bounds, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getSize, getToolkit, getToolkitImpl, getTreeLock, getWidth, getWindowForObject, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, resetGC, reshape, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, 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 |
static final java.awt.Color backColor
static final java.awt.Color tabColor
public static final java.lang.String ICONBYTES
public VariablesManager varManager
public static final java.lang.String VARCODE
public static final java.lang.String VARFORMAT
public static final java.lang.String DATEDELTA
public static final java.awt.Color varColor
public static final java.lang.String imgChar
public static final java.lang.String varChar
protected LabelText lbtPrintType
protected LabelText lbtTemplate
protected LabelText lbtCategory
protected LabelText lbtHeader
protected LabelText lbtBody
protected LabelText lbtClosing
protected LabelText[] basicControls
protected LabelComboCombo lbccFont
protected LabelCombo lbcFormat
protected javax.swing.JPanel pnlControl
protected javax.swing.JPanel pnlRight
protected TemplateEditor.EditorStuff edtStuff
protected TemplateEditor.ComponentEditor selectedTed
protected javax.swing.JScrollPane jsTree
protected javax.swing.JTree jtrVariables
protected java.lang.String[] printTypes
private int printType
public javax.swing.text.DefaultStyledDocument docClipboard
public java.lang.String urlbase
protected java.lang.String fontName
protected int fontSize
protected boolean skipUpdate
protected long varFormat
protected TemplateEditorProxy proxy
protected java.lang.String[] remoteImages
protected CodeDescription[] categories
protected CodeDescription[] varFormats
protected Template template
protected java.util.Hashtable templatesNames
Constructor Detail |
public TemplateEditor()
Method Detail |
public void init()
init
in class java.applet.Applet
private java.lang.String shortenUrl(java.lang.String url, int ncomp)
url
- An url pathncomp
- Number of components to deletepublic void goHome()
private javax.swing.JTree buildTree()
private void refreshStatusGui(Template templ)
templ
- The template whose status is showed.private boolean isValidName(java.lang.String name)
name
- The string to be verified.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |