public abstract class DataArea extends AlignmentSubArea implements AlignmentModelChangeListener
AlignmentArea must be inherited from this class.DISPATCHER_MAP, repaintRequested| Constructor and Description |
|---|
DataArea(AlignmentContentArea owner,
AlignmentArea labeledArea)
Creates a new instance of this class.
|
| Modifier and Type | Method and Description |
|---|---|
AlignmentArea |
getLabeledAlignmentArea()
Returns the alignment area that is labeled by this data area.
|
AlignmentModel<?> |
getLabeledAlignmentModel()
Convenience method that returns the alignment model of the labeled alignment area.
|
double |
getLengthAfterEnd()
Returns the length in pixels considering the current zoom factor this component needs to display
data right of the last alignment column.
|
double |
getLengthBeforeStart()
Returns the length in pixels considering the current zoom factor this component needs to display
data left of the first alignment column.
|
DataAreaList |
getList()
Returns the list this data area is contained in.
|
boolean |
isVisible()
Indicates whether this data area is currently faded in or out in the containing alignment area.
|
void |
setList(DataAreaList list)
Updates the list this element is contained in.
|
boolean |
setVisible(boolean visible)
Fades this data area in or out and lets the containing alignment area repaint, if necessary.
|
abstract java.util.Set<DataAreaListType> |
validLocations()
The result should enumerate all valid locations where the implementing data area is allowed to be located.
|
createLabelSubArea, getHeight, getLabelSubArea, getOwner, getSize, paint, paintPart, repaintaddKeyListener, addMouseListener, addMouseWheelListener, assignSize, dispatchEvent, getCurrentToolkit, getKeyListenersSet, getMouseListenersSet, getMouseWheelListenersSet, getSwingComponentClassName, getSwingComponentConstructorParameters, getSWTComponentClassName, getSWTComponentConstructorParameters, getToolkitComponent, hasDefinedSize, hasToolkitComponent, isUpdateOngoing, removeKeyListener, removeMouseListener, removeWheelMouseListener, setToolkitComponent, setUpdateOngoingclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitafterModelChanged, afterSequenceChange, afterSequenceRenamed, afterTokenChangepublic DataArea(AlignmentContentArea owner, AlignmentArea labeledArea)
owner - the alignment area that will contain this instancelabeledArea - the alignment area displays the sequence which is labeled by the new instance
(If null is specified here, the parent alignment area of owner will be assumed.)public AlignmentArea getLabeledAlignmentArea()
Note that inside a MultipleAlignmentsContainer a data area could be located in a different
alignment area than the related alignment data. Therefore the returned instance is not necessarily
identical with the instance returned by getOwner().getOwner().
getLabeledAlignmentModel()public AlignmentModel<?> getLabeledAlignmentModel()
getLabeledAlignmentArea()public DataAreaList getList()
public void setList(DataAreaList list)
list - the list that contains this elementpublic boolean isVisible()
It does not state whether this data area is contained a area of the alignment area that is currently visible on the screen.
true if this data area is faded in, false if it is faded outpublic boolean setVisible(boolean visible)
visible - true if the state of this element was changed, false otherwisepublic abstract java.util.Set<DataAreaListType> validLocations()
An implementation for a data area could be located everywhere could look like this:
return EnumSet.of(DataAreaListType.TOP, DataAreaListType.BOTTOM, DataAreaListType.SEQUENCE);
public double getLengthBeforeStart()
Overwrite this method if your component displays additional information left of the alignment.
public double getLengthAfterEnd()
Overwrite this method if your component displays additional information right of the alignment.