org.telscenter.pas.common.ui
Class CommonUI
java.lang.Object
org.telscenter.pas.common.ui.CommonUI
public class CommonUI
- extends java.lang.Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MODE
public static final java.lang.String MODE
- See Also:
- Constant Field Values
SAVE_MODE
public static final java.lang.String SAVE_MODE
- See Also:
- Constant Field Values
serialVersionUID
public static final long serialVersionUID
- See Also:
- Constant Field Values
EDIT_MODE
public static final java.lang.String EDIT_MODE
- See Also:
- Constant Field Values
CREATE_Label
public static final java.lang.String CREATE_Label
- See Also:
- Constant Field Values
EDIT_LABEL
public static final java.lang.String EDIT_LABEL
- See Also:
- Constant Field Values
EDIT_BUTTON
public static final java.lang.String EDIT_BUTTON
- See Also:
- Constant Field Values
TEXT_COMP
public static final java.lang.String TEXT_COMP
- See Also:
- Constant Field Values
EDIT_PANEL
public static final java.lang.String EDIT_PANEL
- See Also:
- Constant Field Values
DEFAULT_FILENAME
public static final java.lang.String DEFAULT_FILENAME
- See Also:
- Constant Field Values
fileName
public static java.lang.String fileName
HTML_REGEX
public static final java.lang.String HTML_REGEX
- See Also:
- Constant Field Values
CommonUI
public CommonUI()
tidyHtml
public static java.lang.String tidyHtml(java.lang.String html)
createHTMLTextPanel
public static javax.swing.JComponent createHTMLTextPanel(java.lang.String text)
- Parameters:
formPanel - textI -
- Returns:
createHTMLTidyEditActionlistener
public static java.awt.event.ActionListener createHTMLTidyEditActionlistener()
tidyHtml
public static java.lang.String tidyHtml(java.lang.String html,
java.lang.String name)
getComponentByName
public static java.awt.Component getComponentByName(java.awt.Container container,
java.lang.String name)
getComponentsByName
public static java.util.List getComponentsByName(java.awt.Container container,
java.lang.String name,
java.util.List<java.awt.Component> cs)
createEditableTextarea
public static javax.swing.JPanel createEditableTextarea(javax.swing.text.JTextComponent textComponent,
java.awt.Dimension dim)
centerDialogOnScreen
public static java.awt.Point centerDialogOnScreen(java.awt.Rectangle bounds)
createEtchedBorder
public static javax.swing.border.Border createEtchedBorder()
createLowerBannerGap
public static javax.swing.border.Border createLowerBannerGap()
makeMultilineEditable
public static void makeMultilineEditable(javax.swing.text.JTextComponent area)
makeMultilineLabel
public static void makeMultilineLabel(javax.swing.text.JTextComponent area)
createPurpleWhiteBorder
public static javax.swing.border.Border createPurpleWhiteBorder()
create4PEmptyBorder
public static javax.swing.border.Border create4PEmptyBorder()
makeLink
public static javax.swing.JButton makeLink(javax.swing.JButton button)
makeEnhancedButton
public static javax.swing.JButton makeEnhancedButton(javax.swing.JButton button)
makeButtonWithHandCursor
public static void makeButtonWithHandCursor(javax.swing.JButton button)
applyDNDHack
public static void applyDNDHack(javax.swing.JComponent comp)
makeHintbutton
public static javax.swing.JButton makeHintbutton(javax.swing.JButton hintButton)
- Parameters:
hintButton -
makeButtonTransparent
public static javax.swing.JButton makeButtonTransparent(javax.swing.JButton button)
addButtonRollover
public static void addButtonRollover(javax.swing.JButton button,
javax.swing.ImageIcon rollOverIcon)
showHintDialog
public static javax.swing.JDialog showHintDialog(HintSet hintSet,
javax.swing.JFrame frame)
modScrollPane
public static void modScrollPane(javax.swing.JScrollPane spane)
openDialog
public static java.io.File openDialog()
- Opens the native system file choosing dialog
- Returns:
- the file the user has chosen
openDialog
public static java.io.File openDialog(java.lang.String fileExtension)
- Opens the native system file choosing dialog
- Parameters:
the - extension file type we are allowing the user to choose
- Returns:
- the file the user has chosen
saveDialog
public static java.io.File saveDialog()
- Opens the native system save file dialog
- Returns:
- the file to be saved
getFileName
public static java.lang.String getFileName()
- Returns:
- the fileName
setFileName
public static void setFileName(java.lang.String fileName)
- Parameters:
fileName - the fileName to set
extractFileName
public static java.lang.String extractFileName(java.lang.String url)
- Parameters:
url - a path to a file
- Returns:
- the filename and extension without the directory
Copyright © 2004-2008 TELS Center. All Rights Reserved.