Package chemaxon.marvin.view.swing
Class TableOptions
java.lang.Object
chemaxon.marvin.view.swing.TableOptions
SDF table options for MarvinView.
- Since:
- Marvin 2.8.3
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
Main molecule is a field in at least one record.static final int
Main molecule is not a field in at least one record.static final int
Not yet decided whether the main molecule is a field or not.static final int
Automatic view selection.static final int
Molecule matrix view.static final int
Record oriented view. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds an action listener.int
Gets the default column width.int
getColumnWidth
(int i) Gets the default width of a specified column.Gets a parameter string containing column widths.int
Gets the field font size.boolean
Are SDfile fields shown in table?int
Gets the IUPAC name font size.int
Tests whether the main molecule is a field.int
Get maximum value of columns in the table.int
Get maximum value of rows in the tableint
Get the maximum number of molecules displayed in the table.int
Gets the molecule name font size.int
Gets the row height.int
Gets the number of selected fields.String[]
Get selected fields array which are selected in Table Options dialog boxchemaxon.marvin.view.CellType[]
Get type array of selected field types.int
Gets the SMILES font size.int
Get the index number of the molecule that is the first to be displayed.int
Gets the view handler type.void
Initialize field information before update.boolean
Are IUPAC names shown in the table?boolean
Are molecule names shown in the table?boolean
Tests whether label should be shown for a single cell.boolean
Are SMILES strings shown in the table?boolean
Returns whether startAt and maxSize can be changed.void
Removes an action listener.void
setColumnWidth
(int w) Sets the default column width.void
setColumnWidth
(int i, int w) Sets the default width of a specified column.void
setFieldFontSize
(int v) Sets the field font size.void
setFieldsShown
(boolean v) Show or hide SDfile fields in the tablevoid
setGenNameFontSize
(int v) Sets the IUPAC name font size.void
setGenNameShown
(boolean v) Set visibility of IUPAC names.void
setListFont
(Font f) void
setMaxCols
(int v) Set maximum value of columns in the tablevoid
setMaxRows
(int v) Set maximum value of rows in the tablevoid
setMaxSize
(int n) Set the maximum number of molecules displayed in the table.void
setMolNameFontSize
(int v) Sets the molecule name font size.void
setMolNameShown
(boolean v) Sets visibility of molecule names.void
setRowHeight
(int h) Sets the row height.void
setSelectedFields
(String[] fields) Set selected fields array in Table Options dialog boxvoid
setSingleCellLabelShown
(boolean v) Tests whether label should be shown for a single cell.void
setSMILESFontSize
(int v) Sets the SMILES font size.void
setSMILESShown
(boolean v) Set visibility of SMILES strings.void
setStartAt
(int s) Set the index number of the molecule that is the first to be displayed.void
setSubsetChangable
(boolean b) Sets whether startAt and maxSize can be changed.void
setViewHandlerType
(int t) Sets the view handler type.void
Bring up Table Options dialog boxvoid
updateFields
(MDocument doc) Update fields of SDF tablevoid
updateFields
(MDocument[] docarr) Update fields of SDF table
-
Field Details
-
VH_AUTO
public static final int VH_AUTOAutomatic view selection.- Since:
- Marvin 5.0, 11/07/2007
- See Also:
-
VH_GRIDBAG
public static final int VH_GRIDBAGMolecule matrix view.- Since:
- Marvin 5.0, 10/29/2007
- See Also:
-
VH_SPREADSHEET
public static final int VH_SPREADSHEETRecord oriented view.- Since:
- Marvin 5.0, 10/29/2007
- See Also:
-
MMF_UNSET
public static final int MMF_UNSETNot yet decided whether the main molecule is a field or not.- Since:
- Marvin 5.0, 12/19/2007
- See Also:
-
MMF_FIELD
public static final int MMF_FIELDMain molecule is a field in at least one record.- Since:
- Marvin 5.0, 12/19/2007
- See Also:
-
MMF_NOT_FIELD
public static final int MMF_NOT_FIELDMain molecule is not a field in at least one record.- Since:
- Marvin 5.0, 12/19/2007
- See Also:
-
-
Method Details
-
setListFont
-
initFields
public void initFields()Initialize field information before update.- Since:
- Marvin 4.1, 04/17/2006
-
updateFields
Update fields of SDF table- Parameters:
doc
- document- Since:
- Marvin 4.1, 04/17/2006
-
updateFields
Update fields of SDF table- Parameters:
docarr
- array of molecules in the table
-
isSubsetChangable
public boolean isSubsetChangable()Returns whether startAt and maxSize can be changed.- Returns:
- index
-
setSubsetChangable
public void setSubsetChangable(boolean b) Sets whether startAt and maxSize can be changed.- Parameters:
b
- index
-
getStartAt
public int getStartAt()Get the index number of the molecule that is the first to be displayed.- Returns:
- index
-
setStartAt
public void setStartAt(int s) Set the index number of the molecule that is the first to be displayed.- Parameters:
s
- index
-
getMaxSize
public int getMaxSize()Get the maximum number of molecules displayed in the table.- Returns:
- maximum number of molecules
-
setMaxSize
public void setMaxSize(int n) Set the maximum number of molecules displayed in the table.- Parameters:
n
- maximum number of molecules
-
getViewHandlerType
public int getViewHandlerType()Gets the view handler type.- Returns:
- the view handler type
- Since:
- Marvin 5.0, 10/29/2007
- See Also:
-
setViewHandlerType
public void setViewHandlerType(int t) Sets the view handler type.- Parameters:
t
- the view handler type- Since:
- Marvin 5.0, 10/29/2007
- See Also:
-
setRowHeight
public void setRowHeight(int h) Sets the row height.- Parameters:
h
- the row height- Since:
- Marvin 5.2.4, 07/30/2009
-
getRowHeight
public int getRowHeight()Gets the row height.- Returns:
- the row height
- Since:
- Marvin 5.0, 10/30/2007
-
setColumnWidth
public void setColumnWidth(int w) Sets the default column width. It sets the default width of each column for whichsetColumnWidth(int, int)
is not called, except for column 0.- Parameters:
w
- the column width- Since:
- Marvin 5.2.4, 07/30/2009
-
getColumnWidth
public int getColumnWidth()Gets the default column width.- Returns:
- the column width
- Since:
- Marvin 5.0, 10/30/2007
-
setColumnWidth
public void setColumnWidth(int i, int w) Sets the default width of a specified column.- Parameters:
i
- the column indexw
- width- Since:
- Marvin 5.2.5, 08/29/2009
-
getColumnWidth
public int getColumnWidth(int i) Gets the default width of a specified column.- Parameters:
i
- the column index- Returns:
- the width
- Since:
- Marvin 5.2.5, 08/29/2009
-
getColumnWidthsString
Gets a parameter string containing column widths.- Returns:
- the string
- Since:
- Marvin 5.2.5, 08/29/2009
-
getMaxCols
public int getMaxCols()Get maximum value of columns in the table.- Returns:
- maximum value of columns
-
setMaxCols
public void setMaxCols(int v) Set maximum value of columns in the table- Parameters:
v
- maximum value of columns
-
getMaxRows
public int getMaxRows()Get maximum value of rows in the table- Returns:
- maximum value of rows
-
setMaxRows
public void setMaxRows(int v) Set maximum value of rows in the table- Parameters:
v
- maximum value of rows
-
isMolNameShown
public boolean isMolNameShown()Are molecule names shown in the table?- Returns:
true
if molecule names are visible.- Since:
- Marvin 5.0, 11/16/2007
-
setMolNameShown
public void setMolNameShown(boolean v) Sets visibility of molecule names.- Parameters:
v
-true
to make molecule names visible- Since:
- Marvin 5.0, 11/16/2007
-
getMolNameFontSize
public int getMolNameFontSize()Gets the molecule name font size.- Returns:
- the font size
- Since:
- Marvin 5.0, 11/16/2007
-
setMolNameFontSize
public void setMolNameFontSize(int v) Sets the molecule name font size.- Parameters:
v
- the font size- Since:
- Marvin 3.4
-
isGenNameShown
public boolean isGenNameShown()Are IUPAC names shown in the table?- Returns:
true
if IUPAC names should be visible,false
otherwise
-
setGenNameShown
public void setGenNameShown(boolean v) Set visibility of IUPAC names.- Parameters:
v
-true
to show IUPAC names,false
to hide them
-
getGenNameFontSize
public int getGenNameFontSize()Gets the IUPAC name font size.- Returns:
- the font size
- Since:
- Marvin 5.0, 11/18/2007
-
setGenNameFontSize
public void setGenNameFontSize(int v) Sets the IUPAC name font size.- Parameters:
v
- the font size- Since:
- Marvin 5.0, 11/18/2007
-
isSMILESShown
public boolean isSMILESShown()Are SMILES strings shown in the table?- Returns:
true
if SMILES strings should be visible,false
otherwise
-
setSMILESShown
public void setSMILESShown(boolean v) Set visibility of SMILES strings.- Parameters:
v
-true
to show SMILES strings,false
to hide them
-
getSMILESFontSize
public int getSMILESFontSize()Gets the SMILES font size.- Returns:
- the font size
- Since:
- Marvin 3.4
-
setSMILESFontSize
public void setSMILESFontSize(int v) Sets the SMILES font size.- Parameters:
v
- the font size- Since:
- Marvin 3.4
-
isSingleCellLabelShown
public boolean isSingleCellLabelShown()Tests whether label should be shown for a single cell.- Returns:
true
if label is always shown,false
if label is shown only if more than one cell is present- Since:
- Marvin 5.0.1, 02/18/2008
-
setSingleCellLabelShown
public void setSingleCellLabelShown(boolean v) Tests whether label should be shown for a single cell.- Parameters:
v
-true
to show label always,false
to show only if more than one cell is present- Since:
- Marvin 5.0.1, 02/18/2008
-
getFieldsShown
public boolean getFieldsShown()Are SDfile fields shown in table?- Returns:
- true to show SDfile fields, false to hide them
-
setFieldsShown
public void setFieldsShown(boolean v) Show or hide SDfile fields in the table- Parameters:
v
- true to show SDfile fields, false to hide them
-
getFieldFontSize
public int getFieldFontSize()Gets the field font size.- Returns:
- the font size
- Since:
- Marvin 3.4
-
setFieldFontSize
public void setFieldFontSize(int v) Sets the field font size.- Parameters:
v
- the font size- Since:
- Marvin 3.4
-
getSelectedFields
Get selected fields array which are selected in Table Options dialog box- Returns:
- names of selected fields
- See Also:
-
getSelectedFieldCount
public int getSelectedFieldCount()Gets the number of selected fields.- Returns:
- the number of selected fields
- Since:
- Marvin 5.2.1, 04/11/2009
-
getSelectedFieldTypes
public chemaxon.marvin.view.CellType[] getSelectedFieldTypes()Get type array of selected field types.- Returns:
- names of selected fields
- Since:
- Marvin 5.3, 09/13/2009
- See Also:
-
getMainMolFieldness
public int getMainMolFieldness()Tests whether the main molecule is a field.- Returns:
MMF_UNSET
,MMF_FIELD
,MMF_NOT_FIELD
orMMF_FIELD
|MMF_NOT_FIELD
- Since:
- Marvin 5.0, 12/19/2007
-
setSelectedFields
Set selected fields array in Table Options dialog box- Parameters:
fields
- name of selected fields
-
showDialog
public void showDialog()Bring up Table Options dialog box -
addActionListener
Adds an action listener. The action event is fired when the user closes the dialog with the OK button.- Parameters:
l
- the action listener- Since:
- Marvin 5.0, 11/13/2007
-
removeActionListener
Removes an action listener.- Parameters:
l
- the action listener- Since:
- Marvin 5.0, 11/13/2007
-