public Point getPanelPos ( int structure , int pos ) { Point p = new Point ( ) ; int lineNr = pos / DEFAULT_LINE_LENGTH ; int linePos = pos % DEFAULT_LINE_LENGTH ; int x = linePos * DEFAULT_CHAR_SIZE + DEFAULT_X_SPACE + DEFAULT_LEGEND_SIZE ; int y = lineNr * DEFAULT_Y_STEP + DEFAULT_Y_SPACE ; y += DEFAULT_LINE_SEPARATION * structure ; p . setLocation ( x , y ) ; return p ; }
Get the X position on the Panel of a particular sequence position .