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
FieldsModifier and TypeFieldDescriptionstatic final intMain molecule is a field in at least one record.static final intMain molecule is not a field in at least one record.static final intNot yet decided whether the main molecule is a field or not.static final intAutomatic view selection.static final intMolecule matrix view.static final intRecord oriented view. -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds an action listener.intGets the default column width.intgetColumnWidth(int i) Gets the default width of a specified column.Gets a parameter string containing column widths.intGets the field font size.booleanAre SDfile fields shown in table?intGets the IUPAC name font size.intTests whether the main molecule is a field.intGet maximum value of columns in the table.intGet maximum value of rows in the tableintGet the maximum number of molecules displayed in the table.intGets the molecule name font size.intGets the row height.intGets 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.intGets the SMILES font size.intGet the index number of the molecule that is the first to be displayed.intGets the view handler type.voidInitialize field information before update.booleanAre IUPAC names shown in the table?booleanAre molecule names shown in the table?booleanTests whether label should be shown for a single cell.booleanAre SMILES strings shown in the table?booleanReturns whether startAt and maxSize can be changed.voidRemoves an action listener.voidsetColumnWidth(int w) Sets the default column width.voidsetColumnWidth(int i, int w) Sets the default width of a specified column.voidsetFieldFontSize(int v) Sets the field font size.voidsetFieldsShown(boolean v) Show or hide SDfile fields in the tablevoidsetGenNameFontSize(int v) Sets the IUPAC name font size.voidsetGenNameShown(boolean v) Set visibility of IUPAC names.voidsetListFont(Font f) voidsetMaxCols(int v) Set maximum value of columns in the tablevoidsetMaxRows(int v) Set maximum value of rows in the tablevoidsetMaxSize(int n) Set the maximum number of molecules displayed in the table.voidsetMolNameFontSize(int v) Sets the molecule name font size.voidsetMolNameShown(boolean v) Sets visibility of molecule names.voidsetRowHeight(int h) Sets the row height.voidsetSelectedFields(String[] fields) Set selected fields array in Table Options dialog boxvoidsetSingleCellLabelShown(boolean v) Tests whether label should be shown for a single cell.voidsetSMILESFontSize(int v) Sets the SMILES font size.voidsetSMILESShown(boolean v) Set visibility of SMILES strings.voidsetStartAt(int s) Set the index number of the molecule that is the first to be displayed.voidsetSubsetChangable(boolean b) Sets whether startAt and maxSize can be changed.voidsetViewHandlerType(int t) Sets the view handler type.voidBring up Table Options dialog boxvoidupdateFields(MDocument doc) Update fields of SDF tablevoidupdateFields(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:
trueif molecule names are visible.- Since:
- Marvin 5.0, 11/16/2007
-
setMolNameShown
public void setMolNameShown(boolean v) Sets visibility of molecule names.- Parameters:
v-trueto 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:
trueif IUPAC names should be visible,falseotherwise
-
setGenNameShown
public void setGenNameShown(boolean v) Set visibility of IUPAC names.- Parameters:
v-trueto show IUPAC names,falseto 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:
trueif SMILES strings should be visible,falseotherwise
-
setSMILESShown
public void setSMILESShown(boolean v) Set visibility of SMILES strings.- Parameters:
v-trueto show SMILES strings,falseto 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:
trueif label is always shown,falseif 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-trueto show label always,falseto 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_FIELDorMMF_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
-