John W. Campbell
This class provides an object to display the coverage of the unique
asymmetric unit for a set of X-ray diffraction data. The coverage
can be examined a layer at a time or it is possible to allow the display
to cycle automatically through the layers.
pattern.
Class, fields, constructor and methods:
Class Details
Accessible Fields
Constructor
Operational Methods
Resource Methods
Standard Positioning and Sizing
Overriden Superclass Methods
- Package:
- Jdl.JdlView;
- Class name:
- JdlShowUnique
- Class definition:
- public class JdlShowUnique
- Extends:
- JPanel
- Implements:
- JdlFramedPanelDrawer
JdlButtonDrawer
ActionListener
MouseListener
MouseMotionListener
JdlViewObject
Printable
Runnable
- Actions:
- none
The following accessible fields have been defined:
- public final static int ROTATION
- Display type: Rotation data.
- public final static int LAUE
- Display type: Laue data.
- public final static int RESIZE_NONE
- Resize option - do not resize pattern area.
- public final static int RESIZE_ZOOM
- Resize option - zoom image on resize - keep aspect ratio.
- static final long serialVersionUID
- public final static int PREFERRED
- Size Constraint: preferred size
- public final static int FREE
- Size/Location Constraint: free
A single constructor is available.
Constructor:
Standard constructor
Constructs a JdlShowUnique object with the required resources.
- Constructor Definition:
- public JdlShowUnique (int size, int rsz_opt, JdlViewOptions view_opts)
- Parameters List:
- size
- The required size for the pattern display area of the object
(odd number - even given it will be increased by 1).
- rsz_opt
- Flag indicating required handling if the object is
resized:
= 0, Do not resize the pattern area
= 1, Resize pattern - keep aspect ratio
- view_opts
- Object to set non-default options for borders, active strip,
colours and fonts.
This section contains the main methods used with normal operation
of the object.
Methods:
Get display type - selectedDisplayType
Get display option - selectedDisplayMode
Set unique data - setUniqueData
Set unique data - setUniqueData
Clear data - clearData
This method gets the last selected display type (Rotation or Laue).
- Method Definition:
- public int selectedDisplayType()
- Parameters List:
- none
- Method Return:
-
The display type:
= 1, Rotation
= 2, Laue
(May be ROTATION, LAUE)
This method gets the last selected display option.
- Method Definition:
- public int selectedDisplayMode()
- Parameters List:
- none
- Method Return:
-
The display option:
= 1, Standard layers
= 2, Rotating lattice
= 3, Resolution Histograms
This method defines the set of unique reflections data to be displayed.
- Method Definition:
- public void setUniqueData (JdlUniqueReflectionsList refunq, JdlDiffractionDataModule ddm, int iset, int disp_mode)
- Parameters List:
- refunq
- The unique reflections list for which the data are to be
displayed (a JdlUniqueReflectionsList object). Note that the symmetry
used to generate this list must be set in that object.
- ddm
- Diffraction data module (DDM) containing the cell and wavelength
parameters.
- iset
- Reference set number in DDM dataset for cell and wavelength
for reciprocal lattice display.
- disp_mode
- Display mode:
= 1, Standard layers
= 2, Rotating lattice
= 3, Resolution Histograms
This method defines the set of unique reflections data to be displayed.
- Method Definition:
- public void setUniqueData (JdlUniqueReflectionsList refunq, JdlCell cell, double wavelength, int disp_mode)
- Parameters List:
- refunq
- The unique reflections list for which the data are to be
displayed (a JdlUniqueReflectionsList object). Note that the symmetry
used to generate this list must be set in that object.
- cell
- The unit cell parameters.
- wavelength
- The wavelength.
- disp_mode
- Display mode:
= 1, Standard layers
= 2, Rotating lattice
= 3, Resolution Histograms
Clear current reflections data from the object.
- Method Definition:
- public void clearData()
- Parameters List:
- none
This section has methods to set/get the resources associated with the
object determining its appearance and mode of action.
This section contains the standard methods for positioning and sizing
JdlView objects and getting the current minimum height and width values.
Methods:
Set position constraints - setLocationConstraints
Set size constraints - setSizeConstraints
Set minimum height - setMinimumHeight
Set minimum width - setMinimumWidth
Set constraints on the Jdl object positioning.
- Method Definition:
- public void setLocationConstraints (int constraint_x, int constraint_y)
- Parameters List:
- constraint_x
- Constrain the Jdl Object 'x' position = the required
Jdl Object 'x' position (overrides setLocation method) or FREE if the 'x'
position may be set by the setLocation method and hence possibly by the
layout manager.
- constraint_y
- Constrain the Jdl Object 'y' position = the required
the Jdl Object 'y'position (overrides setLocation method) or FREE if the 'y'
position may be set by the setLocation method and hence possibly by the
layout manager.
Set constraints on the Jdl Object resizing permitted.
- Method Definition:
- public void setSizeConstraints (int constraint_w, int constraint_h)
- Parameters List:
- constraint_w
- Constrain the Jdl Object width = the required
Jdl Object width, or PREFERRED (default) if the width is to be calculated
from the current resources, or FREE if the width may be resized to anything
greater than the minimum width required.
- constraint_h
- Constrain the Jdl Object height = the required
Jdl Object height, or PREFERRED (default) if the height is to be calculated
from the current resources, or FREE if the height may be resized to anything
greater than the minimum height required.
Set the minimum height resource.
- Method Definition:
- public void setMinimumHeight(int minh)
- Parameters List:
- minh
- The minimum height required for the object (ignored if less
than that required by the minimum layout) (default = 0).
Set the minimum width resource.
- Method Definition:
- public void setMinimumWidth(int minw)
- Parameters List:
- minh
- The minimum width required for the object (ignored if less
than that required by the minimum layout) (default = 0).
This section contains methods which override the corresponding superclass
methods. These are basically standard for JdlView objects and comprise
methods to set background and foreground colours and to get the minimum
and preferred sizes for the object. (The paintComponent method is also
over-ridden but is not normally called by the user).
Methods:
Set background - setBackground
Set background colours - setBackground
Set foreground - setForeground
Get minimum size - getMinimumSize
Get preferred size - getPreferredSize
This method sets the background colour resource.
- Method Definition:
- public void setBackground (Color c)
- Parameters List:
- c
- The color to become this object's background color.
This method sets the background colour resource and brighter and darker shades
of that colour (e.g. for 3-D frames).
- Method Definition:
- public void setBackground (Color c, Color brighter, Color darker)
- Parameters List:
- c
- The background colour.
- brighter
- A brighter shade of the background colour.
- darker
- A darker shade of the background colour.
This method sets the foreground colour resource.
- Method Definition:
- public void setForeground (Color c)
- Parameters List:
- c
- The color to become this object's foreground color.
This method returns the minimum size of the component.
- Method Definition:
- public Dimension getMinimumSize()
- Parameters List:
- none
This method returns the preferred size of the component.
- Method Definition:
- public Dimension getPreferredSize()
- Parameters List:
- none
⇑ Up 3
⇑ Up 2
⇑ Up 1
⇑ Top of this