|
||||||||||
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.Window | +--java.awt.Frame | +--ShowSpreadsheetPopup
The ShowSpreadsheetPopup class pops up a scrollable dynamic spreadsheet. For columns that should contain hypertext links, this displays table data in formated/clickable spreadsheet and handles hyperlink dispatching events.
This work was produced by Peter Lemkin of the National Cancer Institute, an agency of the United States Government. As a work of the United States Government there is no associated copyright. It is offered as open source software under the Mozilla Public License (version 1.1) subject to the limitations noted in the accompanying LEGAL file. This notice must be included with the code. The MAExplorer Mozilla and Legal files are available on http://maexplorer.sourceforge.net/.
Report
,
SpreadSheet
, Serialized FormInner classes inherited from class java.awt.Frame |
java.awt.Frame.AccessibleAWTFrame |
Inner classes inherited from class java.awt.Window |
java.awt.Window.AccessibleAWTWindow |
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 | |
private java.lang.String[] |
altFieldNames
ARG: [maxCols] if ! null - same for all cells |
private java.awt.Font |
buttonFont
cell label font |
(package private) java.awt.Checkbox |
cb
Checkbox |
(package private) java.awt.Color |
cellClicked
clicked color for cell color in spreadsheet |
private java.awt.Font |
cellDataFont
cell data font |
private int[] |
cellFormat
ARG: cell type [0:maxCols] fields which are urls is Spreadsheet.CELL_NOP, .CELL_URL, or .CELL_EXPR_PROFILE |
(package private) java.awt.Color |
cellReg
normal color for cell color in spreadsheet |
private java.awt.Font |
cellUrlFont
cell URL font |
(package private) int |
clickedCellCol
keep track of last clicked cell |
(package private) int |
clickedCellRow
keep track of last clicked cell |
private int |
cols
cols |
private java.lang.String[][] |
dataURL
ARG: if url [0:maxRows-1][0:maxCols-1] from and not null, use this for URL |
(package private) static int |
DEF_COLS_TO_SHOW
# of cols to show in dynamic spreadsheet |
(package private) int |
fontSize
integer value of fontSizeStr |
(package private) java.lang.String |
fontSizeStr
ARG: font size |
private java.awt.Frame |
frame
frame which holds popup spreadsheet |
(package private) java.awt.Color |
headerClicked
color for header when click on cell |
(package private) java.lang.String |
headerName
header name for col clicked on in virData |
(package private) int |
lastRow
ARG: end of table data to use, counts from 0? |
private MAExplorer |
mae
link to global MAExplorer instance |
(package private) static int |
MAX_ROWS_TO_SHOW
# of rows to show in dynamic spreadsheet |
(package private) int |
oldTagCol
old tag col for clicked cell color (before) |
(package private) int |
oldTagRow
|
(package private) static int |
POPUP_HEIGHT
size (height) of popup report window |
(package private) static int |
POPUP_WIDTH
size (width) of popup report window |
(package private) java.lang.String |
popupName
ARG: for PopupRegistry |
(package private) int |
popupPropertyBits
ARG: for PopupRegistry |
(package private) int |
prepCols
# cols in prepData table |
private java.lang.String[][] |
prepData
displayed data [0:prepRows-1][0:prepCols-1] |
(package private) int |
prepHdrPos
location of col clicked in prepData |
(package private) int |
prepRows
# rows in prepData table |
private Report |
report
Report instance to show |
private int |
rows
rows |
(package private) SpreadSheet |
ss
SpreadSheet objecyt |
(package private) int |
startRow
ARG: start of table data to use, counts from 0 ? |
(package private) int |
tagCol
tag col for current clicked cell color |
(package private) int |
tagRow
tag row for current clicked cell color |
(package private) int |
tCols
ARG: # cols in Table data |
private java.lang.String[][] |
tData
ARG: user Table data [0:maxRows-1][0:maxCols-1] |
private java.lang.String[] |
tFields
ARG: [maxCols] Table field names from user |
(package private) java.lang.String |
title
ARG: title of spreadsheet |
(package private) int |
tRows
ARG: # rows in Table data |
(package private) boolean |
urlPopupFlag
popup browser flag |
(package private) boolean |
urlViewerFlag
button for browser control |
(package private) int |
virtualHdrPos
location of col clicked in virData |
Fields inherited from class java.awt.Frame |
base, CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, frameSerializedDataVersion, HAND_CURSOR, icon, ICONIFIED, mbManagement, menuBar, MOVE_CURSOR, N_RESIZE_CURSOR, nameCounter, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, ownedWindows, resizable, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, serialVersionUID, state, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR, weakThis |
Fields inherited from class java.awt.Window |
active, dbg, focusMgr, inputContext, inputContextLock, OPENED, ownedWindowList, showWithParent, warningString, windowListener, windowSerializedDataVersion |
Fields inherited from class java.awt.Container |
component, containerListener, containerSerializedDataVersion, dispatcher, layoutMgr, listeningBoundsChildren, listeningChildren, maxSize, ncomponents, printing, printingThreads |
Fields inherited from class java.awt.Component |
accessibleContext, 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 | |
(package private) |
ShowSpreadsheetPopup(MAExplorer mae,
Report report,
java.lang.String[] tFields,
java.lang.String[][] tData,
int lastRow,
int startRow,
int tRows,
int tCols,
java.lang.String fontSizeStr,
java.lang.String title,
java.lang.String[] altFieldNames,
int[] cellFormat,
java.lang.String[][] dataURL,
java.lang.String popupName,
int popupPropertyBits,
boolean urlViewerFlag)
ShowSpreadsheetPopup() - constructor to create a spreadsheet from raw data with URL spec. |
(package private) |
ShowSpreadsheetPopup(MAExplorer mae,
Report report,
Table t,
java.lang.String fontSizeStr,
java.lang.String title,
java.lang.String popupName,
int popupPropertyBits,
boolean urlViewerFlag)
ShowSpreadsheetPopup() - constructor to create a spreadsheet from table without URL spec. |
Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
actionPerformed() - Handle Control panel button clicks |
(package private) void |
close()
close() - close this popup and reset flags if needed |
private boolean |
createSpreadSheet()
createSpreadSheet() - create the the popup spreadsheet |
private java.lang.String[][] |
cvtTableToPrepData(java.lang.String[][] tData,
java.lang.String[] tFields,
int tRows,
int tCols)
cvtTableToPrepData() - cvt tFields & tData into one prepData[][] string[]. |
void |
itemStateChanged(java.awt.event.ItemEvent e)
|
(package private) void |
updateCurGene(int mid)
updateCurGene() - update plot if current gene changed and this type of report requires it. |
(package private) void |
updateFilter(GeneList ml)
updateFilter() - update plot if Filter changed and this type of report requires it. |
(package private) void |
updateLabels()
updateLabels() - update string report if labels changed and this type of report requires it. |
(package private) void |
updateSlider()
updateSlider() - update plot if Slider changed and this type of report requires it. |
void |
windowActivated(java.awt.event.WindowEvent e)
|
void |
windowClosed(java.awt.event.WindowEvent e)
|
void |
windowClosing(java.awt.event.WindowEvent e)
windowClosing() - close down the window. |
void |
windowDeactivated(java.awt.event.WindowEvent e)
|
void |
windowDeiconified(java.awt.event.WindowEvent e)
|
void |
windowIconified(java.awt.event.WindowEvent e)
|
void |
windowOpened(java.awt.event.WindowEvent e)
|
Methods inherited from class java.awt.Frame |
|
Methods inherited from class java.awt.Window |
addOwnedWindow, addWindowListener, adjustListeningChildren, applyResourceBundle, applyResourceBundle, connectOwnedWindow, dispatchEventImpl, dispose, eventEnabled, getFocusOwner, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getOwnedWindows, getOwner, getToolkit, getWarningString, hide, isActive, isShowing, nextFocus, ownedInit, pack, postEvent, postWindowEvent, preProcessKeyEvent, processEvent, processWindowEvent, removeOwnedWindow, removeWindowListener, resetGC, setCursor, setFocusOwner, setWarningString, show, toBack, toFront, transferFocus |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, applyOrientation, checkGD, countComponents, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventToSelf, doLayout, findComponentAt, findComponentAt, findComponentAt, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getInsets, getLayout, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, getWindow, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, numListening, paint, paintComponents, paintHeavyweightComponents, postsOldMouseEvents, preferredSize, print, printComponents, printHeavyweightComponents, processContainerEvent, proxyEnableEvents, proxyRequestFocus, remove, remove, removeAll, removeContainerListener, setFont, setLayout, update, validate, validateTree |
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, getHeight, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getSize, getToolkitImpl, getTreeLock, getWidth, getWindowForObject, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait |
Methods inherited from interface java.awt.MenuContainer |
getFont, postEvent |
Field Detail |
private MAExplorer mae
static final int DEF_COLS_TO_SHOW
static final int MAX_ROWS_TO_SHOW
static final int POPUP_WIDTH
static final int POPUP_HEIGHT
private Report report
private java.lang.String[] tFields
private java.lang.String[][] tData
private java.lang.String[][] dataURL
private java.lang.String[] altFieldNames
private java.lang.String[][] prepData
private int[] cellFormat
int prepHdrPos
int virtualHdrPos
int clickedCellRow
int clickedCellCol
int oldTagRow
int oldTagCol
int tagRow
int tagCol
int prepRows
int prepCols
int lastRow
int startRow
int tRows
int tCols
int fontSize
java.lang.String title
java.lang.String headerName
java.lang.String fontSizeStr
java.lang.String popupName
int popupPropertyBits
private int rows
private int cols
private java.awt.Font cellUrlFont
private java.awt.Font cellDataFont
private java.awt.Font buttonFont
private java.awt.Frame frame
SpreadSheet ss
java.awt.Checkbox cb
boolean urlViewerFlag
boolean urlPopupFlag
java.awt.Color headerClicked
java.awt.Color cellClicked
java.awt.Color cellReg
Constructor Detail |
ShowSpreadsheetPopup(MAExplorer mae, Report report, java.lang.String[] tFields, java.lang.String[][] tData, int lastRow, int startRow, int tRows, int tCols, java.lang.String fontSizeStr, java.lang.String title, java.lang.String[] altFieldNames, int[] cellFormat, java.lang.String[][] dataURL, java.lang.String popupName, int popupPropertyBits, boolean urlViewerFlag)
mae
- is the MAExplorer instancereport
- is the Report instance to displaytFields
- is the Table fieldstData
- is the Table datalastRow
- is the end of the regionstartRow
- is the start of the regiontRows
- is the # rows of tDatatCols
- is the # cols of tDatafontSizeStr
- is the cell font size "12pt", "10pt", "8pt"title
- of spreadsheetaltFieldNames
- if not null (name to display since data is URL type data)cellFormat
- is the cell type fields that may highlight some cellsdataURL
- is associated URL datapopupName
- is the name for PopupRegistrypopupPropertyBits
- is property bits for PopupRegistryurlViewerFlag
- if browser popup is enabledcreateSpreadSheet()
ShowSpreadsheetPopup(MAExplorer mae, Report report, Table t, java.lang.String fontSizeStr, java.lang.String title, java.lang.String popupName, int popupPropertyBits, boolean urlViewerFlag)
mae
- is the MAExplorer instancereport
- is the Report instance to displayt
- the Table instancefontSizeStr
- is the cell font size "12pt", "10pt", "8pt"title
- of spreadsheetpopupName
- is the name for PopupRegistrypopupPropertyBits
- is property bits for PopupRegistryurlViewerFlag
- if browser popup is enabledcreateSpreadSheet()
Method Detail |
private boolean createSpreadSheet()
PopupRegistry.addPopupWindowToReg(ShowPlotPopup, java.lang.String, int)
,
PopupRegistry.removePopupByKey(java.lang.String)
,
Util.cvFontS2I(java.lang.String)
,
cvtTableToPrepData(java.lang.String[][], java.lang.String[], int, int)
private java.lang.String[][] cvtTableToPrepData(java.lang.String[][] tData, java.lang.String[] tFields, int tRows, int tCols)
tFields
- is the Table fieldstData
- is the Table datatRows
- is the # rows of tDatatCols
- is the # cols of tDatapublic void itemStateChanged(java.awt.event.ItemEvent e)
itemStateChanged
in interface java.awt.event.ItemListener
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
e
- is ActionEvent for Buttonsclose()
public void windowClosing(java.awt.event.WindowEvent e)
windowClosing
in interface java.awt.event.WindowListener
e
- is window closing eventclose()
public void windowOpened(java.awt.event.WindowEvent e)
windowOpened
in interface java.awt.event.WindowListener
public void windowActivated(java.awt.event.WindowEvent e)
windowActivated
in interface java.awt.event.WindowListener
public void windowClosed(java.awt.event.WindowEvent e)
windowClosed
in interface java.awt.event.WindowListener
public void windowDeactivated(java.awt.event.WindowEvent e)
windowDeactivated
in interface java.awt.event.WindowListener
public void windowDeiconified(java.awt.event.WindowEvent e)
windowDeiconified
in interface java.awt.event.WindowListener
public void windowIconified(java.awt.event.WindowEvent e)
windowIconified
in interface java.awt.event.WindowListener
void updateCurGene(int mid)
mid
- is the new Master Gene ID of the current genevoid updateFilter(GeneList ml)
ml
- is the gene list to update now that filter has changed.void updateSlider()
void updateLabels()
Component.repaint()
void close()
PopupRegistry.removePopupByKey(java.lang.String)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |