|
|||||||||
| Home >> All >> com >> hexidec >> [ ekit overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
com.hexidec.ekit
Class EkitCore

java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
com.hexidec.ekit.EkitCore
- All Implemented Interfaces:
- javax.accessibility.Accessible, java.awt.event.ActionListener, javax.swing.event.DocumentListener, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable
- public class EkitCore
- extends javax.swing.JPanel
- implements java.awt.event.ActionListener, javax.swing.event.DocumentListener
- extends javax.swing.JPanel
EkitCore Main application class for editing and saving HTML in a Java text component
- Version:
- 0.9e REQUIREMENTS Java 2 (JDK 1.3 or 1.4) Swing Library
| Nested Class Summary | |
(package private) class |
EkitCore.CustomUndoableEditListener
Class for implementing the Undo listener to handle the Undo and Redo actions |
(package private) class |
EkitCore.RedoAction
Class for implementing Redo as an autonomous action |
(package private) class |
EkitCore.UndoAction
Class for implementing Undo as an autonomous action |
| Nested classes inherited from class javax.swing.JPanel |
javax.swing.JPanel.AccessibleJPanel |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Container |
|
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
EkitCore(java.lang.String sDocument,
java.lang.String sStyleSheet,
java.lang.String sRawDocument,
java.net.URL urlStyleSheet,
boolean showViewSource,
boolean showMenuIcons,
boolean editModeExclusive,
java.lang.String sLanguage,
java.lang.String sCountry,
boolean debugMode,
java.net.URL urlFilePaths,
java.lang.String sRootName,
java.lang.String sFilePathDelimiter,
java.lang.String sDefaultTables,
java.lang.String sCustomText)
Master Constructor |
|
| Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent ae)
This method is invoked when an action occurs. |
private void |
alignCells(java.lang.String sAlignment)
|
void |
changedUpdate(javax.swing.event.DocumentEvent de)
Changed update |
private void |
changeList(javax.swing.text.html.HTML.Tag listType)
|
void |
createColorMenu(java.util.Vector vColors)
Method to update |
private void |
deleteTable()
|
private void |
deleteTableCol()
|
private void |
deleteTableRow()
|
private void |
describeDocument(javax.swing.text.StyledDocument doc)
Method for describing the node hierarchy of the document |
void |
displayBorderColors()
|
void |
displayCellColors()
|
void |
displayColColors()
|
void |
displayRowColors()
|
void |
displayTableColors()
|
private java.lang.String |
findStyle(javax.swing.text.Element element)
Searches the specified element for CLASS attribute setting |
void |
firstParse()
|
java.lang.String |
getAppName()
Convenience method for obtaining the application name |
java.lang.String |
getChooserColor()
|
java.io.File |
getCurrentFile()
Convenience method for obtaining the current file handle |
javax.swing.text.StyledDocument |
getDocumentStyledDocument()
Convenience method for obtaining the |
java.lang.String |
getDocumentSubText(java.lang.String tagBlock)
|
java.lang.String |
getDocumentSubTextForApplet(java.lang.String tagBlock)
Method for extracting the text within a tag, custom method for WS Interactive Automne |
java.lang.String |
getDocumentText()
Convenience method for obtaining the document text |
private javax.swing.ImageIcon |
getEkitIcon(java.lang.String iconName)
Convenience method for fetching icon images from jar file |
java.awt.Frame |
getFrame()
Convenience method for obtaining the application as a Frame |
int |
getMainCaretPosition()
|
javax.swing.JMenuBar |
getMenuBar()
Convenience method for obtaining the pre-generated menu bar |
private java.lang.String |
getSubText(java.lang.String docText,
java.lang.String containingTag)
Method for extracting the text within a tag |
javax.swing.JTextPane |
getTextPane()
Convenience method for obtaining the JTextPane |
javax.swing.JToolBar |
getToolBar()
Convenience method for obtaining the pre-generated toolbar |
private void |
handleCaretPositionChange(javax.swing.event.CaretEvent ce)
Handles caret tracking and related events, such as displaying the current style of the text under the caret |
void |
handleDocumentChange(javax.swing.event.DocumentEvent de)
|
private void |
indentListItem(javax.swing.text.html.HTML.Tag listType)
|
private void |
insertBreak()
Method for inserting a break (BR) element |
void |
insertExternalString(java.lang.String sExternal)
Convenience method for inserting a string |
void |
insertHTMLString(java.lang.String sText,
java.lang.String sTag)
|
private void |
insertListItem(boolean bOrdered)
|
private void |
insertNewLineList(javax.swing.text.html.HTML.Tag listType)
|
private void |
insertNonbreakingSpace()
Method for inserting a non-breaking space ( ) |
private void |
insertOrderedList()
|
void |
insertParagraphs()
|
void |
insertString(java.lang.String sExternal)
|
private void |
insertTable(java.util.Hashtable attribs,
java.lang.String[] fieldNames,
java.lang.String[] fieldTypes)
Method for inserting an HTML Table |
private void |
insertTableCell()
Method for inserting a cell into an HTML Table |
private void |
insertTableColumnLeft()
|
private void |
insertTableColumnRight()
|
private void |
insertTableRow()
Method for inserting a row into an HTML Table |
private void |
insertTableRowBelow()
Method for inserting a row into an HTML Table |
private void |
insertUnorderedList()
|
void |
insertUpdate(javax.swing.event.DocumentEvent de)
Insert update |
boolean |
isInTag(javax.swing.text.html.HTML.Tag inTag)
|
private void |
justifyListItem(javax.swing.text.html.HTML.Tag listType)
Method to realign HTML list item if indented |
private javax.swing.text.Element |
locateChildElementInDocument(javax.swing.text.Element element,
java.lang.String elementName)
Traverses nodes for the locating method |
private javax.swing.text.Element |
locateClosestParent(javax.swing.text.html.HTML.Tag tagFirst,
javax.swing.text.html.HTML.Tag tagSecond)
Traverses nodes to see which Elements is closest parent Returns 1st Paramater if parameters are siblings |
private javax.swing.text.Element |
locateElementInDocument(javax.swing.text.StyledDocument doc,
java.lang.String elementName)
Method to locate a node element by name |
private void |
logException(java.lang.String internalMessage,
java.lang.Exception e)
Convenience method for outputting exceptions |
private void |
mergeCells()
|
private void |
openStyleSheet(java.io.File fileCSS)
Method for loading a Stylesheet into the app |
void |
purgeUndos()
Convenience method for clearing out the UndoManager |
void |
refreshOnUpdate()
Convenience method for refreshing and displaying changes |
void |
registerDocument(com.hexidec.ekit.component.ExtendedHTMLDocument htmlDoc)
Method for setting a document as the current document for the text pane and re-registering the controls and settings for it |
void |
registerDocumentStyles()
Method for locating the available CSS style for the document and adding them to the styles selector |
private void |
removeHeading(javax.swing.text.html.HTML.Tag heading)
|
private void |
removeListItem(javax.swing.text.html.HTML.Tag listType)
|
private void |
removeOrderedList()
|
private void |
removeUnorderedList()
|
void |
removeUpdate(javax.swing.event.DocumentEvent de)
Remove update |
void |
resetCaret(int caretPos)
|
void |
setFrame(java.awt.Frame parentFrame)
Convenience method for setting the parent Frame |
void |
sourceRefresh()
|
private void |
splitCells()
|
private void |
tableProperties()
|
private void |
toggleSourceWindow()
Convenience method for toggling source window visibility |
private void |
traverseElement(javax.swing.text.Element element)
Traverses nodes for the describing method |
void |
updateColors()
|
private void |
updateLists()
Method for updating lists when Enter key is pressed |
private void |
updateTitle()
Convenience method for obtaining the document text |
| Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
jspltDisplay
private javax.swing.JSplitPane jspltDisplay
jtpMain
private javax.swing.JTextPane jtpMain
htmlKit
private com.hexidec.ekit.component.ExtendedHTMLEditorKit htmlKit
htmlDoc
private com.hexidec.ekit.component.ExtendedHTMLDocument htmlDoc
styleSheet
private javax.swing.text.html.StyleSheet styleSheet
jtpSource
private javax.swing.JTextPane jtpSource
jspSource
private javax.swing.JScrollPane jspSource
jToolBar
private javax.swing.JToolBar jToolBar
jbtnBold
private com.hexidec.ekit.component.JButtonNoFocus jbtnBold
jbtnItalic
private com.hexidec.ekit.component.JButtonNoFocus jbtnItalic
jbtnUnderline
private com.hexidec.ekit.component.JButtonNoFocus jbtnUnderline
jbtnStrike
private com.hexidec.ekit.component.JButtonNoFocus jbtnStrike
jbtnSuperscript
private com.hexidec.ekit.component.JButtonNoFocus jbtnSuperscript
jbtnSubscript
private com.hexidec.ekit.component.JButtonNoFocus jbtnSubscript
jbtnAlignLeft
private com.hexidec.ekit.component.JButtonNoFocus jbtnAlignLeft
jbtnAlignRight
private com.hexidec.ekit.component.JButtonNoFocus jbtnAlignRight
jbtnAlignCenter
private com.hexidec.ekit.component.JButtonNoFocus jbtnAlignCenter
jbtnAlignJustified
private com.hexidec.ekit.component.JButtonNoFocus jbtnAlignJustified
jbtnUList
private com.hexidec.ekit.component.JButtonNoFocus jbtnUList
jbtnOList
private com.hexidec.ekit.component.JButtonNoFocus jbtnOList
jbtnClearFormat
private com.hexidec.ekit.component.JButtonNoFocus jbtnClearFormat
jbtnAnchor
private com.hexidec.ekit.component.JButtonNoFocus jbtnAnchor
jbtnRefresh
private com.hexidec.ekit.component.JButtonNoFocus jbtnRefresh
jtbtnViewSource
private com.hexidec.ekit.component.JToggleButtonNoFocus jtbtnViewSource
pathToTag
private java.util.Hashtable pathToTag
jcmbStyleSelector
private com.hexidec.ekit.component.JComboBoxNoFocus jcmbStyleSelector
frameHandler
private java.awt.Frame frameHandler
actionAlignLeft
private javax.swing.text.StyledEditorKit.AlignmentAction actionAlignLeft
actionAlignRight
private javax.swing.text.StyledEditorKit.AlignmentAction actionAlignRight
actionAlignCenter
private javax.swing.text.StyledEditorKit.AlignmentAction actionAlignCenter
actionAlignJustified
private javax.swing.text.StyledEditorKit.AlignmentAction actionAlignJustified
actionFontStrike
private com.hexidec.ekit.action.TextAction actionFontStrike
actionFontSuperscript
private com.hexidec.ekit.action.TextAction actionFontSuperscript
actionFontSubscript
private com.hexidec.ekit.action.TextAction actionFontSubscript
actionRemoveLink
private com.hexidec.ekit.action.TextAction actionRemoveLink
actionFontBold
private javax.swing.text.StyledEditorKit.BoldAction actionFontBold
actionFontItalic
private javax.swing.text.StyledEditorKit.ItalicAction actionFontItalic
actionFontUnderline
private javax.swing.text.StyledEditorKit.UnderlineAction actionFontUnderline
actionClearFormat
private com.hexidec.ekit.action.TextAction actionClearFormat
actionInsertAnchor
private com.hexidec.ekit.action.CustomAction actionInsertAnchor
actionInsertLink
private com.hexidec.ekit.action.CustomAction actionInsertLink
actionInsertEmail
private com.hexidec.ekit.action.CustomAction actionInsertEmail
actionNewColor
private com.hexidec.ekit.action.FontAction actionNewColor
actionNoColor
private com.hexidec.ekit.action.FontAction actionNoColor
undoMngr
protected javax.swing.undo.UndoManager undoMngr
undoAction
protected EkitCore.UndoAction undoAction
redoAction
protected EkitCore.RedoAction redoAction
jMenuBar
private javax.swing.JMenuBar jMenuBar
jMenuEdit
private javax.swing.JMenu jMenuEdit
jMenuView
private javax.swing.JMenu jMenuView
jMenuFont
private javax.swing.JMenu jMenuFont
jMenuFontColor
private javax.swing.JMenu jMenuFontColor
jMenuFormat
private javax.swing.JMenu jMenuFormat
jMenuInsert
private javax.swing.JMenu jMenuInsert
jMenuTable
private javax.swing.JMenu jMenuTable
jMenuList
private javax.swing.JMenu jMenuList
jMenuDebug
private javax.swing.JMenu jMenuDebug
sArrTables
private java.lang.String[] sArrTables
appName
private final java.lang.String appName
- See Also:
- Constant Field Values
menuDialog
private final java.lang.String menuDialog
- See Also:
- Constant Field Values
iSplitPos
private int iSplitPos
exclusiveEdit
private boolean exclusiveEdit
currentFile
private java.io.File currentFile
indent
private int indent
indentStep
private final int indentStep
- See Also:
- Constant Field Values
extsCSS
private final java.lang.String[] extsCSS
| Constructor Detail |
EkitCore
public EkitCore(java.lang.String sDocument, java.lang.String sStyleSheet, java.lang.String sRawDocument, java.net.URL urlStyleSheet, boolean showViewSource, boolean showMenuIcons, boolean editModeExclusive, java.lang.String sLanguage, java.lang.String sCountry, boolean debugMode, java.net.URL urlFilePaths, java.lang.String sRootName, java.lang.String sFilePathDelimiter, java.lang.String sDefaultTables, java.lang.String sCustomText)
- Master Constructor
| Method Detail |
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent ae)
- Description copied from interface:
java.awt.event.ActionListener - This method is invoked when an action occurs.
- Specified by:
actionPerformedin interfacejava.awt.event.ActionListener
changedUpdate
public void changedUpdate(javax.swing.event.DocumentEvent de)
- Description copied from interface:
javax.swing.event.DocumentListener - Changed update
- Specified by:
changedUpdatein interfacejavax.swing.event.DocumentListener
insertUpdate
public void insertUpdate(javax.swing.event.DocumentEvent de)
- Description copied from interface:
javax.swing.event.DocumentListener - Insert update
- Specified by:
insertUpdatein interfacejavax.swing.event.DocumentListener
removeUpdate
public void removeUpdate(javax.swing.event.DocumentEvent de)
- Description copied from interface:
javax.swing.event.DocumentListener - Remove update
- Specified by:
removeUpdatein interfacejavax.swing.event.DocumentListener
handleDocumentChange
public void handleDocumentChange(javax.swing.event.DocumentEvent de)
registerDocument
public void registerDocument(com.hexidec.ekit.component.ExtendedHTMLDocument htmlDoc)
- Method for setting a document as the current document for the text pane
and re-registering the controls and settings for it
registerDocumentStyles
public void registerDocumentStyles()
- Method for locating the available CSS style for the document and adding
them to the styles selector
getChooserColor
public java.lang.String getChooserColor()
removeHeading
private void removeHeading(javax.swing.text.html.HTML.Tag heading)
displayBorderColors
public void displayBorderColors()
displayCellColors
public void displayCellColors()
displayRowColors
public void displayRowColors()
displayColColors
public void displayColColors()
displayTableColors
public void displayTableColors()
tableProperties
private void tableProperties()
insertTable
private void insertTable(java.util.Hashtable attribs, java.lang.String[] fieldNames, java.lang.String[] fieldTypes) throws java.io.IOException, javax.swing.text.BadLocationException, java.lang.RuntimeException, java.lang.NumberFormatException
- Method for inserting an HTML Table
insertTableRow
private void insertTableRow()
- Method for inserting a row into an HTML Table
insertParagraphs
public void insertParagraphs()
firstParse
public void firstParse()
isInTag
public boolean isInTag(javax.swing.text.html.HTML.Tag inTag)
insertTableRowBelow
private void insertTableRowBelow()
- Method for inserting a row into an HTML Table
insertTableColumnLeft
private void insertTableColumnLeft()
insertTableColumnRight
private void insertTableColumnRight()
deleteTableRow
private void deleteTableRow()
deleteTableCol
private void deleteTableCol()
deleteTable
private void deleteTable()
alignCells
private void alignCells(java.lang.String sAlignment)
mergeCells
private void mergeCells()
splitCells
private void splitCells()
insertOrderedList
private void insertOrderedList()
insertUnorderedList
private void insertUnorderedList()
JAVADOC