Class ImageScroller

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by java.awt.Panel
              extended by ImageScroller
All Implemented Interfaces:
java.awt.event.AdjustmentListener, java.awt.event.TextListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible

public class ImageScroller
extends java.awt.Panel
implements java.awt.event.AdjustmentListener, java.awt.event.TextListener

ImageScroller class supports a scrollable image for the Left and right images. It is also used for the top flicker window with scrolling disabled. It acquires an image and has a text-title, image canvas, horizontal and vertical scroll bars, and delay scrollbar (for flickering). The ImageScroller is generally created as part of the GUI before the image has been loaded. Therefore, we need to do several setXXXX() fct calls after the image has been loaded to tell the ImageScroller "stuff" it will need.

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 Flicker Mozilla and Legal files are available on http://open2dprot.sourceforge.net/Flicker

Version:
$Date$ $Revision$
Author:
P. Lemkin (LECB/NCI), G. Thornwall (SAIC), Frederick, MD
See Also:
Flicker Home, Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.awt.Panel
java.awt.Panel.AccessibleAWTPanel
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
(package private)  java.awt.Adjustable aH
          deals with scroller events
(package private)  java.awt.Adjustable aV
          deals with scroller events
(package private)  BrightnessContrastFilter bcImgF
          Instance of Brightness/Contrast Filter.
 java.awt.Scrollbar delayBar
          opt.
 javax.swing.JLabel delayLabel
          opt.
 java.awt.Panel dPanel
          opt.
private  Flicker flk
           
 int guardHeight
          size of top & bottom guard region
 int guardImgHeight
          size of img with guard region
 int guardImgWidth
          size of img with guard region
 boolean guardRegionFlag
          guard region flag
 int guardWidth
          size of right & left guard region
 ImageData iData
          Image data for mapGraytoOD[] that will be set later...
 boolean img_selectedFlag
          set if xObj,yObj is set
 int isHeight
          height of image from iData.iHeight or zoomed data
 int isWidth
          width of image from iData.iWidth or zoomed data
static java.lang.String lastISName
          last image scroller - used in new operation "flicker", "left", "right"
 java.lang.String name
          obj name "left", "right" or "both".
 java.lang.String oGifFileName
          Name of GIF file used in "SaveAs" of oImg to local GIF file
(package private)  int oldIHeight
          calc ScrollPostions
(package private)  int oldIWidth
          calc ScrollPostions
 int pagestep
          thickness of scroller
 int preferredHeight
          preferred height of canvas
 int preferredWidth
          preferred width of canvas
(package private)  boolean repackFlag
           
(package private)  java.awt.Point scrollPos
          keep track of ScrollPostions
 ScrollableImageCanvas siCanvas
          pointer to the associated image canvas
 java.awt.Panel southPanel
          opt.
(package private)  java.awt.ScrollPane sp
          scroller for the canvas, siCanvas
 SliderState state
          SliderState threshold parameters associated with the image
 int steps
          prewired scroller steps
 java.lang.String title
          current title for image scroller associated with iData
 java.awt.TextField txtField
          image title placed above canvas
(package private)  boolean useScrollBarsFlag
          create and use scrollers flag
private  Util util
           
(package private)  int xObj
          X cursor position mapped to image
(package private)  int yObj
          Y cursor position mapped to image
 
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
ImageScroller(Flicker flk, java.lang.String name, java.lang.String title, ImageData iData, int preferredWidth, int preferredHeight, int def_delay, int min_delay, int max_delay, boolean useScrollBarsFlag)
          ImageScroller() - constructor.
 
Method Summary
 void addGuardRegion(boolean guardRegionFlag)
          addGuardRegion() - set up siCanvas for guard region
 void adjustmentValueChanged(java.awt.event.AdjustmentEvent e)
          adjustmentValueChanged() - handle ImageScroller scroll events.
 void clearLandmarkTextListToDraw()
          clearLandmarkTextListToDraw() - disable text list of things to draw in canvas.
 java.lang.String cvFeatures2str(java.lang.String imgFile)
          cvFeatures2str() - cvt object features to printable string
 void drawImageTitle()
          drawImageTitle() - draw title in image.
 void finishMeasurement()
          finishMeasurement() - finish measurement and compute features
 java.awt.Color[] getColorText()
          getColorText() - text list items colors
 int getDelay()
          getDelay() - get the Image delay time
 java.awt.Font[] getFontText()
          getFontText() - get text list fonts
 java.awt.Dimension getGuardRegionDimension(double mag)
          getGuardRegionDimension() - return guard size
 java.awt.Point getImgCursor()
          getImgCursor() - get the (x,y) scrollable cursor for this image If there is no cursor, then return (0,0).
 java.awt.Point getImgCursorMax()
          getImgCursorMax() - get the (x,y) scrollable cursor Maximum for image If there is no cursor, then return (0,0).
 java.awt.Point getImgPosition()
          getImgPosition() - get the Image position.
 int getMaxScrollBarHeight()
          getMaxScrollBarHeight() - return scroll max height
 int getMaxScrollBarWidth()
          getMaxScrollBarWidth() - return scroll max width
 int getNbrTextItems()
          getNbrTextItems() - return actual number of text items to display
 java.awt.Point getObjPosition()
          getObjPosition() - get the object position.
 java.awt.Dimension getPreferredSize()
          getPreferredSize() - getPreferredSize, needed for sizing canvas and ScrollPane correctly.
 int getScrollbarHeight()
          getScrollBarHeight() - return scroll height position
 int getScrollbarWidth()
          getScrollBarWidth() - return scroll width position
 java.awt.Point getScrollPosition()
          getScrollPosition() - return scroll positions
 java.lang.String[] getText()
          getText() - text list items
 boolean getValidFeaturesFlag()
          getValidFeaturesFlag() - get the valid features set after measurement
 int getXObjPosition()
          getXObjPosition() - get the X object position.
 int[] getXText()
          getXText() - x text list items positions
 int getYObjPosition()
          getYObjPosition() - get the X object position.
 int[] getYText()
          getYText() - y text list items positions
 void paint(java.awt.Graphics g)
          paintComponent() - repaint scrollable canvas in region defined by scroll bars
 void paintSiCanvas()
          paintSiCanvas() - paint the scrollable canvas using thread safe method in one place.
 boolean processBCimage(ImageData id)
          processBCimage() - process colormap image by running the filter.
 void resizeImageCanvas(java.awt.Image img, int newWidth, int newHeight, double mag)
          resizeImageCanvas() - Reset Image, used in zoom and dezoom.
 void saveAsOverlayFile(java.lang.String saveAsImgFile)
          saveAsOverlayFile() - save repainted image as GIF file
(package private)  boolean saveOImgAsGifFile(java.lang.String defGifFile, boolean promptForFileFlag)
          saveOImgAsGifFile() - save the oImg into a Gif image file in the < userDir >/tmp/.
 void setBndState(boolean bndOpenFlag)
          setBndState() - set the boundary state in the imageCanvas
 void setCanvasSize(int size)
          setCanvasSize() - change the size of this Canvas.
 void setCanvasSize(int preferredWidth, int preferredHeight)
          setCanvasSize() - change the size of this Canvas.
 void setcurrentIS(ImageScroller currentIS)
          setcurrentIS() - set the currentIS, used when flickering
 void setGuardRegion(int newImgWidth, int newImgHeight, double zoomMag)
          setGuardRegion() - force siCanvas to create guard region
 void setImageData(ImageData iData)
          setImageData() - change the ImageData for the panel.
 void setImageData(ImageData iData, java.awt.Point xyImg)
          setImageData() - change the ImageData for the panel.
 void setImgPosition(int xImg, int yImg)
          setImgPosition() - set the Image position.
 void setImgPosition(java.awt.Point xyImg)
          setImgPosition() - set the Image position.
 void setLandmarksTextListToDraw(int nTextItems, java.awt.Color[] color_text, java.lang.String[] text, java.awt.Font[] font_text, int[] x_text, int[] y_text)
          setLandmarksTextListToDraw() - set text list including color and position.
 void setObjPosition(int xObj, int yObj)
          setObjPosition() - set the object position.
 void setObjPosition(java.awt.Point xyObj)
          setObjPosition() - set the object position.
 void setTitle(java.lang.String title, boolean saveTitleFlag)
          setTitle() - change the title for the panel.
 void startMeasurement(java.lang.String measType)
          startMeasurement() - start measurement of object.
 void textValueChanged(java.awt.event.TextEvent e)
          textValueChanged() - process text change events in image title text area NOTE: this is DEPRICATED!
 void update(java.awt.Graphics g)
          update() - update without background the scrollable canvas
(package private)  void updateClickableCanvas()
          updateClickableCanvas() - perform canvas update operations invoked by various controls
 
Methods inherited from class java.awt.Panel
addNotify, getAccessibleContext
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, paramString, preferredSize, print, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, removeNotify, setComponentZOrder, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, 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, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

flk

private Flicker flk

util

private Util util

lastISName

public static java.lang.String lastISName
last image scroller - used in new operation "flicker", "left", "right"


iData

public ImageData iData
Image data for mapGraytoOD[] that will be set later...


isWidth

public int isWidth
width of image from iData.iWidth or zoomed data


isHeight

public int isHeight
height of image from iData.iHeight or zoomed data


state

public SliderState state
SliderState threshold parameters associated with the image


siCanvas

public ScrollableImageCanvas siCanvas
pointer to the associated image canvas


southPanel

public java.awt.Panel southPanel
opt. holds vs & Delay scroll box SOUTH


dPanel

public java.awt.Panel dPanel
opt. holds Delay scroll label & bar


delayLabel

public javax.swing.JLabel delayLabel
opt. label for image delay


delayBar

public java.awt.Scrollbar delayBar
opt. scroll bar for image delay


txtField

public java.awt.TextField txtField
image title placed above canvas


preferredWidth

public int preferredWidth
preferred width of canvas


preferredHeight

public int preferredHeight
preferred height of canvas


steps

public int steps
prewired scroller steps


pagestep

public int pagestep
thickness of scroller


img_selectedFlag

public boolean img_selectedFlag
set if xObj,yObj is set


useScrollBarsFlag

boolean useScrollBarsFlag
create and use scrollers flag


repackFlag

boolean repackFlag

oGifFileName

public java.lang.String oGifFileName
Name of GIF file used in "SaveAs" of oImg to local GIF file


name

public java.lang.String name
obj name "left", "right" or "both".


title

public java.lang.String title
current title for image scroller associated with iData


sp

java.awt.ScrollPane sp
scroller for the canvas, siCanvas


aH

java.awt.Adjustable aH
deals with scroller events


aV

java.awt.Adjustable aV
deals with scroller events


scrollPos

java.awt.Point scrollPos
keep track of ScrollPostions


oldIWidth

int oldIWidth
calc ScrollPostions


oldIHeight

int oldIHeight
calc ScrollPostions


bcImgF

BrightnessContrastFilter bcImgF
Instance of Brightness/Contrast Filter. It is reused across images for this image scroller.


xObj

int xObj
X cursor position mapped to image


yObj

int yObj
Y cursor position mapped to image


guardRegionFlag

public boolean guardRegionFlag
guard region flag


guardWidth

public int guardWidth
size of right & left guard region


guardHeight

public int guardHeight
size of top & bottom guard region


guardImgWidth

public int guardImgWidth
size of img with guard region


guardImgHeight

public int guardImgHeight
size of img with guard region

Constructor Detail

ImageScroller

public ImageScroller(Flicker flk,
                     java.lang.String name,
                     java.lang.String title,
                     ImageData iData,
                     int preferredWidth,
                     int preferredHeight,
                     int def_delay,
                     int min_delay,
                     int max_delay,
                     boolean useScrollBarsFlag)
ImageScroller() - constructor. Resize to prefered size.

Parameters:
flk - is instance of flicker
name -
title -
iData - is current ImageData iData - this may change for flicker Image Scroller
preferredWidth - is size of canvas
preferredHeight -
def_delay - is Flicker delay scroll bar values
min_delay -
max_delay -
useScrollBarsFlag -
Method Detail

setGuardRegion

public void setGuardRegion(int newImgWidth,
                           int newImgHeight,
                           double zoomMag)
setGuardRegion() - force siCanvas to create guard region

Parameters:
newImgWidth - new image width
newImgHeight - new image height
zoomMag - magification factor

addGuardRegion

public void addGuardRegion(boolean guardRegionFlag)
addGuardRegion() - set up siCanvas for guard region

Parameters:
guardRegionFlag - boolean to turn on/off guard region

getGuardRegionDimension

public java.awt.Dimension getGuardRegionDimension(double mag)
getGuardRegionDimension() - return guard size

Returns:
guard region point

resizeImageCanvas

public void resizeImageCanvas(java.awt.Image img,
                              int newWidth,
                              int newHeight,
                              double mag)
resizeImageCanvas() - Reset Image, used in zoom and dezoom.

Parameters:
img - is the image to set to be drawn
newWidth - tof the canvas
newHeight - tof the canvas
mage - of the canvas

getPreferredSize

public java.awt.Dimension getPreferredSize()
getPreferredSize() - getPreferredSize, needed for sizing canvas and ScrollPane correctly. NOTE: Used offsets since scroll bars take up space from the canvas.

Overrides:
getPreferredSize in class java.awt.Container
Returns:
canvas size

setCanvasSize

public void setCanvasSize(int size)
setCanvasSize() - change the size of this Canvas. We assume that the legality of the new size is checked prior to this method being called.

Parameters:
size - is new size

setCanvasSize

public void setCanvasSize(int preferredWidth,
                          int preferredHeight)
setCanvasSize() - change the size of this Canvas. We assume that the legality of the new size is checked prior to this method being called.

Parameters:
preferredWidth - is new width
preferredHeight - is new height

setImageData

public void setImageData(ImageData iData)
setImageData() - change the ImageData for the panel. Note: this method is needed since iData may not exist when the ImageScroller was created. [DEPRICATED?]

Parameters:
iData - is Image data

setImageData

public void setImageData(ImageData iData,
                         java.awt.Point xyImg)
setImageData() - change the ImageData for the panel. Note: this method is needed since iData may not exist when the ImageScroller was created. [DEPRICATED?]

Parameters:
iData - is Image data
xyImg - is the position of the image in the scrollable canvas

setTitle

public void setTitle(java.lang.String title,
                     boolean saveTitleFlag)
setTitle() - change the title for the panel. You can do a temporary change or a permanent change.

Parameters:
title - to use
saveTitleFlag - if keep title change

getDelay

public int getDelay()
getDelay() - get the Image delay time


setImgPosition

public void setImgPosition(java.awt.Point xyImg)
setImgPosition() - set the Image position. Don't repaint here...

Parameters:
xyImg - is current image position

setImgPosition

public void setImgPosition(int xImg,
                           int yImg)
setImgPosition() - set the Image position. Don't repaint here...

Parameters:
xImg - is current image position
yImg - is current image position

getImgPosition

public java.awt.Point getImgPosition()
getImgPosition() - get the Image position.

Returns:
image position

setObjPosition

public void setObjPosition(java.awt.Point xyObj)
setObjPosition() - set the object position. Don't repaint here...

Parameters:
xyObj - is object position

setObjPosition

public void setObjPosition(int xObj,
                           int yObj)
setObjPosition() - set the object position. Don't repaint here...

Parameters:
xObj - is object position
yObj - is object position

setcurrentIS

public void setcurrentIS(ImageScroller currentIS)
setcurrentIS() - set the currentIS, used when flickering

Parameters:
currentIS - is current ImageScroller (right or left)

getObjPosition

public java.awt.Point getObjPosition()
getObjPosition() - get the object position.

Returns:
current object position

getXObjPosition

public int getXObjPosition()
getXObjPosition() - get the X object position.

Returns:
current X object position

getYObjPosition

public int getYObjPosition()
getYObjPosition() - get the X object position.

Returns:
current X object position

getScrollPosition

public java.awt.Point getScrollPosition()
getScrollPosition() - return scroll positions

Returns:
Point of scroll position

getScrollbarWidth

public int getScrollbarWidth()
getScrollBarWidth() - return scroll width position

Returns:
int scroll position

getScrollbarHeight

public int getScrollbarHeight()
getScrollBarHeight() - return scroll height position

Returns:
int scroll position

getMaxScrollBarWidth

public int getMaxScrollBarWidth()
getMaxScrollBarWidth() - return scroll max width

Returns:
int scroll max position

getMaxScrollBarHeight

public int getMaxScrollBarHeight()
getMaxScrollBarHeight() - return scroll max height

Returns:
int scroll max position

setBndState

public void setBndState(boolean bndOpenFlag)
setBndState() - set the boundary state in the imageCanvas

Parameters:
bndOpenFlag - open/close boundary state flag

getValidFeaturesFlag

public boolean getValidFeaturesFlag()
getValidFeaturesFlag() - get the valid features set after measurement

Returns:
valid features flag

startMeasurement

public void startMeasurement(java.lang.String measType)
startMeasurement() - start measurement of object.

Parameters:
measType - type specified as "Quant" or "Bkgrd"

finishMeasurement

public void finishMeasurement()
finishMeasurement() - finish measurement and compute features


cvFeatures2str

public java.lang.String cvFeatures2str(java.lang.String imgFile)
cvFeatures2str() - cvt object features to printable string

Parameters:
imgFile - to display
Returns:
printable features string

setLandmarksTextListToDraw

public void setLandmarksTextListToDraw(int nTextItems,
                                       java.awt.Color[] color_text,
                                       java.lang.String[] text,
                                       java.awt.Font[] font_text,
                                       int[] x_text,
                                       int[] y_text)
setLandmarksTextListToDraw() - set text list including color and position. To disable the list, just set nTextItems to 0.

Parameters:
nTextItems - is the number of text items
color_text - is list of text label colors
text - is list of text labels
font_text - is list of fonts of labels
x_text - is list of x coordinates of labels
y_text - is list of y coordinates of labels

clearLandmarkTextListToDraw

public void clearLandmarkTextListToDraw()
clearLandmarkTextListToDraw() - disable text list of things to draw in canvas.


getNbrTextItems

public int getNbrTextItems()
getNbrTextItems() - return actual number of text items to display

Returns:
nbr text items to display

getColorText

public java.awt.Color[] getColorText()
getColorText() - text list items colors

Returns:
text list items colors

getText

public java.lang.String[] getText()
getText() - text list items

Returns:
text list items

getFontText

public java.awt.Font[] getFontText()
getFontText() - get text list fonts

Returns:
text list fonts

getXText

public int[] getXText()
getXText() - x text list items positions

Returns:
x text list items positions

getYText

public int[] getYText()
getYText() - y text list items positions

Returns:
y text list items positions

processBCimage

public boolean processBCimage(ImageData id)
processBCimage() - process colormap image by running the filter. NOTE: need to do repaint() just after this call. NOTE: we must sync this so that it completes a full image computation before we do it again. If not allowing image transforms (i.e. !flk.allowXformFlag), then use the id.iImg. Otherwise, if we are composing output images then use id.oImg else id.iImg. It creates the id.bcImg in the process if successful

Parameters:
id - is the ImageData to get the image to process
Returns:
true if succeed

drawImageTitle

public void drawImageTitle()
drawImageTitle() - draw title in image. This uses the mouse position in the canvas to get the [x,y,g(x,y)/od(x,y)] values and set it to: + (x,y,g) + "[use]" <P> <DD><DL> </DL> </DD> <DD><DL> </DL> </DD> </DL> <HR> <A NAME="getImgCursor()"><!-- --></A><H3> getImgCursor</H3> <PRE> public java.awt.Point <B>getImgCursor</B>()</PRE> <DL> <DD>getImgCursor() - get the (x,y) scrollable cursor for this image If there is no cursor, then return (0,0). <P> <DD><DL> </DL> </DD> <DD><DL> <DT><B>Returns:</B><DD>image cursor point</DL> </DD> </DL> <HR> <A NAME="getImgCursorMax()"><!-- --></A><H3> getImgCursorMax</H3> <PRE> public java.awt.Point <B>getImgCursorMax</B>()</PRE> <DL> <DD>getImgCursorMax() - get the (x,y) scrollable cursor Maximum for image If there is no cursor, then return (0,0). <P> <DD><DL> </DL> </DD> <DD><DL> <DT><B>Returns:</B><DD>image cursor point maximum</DL> </DD> </DL> <HR> <A NAME="updateClickableCanvas()"><!-- --></A><H3> updateClickableCanvas</H3> <PRE> void <B>updateClickableCanvas</B>()</PRE> <DL> <DD>updateClickableCanvas() - perform canvas update operations invoked by various controls <P> <DD><DL> </DL> </DD> <DD><DL> </DL> </DD> </DL> <HR> <A NAME="adjustmentValueChanged(java.awt.event.AdjustmentEvent)"><!-- --></A><H3> adjustmentValueChanged</H3> <PRE> public void <B>adjustmentValueChanged</B>(java.awt.event.AdjustmentEvent e)</PRE> <DL> <DD>adjustmentValueChanged() - handle ImageScroller scroll events. Handle ImageScroller scroll events & cause repaint of canvas. If we are using the scroll bar for this canvas, then set the obj position for use by other canvas for the same image. Handle the delay scrollbar as well if it exists. <P> <DD><DL> <DT><B>Specified by:</B><DD><CODE>adjustmentValueChanged</CODE> in interface <CODE>java.awt.event.AdjustmentListener</CODE></DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>e</CODE> - is adjustment event for scroll bars</DL> </DD> </DL> <HR> <A NAME="textValueChanged(java.awt.event.TextEvent)"><!-- --></A><H3> textValueChanged</H3> <PRE> public void <B>textValueChanged</B>(java.awt.event.TextEvent e)</PRE> <DL> <DD>textValueChanged() - process text change events in image title text area NOTE: this is DEPRICATED! <P> <DD><DL> <DT><B>Specified by:</B><DD><CODE>textValueChanged</CODE> in interface <CODE>java.awt.event.TextListener</CODE></DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>e</CODE> - is text event</DL> </DD> </DL> <HR> <A NAME="saveAsOverlayFile(java.lang.String)"><!-- --></A><H3> saveAsOverlayFile</H3> <PRE> public void <B>saveAsOverlayFile</B>(java.lang.String saveAsImgFile)</PRE> <DL> <DD>saveAsOverlayFile() - save repainted image as GIF file <P> <DD><DL> </DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>saveAsImgFile</CODE> - is full path name of the GIF file to write</DL> </DD> </DL> <HR> <A NAME="saveOImgAsGifFile(java.lang.String, boolean)"><!-- --></A><H3> saveOImgAsGifFile</H3> <PRE> boolean <B>saveOImgAsGifFile</B>(java.lang.String defGifFile, boolean promptForFileFlag)</PRE> <DL> <DD>saveOImgAsGifFile() - save the oImg into a Gif image file in the < userDir >/tmp/. This sets it up and lets paint() do the heavy lifting... <P> <DD><DL> </DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>defGifFile</CODE> - is the full path GIF output file<DD><CODE>promptForFileFlag</CODE> - if want to have user overide file name <DT><B>Returns:</B><DD>true if successful, false if unable to generate image file.<DT><B>See Also:</B><DD><CODE>Component.repaint()</CODE></DL> </DD> </DL> <HR> <A NAME="paintSiCanvas()"><!-- --></A><H3> paintSiCanvas</H3> <PRE> public void <B>paintSiCanvas</B>()</PRE> <DL> <DD>paintSiCanvas() - paint the scrollable canvas using thread safe method in one place. <P> <DD><DL> </DL> </DD> <DD><DL> </DL> </DD> </DL> <HR> <A NAME="update(java.awt.Graphics)"><!-- --></A><H3> update</H3> <PRE> public void <B>update</B>(java.awt.Graphics g)</PRE> <DL> <DD>update() - update without background the scrollable canvas <P> <DD><DL> <DT><B>Overrides:</B><DD><CODE>update</CODE> in class <CODE>java.awt.Container</CODE></DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>g</CODE> - is graphics context</DL> </DD> </DL> <HR> <A NAME="paint(java.awt.Graphics)"><!-- --></A><H3> paint</H3> <PRE> public void <B>paint</B>(java.awt.Graphics g)</PRE> <DL> <DD>paintComponent() - repaint scrollable canvas in region defined by scroll bars <P> <DD><DL> <DT><B>Overrides:</B><DD><CODE>paint</CODE> in class <CODE>java.awt.Container</CODE></DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>g</CODE> - is graphics context</DL> </DD> </DL> <!-- ========= END OF CLASS DATA ========= --> <HR> <!-- ======= START OF BOTTOM NAVBAR ====== --> <A NAME="navbar_bottom"><!-- --></A> <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_bottom_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev">  <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ImageScroller.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> </EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="ImageIO.html" title="class in <Unnamed>"><B>PREV CLASS</B></A>   <A HREF="ImageXform.html" title="class in <Unnamed>"><B>NEXT CLASS</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="index.html?ImageScroller.html" target="_top"><B>FRAMES</B></A>    <A HREF="ImageScroller.html" target="_top"><B>NO FRAMES</B></A>    <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: <A HREF="#nested_classes_inherited_from_class_java.awt.Panel">NESTED</A> | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_bottom"></A> <!-- ======== END OF BOTTOM NAVBAR ======= --> <HR> </BODY> </HTML>