Main Page | Namespace List | Class Hierarchy | Class List | Class Members | Related Pages

gov::lbl::genome::gui::panel::VistaPanel Class Reference

Inheritance diagram for gov::lbl::genome::gui::panel::VistaPanel:

Inheritance graph
[legend]
Collaboration diagram for gov::lbl::genome::gui::panel::VistaPanel:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 VistaPanel (VistaApp vapp)
 VistaPanel (VistaApp vapp, int line)
 VistaPanel (VistaApp vapp, PageFormat pf, int line)
 VistaPanel (VistaApp vapp, PageFormat pf)
String getFormattedXDisplayString (int currXPos)
String getFormattedXDisplayString (int currXPos, int line)
int getXDisplay (int currXPos)
int getXDisplay (int currXPos, int line)
String getFormattedNumberString (double x, int maxFracDigits)
String getFormattedNumberString (int x, int maxFracDigits)
int getHorizSize ()
int getVertSize ()
void paintComponent (Graphics g)
Graphics2D createImage ()
void removeImage ()
void setImage (BufferedImage im)
int getStringWidth (String s, Font f)
String shortenString (String s, Font f, int width)

Protected Member Functions

int convertX (long x)
int convertX (double x)

Protected Attributes

boolean wait_cursor = false
int topSpace = UIConstants.COOR_DISPLAY_HEIGHT
int bottomSpace = UIConstants.COOR_DISPLAY_HEIGHT
int leftSpace = 0
int rightSpace = 0
int vertSize
int horizSize
int top
int bottom
int height
long minX
long maxX
int offsetWidth = UIConstants.GRAPH_OFFSET_WIDTH
double pixelWidth
DecimalFormat df = new DecimalFormat()
Cursor waitCursor = new Cursor(Cursor.WAIT_CURSOR)
BufferedImage image = null
Graphics2D g2d = null

Detailed Description

Title: VistaPanel

Description: Parent class for many panels

Copyright: Copyright (c) 2002 Ernest Orlando Lawrence Berkeley National Laboratory

Company: LBNL

Author:
Mike Teplitskiy
Version:
2.0


Constructor & Destructor Documentation

gov::lbl::genome::gui::panel::VistaPanel::VistaPanel VistaApp  vapp  )  [inline]
 

VistaPanel

Parameters:
vapp VistaApp

gov::lbl::genome::gui::panel::VistaPanel::VistaPanel VistaApp  vapp,
int  line
[inline]
 

Parameters:
vapp VistaApp
line int

gov::lbl::genome::gui::panel::VistaPanel::VistaPanel VistaApp  vapp,
PageFormat  pf,
int  line
[inline]
 

Parameters:
vapp VistaApp
pf PageFormat
line int

gov::lbl::genome::gui::panel::VistaPanel::VistaPanel VistaApp  vapp,
PageFormat  pf
[inline]
 

Parameters:
vapp VistaApp
pf PageFormat


Member Function Documentation

int gov::lbl::genome::gui::panel::VistaPanel::convertX double  x  )  [inline, protected]
 

convert chromosome coordinates into screen (panel) coordinates

Parameters:
x double
Returns:
int

int gov::lbl::genome::gui::panel::VistaPanel::convertX long  x  )  [inline, protected]
 

convert chromosome coordinates into screen (panel) coordinates

Parameters:
x long
Returns:
int

Graphics2D gov::lbl::genome::gui::panel::VistaPanel::createImage  )  [inline]
 

create transparent bitmap image. It's dimentions are taken from the panel size. Return Graphics2D

Returns:
Graphics2D

Reimplemented in gov::lbl::genome::gui::GeneralGraphComp, gov::lbl::genome::gui::panel::AnnotationPanel, gov::lbl::genome::gui::panel::AxisPanel, gov::lbl::genome::gui::panel::ChromPanel, gov::lbl::genome::gui::panel::ContigPanel, gov::lbl::genome::gui::panel::RepeatPanel, and gov::lbl::genome::gui::panel::XAxisPanel.

String gov::lbl::genome::gui::panel::VistaPanel::getFormattedNumberString int  x,
int  maxFracDigits
[inline]
 

return formattes string

Parameters:
x int
maxFracDigits int
Returns:
String

String gov::lbl::genome::gui::panel::VistaPanel::getFormattedNumberString double  x,
int  maxFracDigits
[inline]
 

return formatted string

Parameters:
x double
maxFracDigits int
Returns:
String

String gov::lbl::genome::gui::panel::VistaPanel::getFormattedXDisplayString int  currXPos,
int  line
[inline]
 

This method converts an x-coordinate on the data display panel to an x-coordinate on the graph and return formatted string.

Parameters:
currXPos int
Returns:
String

String gov::lbl::genome::gui::panel::VistaPanel::getFormattedXDisplayString int  currXPos  )  [inline]
 

This method converts an x-coordinate on the data display panel to an x-coordinate on the graph and return formatted string.

Parameters:
currXPos int
Returns:
String

int gov::lbl::genome::gui::panel::VistaPanel::getHorizSize  )  [inline]
 

return adjusted panel width

Returns:
int

int gov::lbl::genome::gui::panel::VistaPanel::getStringWidth String  s,
Font  f
[inline]
 

return width in pixels for the strind s and font f

Parameters:
s String
f Font
Returns:
int

int gov::lbl::genome::gui::panel::VistaPanel::getVertSize  )  [inline]
 

return adjusted panel height

Returns:
int

int gov::lbl::genome::gui::panel::VistaPanel::getXDisplay int  currXPos,
int  line
[inline]
 

convert screen coordinates into chromosome coordinates

Parameters:
currXPos int
line int
Returns:
int

int gov::lbl::genome::gui::panel::VistaPanel::getXDisplay int  currXPos  )  [inline]
 

convert screen coordinates into chromosome coordinates

Parameters:
currXPos int
Returns:
int

void gov::lbl::genome::gui::panel::VistaPanel::paintComponent Graphics  g  )  [inline]
 

paintComponent overload JPanel paintComponent. Prepare some parameters. If image does not exist - create it first. Draw image.

Parameters:
g Graphics

Reimplemented in gov::lbl::genome::gui::GeneralGraphComp, and gov::lbl::genome::gui::panel::TracerPanel.

void gov::lbl::genome::gui::panel::VistaPanel::removeImage  )  [inline]
 

remove image. New image will be created during next paintComponent() call

Reimplemented in gov::lbl::genome::gui::GeneralGraphComp, and gov::lbl::genome::gui::panel::TracerPanel.

void gov::lbl::genome::gui::panel::VistaPanel::setImage BufferedImage  im  )  [inline]
 

set new image created by somebody else. Dont forget to call repaint();

String gov::lbl::genome::gui::panel::VistaPanel::shortenString String  s,
Font  f,
int  width
[inline]
 

shorten string is useful if string is long and does not fit in width.

Parameters:
s String
f Font
width int
Returns:
String


The documentation for this class was generated from the following file:
Generated on Wed Jan 19 17:03:01 2005 by  doxygen 1.3.9.1