import java.util.HashSet;
import java.util.List;
import java.util.Map;
+import java.util.Set;
import javax.swing.BorderFactory;
import javax.swing.DefaultListCellRenderer;
Font.PLAIN,
9 );
private static final String RETURN_TO_SUPER_TREE_TEXT = "Back to Super Tree";
+ private static final String SEARCH_TIP_TEXT = "Enter text to search for. Use ',' for logical OR and '+' for logical AND (not used in this manner for regular expression searches).";
private static final long serialVersionUID = -8463483932821545633L;
private NodeClickAction _action_when_node_clicked;
private int _add_new_node_item;
private int _paste_subtree_item;
private int _reroot_cb_item;
private JButton _return_to_super_tree;
- // Search
+ // Search
private JLabel _search_found_label_0;
private JLabel _search_found_label_1;
private JButton _search_reset_button_0;
// Indices for the click-to options in the combo box
private int _show_data_item;
private JCheckBox _show_domain_architectures;
+ private JCheckBox _show_mol_seqs;
+ private JCheckBox _write_branch_length_values;
private JCheckBox _show_events;
private JCheckBox _show_gene_names;
private JCheckBox _show_node_names;
displayedPhylogenyMightHaveChanged( false );
}
else if ( e.getSource() == _show_whole ) {
+ displayedPhylogenyMightHaveChanged( true );
showWhole();
}
else if ( e.getSource() == _return_to_super_tree ) {
showWhole();
}
else if ( e.getSource() == _order ) {
- DESCENDANT_SORT_PRIORITY pri = DESCENDANT_SORT_PRIORITY.TAXONOMY;
- if ( ( !isShowTaxonomyScientificNames() && !isShowTaxonomyCode() && !isShowTaxonomyCommonNames() ) ) {
- if ( ( isShowSequenceAcc() || isShowSeqNames() || isShowSeqSymbols() ) ) {
- pri = DESCENDANT_SORT_PRIORITY.SEQUENCE;
- }
- else if ( isShowNodeNames() ) {
- pri = DESCENDANT_SORT_PRIORITY.NODE_NAME;
- }
+ DESCENDANT_SORT_PRIORITY pri = DESCENDANT_SORT_PRIORITY.NODE_NAME;
+ if ( isShowTaxonomyScientificNames() || isShowTaxonomyCode() ) {
+ pri = DESCENDANT_SORT_PRIORITY.TAXONOMY;
+ }
+ else if ( isShowSeqNames() || isShowSeqSymbols() || isShowGeneNames() ) {
+ pri = DESCENDANT_SORT_PRIORITY.SEQUENCE;
}
PhylogenyMethods.orderAppearance( tp.getPhylogeny().getRoot(), _order_of_appearance, true, pri );
_order_of_appearance = !_order_of_appearance;
tp.getPhylogeny().recalculateNumberOfExternalDescendants( true );
tp.resetNodeIdToDistToLeafMap();
tp.setEdited( true );
- displayedPhylogenyMightHaveChanged( false );
+ displayedPhylogenyMightHaveChanged( true );
}
else if ( e.getSource() == _uncollapse_all ) {
uncollapseAll( tp );
displayedPhylogenyMightHaveChanged( true );
}
else if ( e.getSource() == _decr_domain_structure_evalue_thr ) {
- _mainpanel.getCurrentTreePanel().decreaseDomainStructureEvalueThreshold();
+ _mainpanel.getCurrentTreePanel().decreaseDomainStructureEvalueThresholdExp();
+ search0();
+ search1();
displayedPhylogenyMightHaveChanged( true );
}
else if ( e.getSource() == _incr_domain_structure_evalue_thr ) {
- _mainpanel.getCurrentTreePanel().increaseDomainStructureEvalueThreshold();
+ _mainpanel.getCurrentTreePanel().increaseDomainStructureEvalueThresholdExp();
+ search0();
+ search1();
displayedPhylogenyMightHaveChanged( true );
}
else if ( e.getSource() == _search_tf_0 ) {
addJCheckBox( _width_branches, ch_panel );
add( ch_panel );
break;
+ case Configuration.write_branch_length_values:
+ _write_branch_length_values = new JCheckBox( title );
+ addJCheckBox( _write_branch_length_values, ch_panel );
+ add( ch_panel );
+ break;
case Configuration.show_domain_architectures:
_show_domain_architectures = new JCheckBox( title );
addJCheckBox( _show_domain_architectures, ch_panel );
add( ch_panel );
break;
+ case Configuration.show_mol_seqs:
+ _show_mol_seqs = new JCheckBox( title );
+ addJCheckBox( _show_mol_seqs, ch_panel );
+ add( ch_panel );
+ break;
case Configuration.show_seq_names:
_show_seq_names = new JCheckBox( title );
addJCheckBox( _show_seq_names, ch_panel );
/**
* Indicates what action should be execute when a node is clicked
- *
+ *
* @return the click-on action
*/
NodeClickAction getActionWhenNodeClicked() {
return ( ( getWriteConfidenceCb() != null ) && getWriteConfidenceCb().isSelected() );
}
+ boolean isWriteBranchLengthValues() {
+ return ( ( _write_branch_length_values != null ) && _write_branch_length_values.isSelected() );
+ }
+
boolean isShowDomainArchitectures() {
return ( ( _show_domain_architectures != null ) && _show_domain_architectures.isSelected() );
}
+ public boolean isShowMolSequences() {
+ return ( ( _show_mol_seqs != null ) && _show_mol_seqs.isSelected() );
+ }
+
boolean isShowGeneNames() {
return ( ( _show_gene_names != null ) && _show_gene_names.isSelected() );
}
_show_domain_architectures.setSelected( state );
}
break;
+ case Configuration.write_branch_length_values:
+ if ( _write_branch_length_values != null ) {
+ _write_branch_length_values.setSelected( state );
+ }
+ break;
+ case Configuration.show_mol_seqs:
+ if ( _show_mol_seqs != null ) {
+ _show_mol_seqs.setSelected( state );
+ }
+ break;
case Configuration.show_seq_names:
if ( _show_seq_names != null ) {
_show_seq_names.setSelected( state );
_sequence_colors = sequence_colors;
}
- /* GUILHEM_END */
- /*
- * Set up the controls from the config settings. 11/26/05
- */
void setupControls() {
// The tree display options:
setupDisplayCheckboxes();
}
void setupSearchTools0() {
- final String tip = "Enter text to search for. Use ',' for multiple searches (logical OR) and '+' for logical AND.";
final JLabel search_label = new JLabel( "Search (A):" );
search_label.setFont( ControlPanel.jcb_bold_font );
if ( !getConfiguration().isUseNativeUI() ) {
search_label.setForeground( getConfiguration().getGuiCheckboxTextColor() );
}
add( search_label );
- search_label.setToolTipText( tip );
+ search_label.setToolTipText( SEARCH_TIP_TEXT );
_search_found_label_0 = new JLabel();
getSearchFoundCountsLabel0().setVisible( false );
_search_found_label_0.setFont( ControlPanel.jcb_bold_font );
_search_found_label_0.setForeground( getConfiguration().getGuiCheckboxTextColor() );
}
_search_tf_0 = new JTextField( 3 );
- _search_tf_0.setToolTipText( tip );
+ _search_tf_0.setToolTipText( SEARCH_TIP_TEXT );
_search_tf_0.setEditable( true );
if ( !getConfiguration().isUseNativeUI() ) {
_search_tf_0.setForeground( getConfiguration().getGuiMenuBackgroundColor() );
}
void setupSearchTools1() {
- final String tip = "Enter text to search for. Use ',' for multiple searches (logical OR) and '+' for logical AND.";
final JLabel search_label = new JLabel( "Search (B):" );
search_label.setFont( ControlPanel.jcb_bold_font );
if ( !getConfiguration().isUseNativeUI() ) {
search_label.setForeground( getConfiguration().getGuiCheckboxTextColor() );
}
add( search_label );
- search_label.setToolTipText( tip );
+ search_label.setToolTipText( SEARCH_TIP_TEXT );
_search_found_label_1 = new JLabel();
getSearchFoundCountsLabel1().setVisible( false );
_search_found_label_1.setFont( ControlPanel.jcb_bold_font );
_search_found_label_1.setForeground( getConfiguration().getGuiCheckboxTextColor() );
}
_search_tf_1 = new JTextField( 3 );
- _search_tf_1.setToolTipText( tip );
+ _search_tf_1.setToolTipText( SEARCH_TIP_TEXT );
_search_tf_1.setEditable( true );
if ( !getConfiguration().isUseNativeUI() ) {
_search_tf_1.setForeground( getConfiguration().getGuiMenuBackgroundColor() );
_mainpanel.getCurrentTreePanel().validate();
_mainpanel.validate();
_mainpanel.getCurrentTreePanel().calcParametersForPainting( _mainpanel.getSizeOfViewport().width,
- _mainpanel.getSizeOfViewport().height,
- true );
+ _mainpanel.getSizeOfViewport().height );
_mainpanel.getCurrentTreePanel().resetPreferredSize();
_mainpanel.adjustJScrollPane();
_mainpanel.getCurrentTreePanel().repaint();
_mainpanel.getCurrentTreePanel().validate();
_mainpanel.validate();
_mainpanel.getCurrentTreePanel().calcParametersForPainting( _mainpanel.getSizeOfViewport().width,
- _mainpanel.getSizeOfViewport().height,
- true );
+ _mainpanel.getSizeOfViewport().height );
_mainpanel.getCurrentTreePanel().resetPreferredSize();
_mainpanel.adjustJScrollPane();
_mainpanel.getCurrentTreePanel().repaint();
if ( tree_panel != null ) {
tree_panel.validate();
tree_panel.calcParametersForPainting( _mainpanel.getSizeOfViewport().width,
- _mainpanel.getSizeOfViewport().height,
- true );
+ _mainpanel.getSizeOfViewport().height );
tree_panel.resetPreferredSize();
tree_panel.repaint();
}
void updateDomainStructureEvaluethresholdDisplay() {
if ( _domain_structure_evalue_thr_tf != null ) {
_domain_structure_evalue_thr_tf.setText( "10^"
- + getMainPanel().getCurrentTreePanel().getDomainStructureEvalueThreshold() );
+ + getMainPanel().getCurrentTreePanel().getDomainStructureEvalueThresholdExp() );
}
}
getSearchResetButton0().setEnabled( true );
getSearchResetButton0().setVisible( true );
String[] queries = null;
- List<PhylogenyNode> nodes = null;
- if ( query_str.indexOf( ',' ) >= 0 ) {
+ Set<PhylogenyNode> nodes = null;
+ if ( ( query_str.indexOf( ',' ) >= 0 ) && !getOptions().isSearchWithRegex() ) {
queries = query_str.split( ",+" );
}
else {
queries[ 0 ] = query_str.trim();
}
if ( ( queries != null ) && ( queries.length > 0 ) ) {
- nodes = new ArrayList<PhylogenyNode>();
+ nodes = new HashSet<PhylogenyNode>();
for( String query : queries ) {
if ( ForesterUtil.isEmpty( query ) ) {
continue;
}
query = query.trim();
- if ( query.indexOf( '+' ) >= 0 ) {
+ final TreePanel tp = getMainPanel().getCurrentTreePanel();
+ if ( ( query.indexOf( '+' ) > 0 ) && !getOptions().isSearchWithRegex() ) {
nodes.addAll( PhylogenyMethods.searchDataLogicalAnd( query.split( "\\++" ),
tree,
getOptions().isSearchCaseSensitive(),
!getOptions().isMatchWholeTermsOnly(),
- isShowDomainArchitectures() ) );
+ isShowDomainArchitectures(),
+ tp != null ? Math.pow( 10,
+ tp.getDomainStructureEvalueThresholdExp() )
+ : 0 ) );
}
else {
nodes.addAll( PhylogenyMethods.searchData( query,
tree,
getOptions().isSearchCaseSensitive(),
!getOptions().isMatchWholeTermsOnly(),
- isShowDomainArchitectures() ) );
+ getOptions().isSearchWithRegex(),
+ isShowDomainArchitectures(),
+ tp != null ? Math.pow( 10, tp
+ .getDomainStructureEvalueThresholdExp() ) : 0 ) );
}
}
if ( getOptions().isInverseSearchResult() ) {
final List<PhylogenyNode> all = PhylogenyMethods.obtainAllNodesAsList( tree );
all.removeAll( nodes );
- nodes = all;
+ nodes = new HashSet<PhylogenyNode>();
+ nodes.addAll( all );
}
}
if ( ( nodes != null ) && ( nodes.size() > 0 ) ) {
getSearchResetButton1().setEnabled( true );
getSearchResetButton1().setVisible( true );
String[] queries = null;
- List<PhylogenyNode> nodes = null;
- if ( query_str.indexOf( ',' ) >= 0 ) {
+ Set<PhylogenyNode> nodes = null;
+ if ( ( query_str.indexOf( ',' ) >= 0 ) && !getOptions().isSearchWithRegex() ) {
queries = query_str.split( ",+" );
}
else {
queries[ 0 ] = query_str.trim();
}
if ( ( queries != null ) && ( queries.length > 0 ) ) {
- nodes = new ArrayList<PhylogenyNode>();
+ nodes = new HashSet<PhylogenyNode>();
for( String query : queries ) {
if ( ForesterUtil.isEmpty( query ) ) {
continue;
}
query = query.trim();
- if ( query.indexOf( '+' ) >= 0 ) {
+ final TreePanel tp = getMainPanel().getCurrentTreePanel();
+ if ( ( query.indexOf( '+' ) > 0 ) && !getOptions().isSearchWithRegex() ) {
nodes.addAll( PhylogenyMethods.searchDataLogicalAnd( query.split( "\\++" ),
tree,
getOptions().isSearchCaseSensitive(),
!getOptions().isMatchWholeTermsOnly(),
- isShowDomainArchitectures() ) );
+ isShowDomainArchitectures(),
+ tp != null ? Math.pow( 10,
+ tp.getDomainStructureEvalueThresholdExp() )
+ : 0 ) );
}
else {
nodes.addAll( PhylogenyMethods.searchData( query,
tree,
getOptions().isSearchCaseSensitive(),
!getOptions().isMatchWholeTermsOnly(),
- isShowDomainArchitectures() ) );
+ getOptions().isSearchWithRegex(),
+ isShowDomainArchitectures(),
+ tp != null ? Math.pow( 10, tp
+ .getDomainStructureEvalueThresholdExp() ) : 0 ) );
}
}
if ( getOptions().isInverseSearchResult() ) {
final List<PhylogenyNode> all = PhylogenyMethods.obtainAllNodesAsList( tree );
all.removeAll( nodes );
- nodes = all;
+ nodes = new HashSet<PhylogenyNode>();
+ nodes.addAll( all );
}
}
if ( ( nodes != null ) && ( nodes.size() > 0 ) ) {
_get_ext_desc_data = cb_index;
if ( !ForesterUtil.isEmpty( getConfiguration().getLabelForGetExtDescendentsData() ) ) {
addClickToOption( Configuration.get_ext_desc_data, getConfiguration()
- .getLabelForGetExtDescendentsData() );
+ .getLabelForGetExtDescendentsData() );
}
else {
- String s = ";";
- switch ( getConfiguration().getExtDescNodeDataToReturn() ) {
- case NODE_NAME:
- s = "Node Names";
- break;
- case SEQUENCE_ACC:
- s = "Sequence Accessors";
- break;
- case SEQUENCE_MOL_SEQ:
- s = "Molecular Sequence";
- break;
- case SEQUENCE_MOL_SEQ_FASTA:
- s = "Molecular Sequence (Fasta)";
- break;
- case SEQUENCE_NAME:
- s = "Sequence Names";
- break;
- case GENE_NAME:
- s = "Gene Names";
- break;
- case SEQUENCE_SYMBOL:
- s = "Sequence Symbols";
- break;
- case TAXONOMY_CODE:
- s = "Taxonomy Codes";
- break;
- case TAXONOMY_COMM0N_NAME:
- s = "Taxonomy Common Names";
- break;
- case TAXONOMY_SCIENTIFIC_NAME:
- s = "Scientific Names";
- break;
- case UNKNOWN:
- s = "User Selected Data";
- break;
- default:
- throw new IllegalStateException( "dont know how to deal with "
- + getConfiguration().getExtDescNodeDataToReturn() );
- }
- final String label = _configuration.getClickToTitle( Configuration.get_ext_desc_data ) + " " + s;
- addClickToOption( Configuration.get_ext_desc_data, label );
+ addClickToOption( Configuration.get_ext_desc_data,
+ getConfiguration().getClickToTitle( Configuration.get_ext_desc_data ) );
}
if ( default_option == Configuration.get_ext_desc_data ) {
selected_index = cb_index;
addCheckbox( Configuration.show_annotation, _configuration.getDisplayTitle( Configuration.show_annotation ) );
setCheckbox( Configuration.show_annotation, _configuration.doCheckOption( Configuration.show_annotation ) );
}
+ if ( _configuration.doDisplayOption( Configuration.write_confidence_values ) ) {
+ addCheckbox( Configuration.write_confidence_values,
+ _configuration.getDisplayTitle( Configuration.write_confidence_values ) );
+ setCheckbox( Configuration.write_confidence_values,
+ _configuration.doCheckOption( Configuration.write_confidence_values ) );
+ }
+ if ( _configuration.doDisplayOption( Configuration.write_branch_length_values ) ) {
+ addCheckbox( Configuration.write_branch_length_values,
+ _configuration.getDisplayTitle( Configuration.write_branch_length_values ) );
+ setCheckbox( Configuration.write_branch_length_values,
+ _configuration.doCheckOption( Configuration.write_branch_length_values ) );
+ }
if ( _configuration.doDisplayOption( Configuration.show_binary_characters ) ) {
addCheckbox( Configuration.show_binary_characters,
_configuration.getDisplayTitle( Configuration.show_binary_characters ) );
setCheckbox( Configuration.show_domain_architectures,
_configuration.doCheckOption( Configuration.show_domain_architectures ) );
}
- if ( _configuration.doDisplayOption( Configuration.write_confidence_values ) ) {
- addCheckbox( Configuration.write_confidence_values,
- _configuration.getDisplayTitle( Configuration.write_confidence_values ) );
- setCheckbox( Configuration.write_confidence_values,
- _configuration.doCheckOption( Configuration.write_confidence_values ) );
+ if ( _configuration.doDisplayOption( Configuration.show_mol_seqs ) ) {
+ addCheckbox( Configuration.show_mol_seqs, _configuration.getDisplayTitle( Configuration.show_mol_seqs ) );
+ setCheckbox( Configuration.show_mol_seqs, _configuration.doCheckOption( Configuration.show_mol_seqs ) );
}
if ( _configuration.doDisplayOption( Configuration.write_events ) ) {
addCheckbox( Configuration.write_events, _configuration.getDisplayTitle( Configuration.write_events ) );
private void setVisibilityOfDomainStrucureControls() {
if ( _zoom_in_domain_structure != null ) {
- if ( isShowDomainArchitectures() ) {
- _domain_display_label.setVisible( true );
- _zoom_in_domain_structure.setVisible( true );
- _zoom_out_domain_structure.setVisible( true );
- _decr_domain_structure_evalue_thr.setVisible( true );
- _incr_domain_structure_evalue_thr.setVisible( true );
- _domain_structure_evalue_thr_tf.setVisible( true );
- if ( getMainPanel().getMainFrame()._right_line_up_domains_cbmi != null ) {
- getMainPanel().getMainFrame()._right_line_up_domains_cbmi.setVisible( true );
+ final MainFrame mf = getMainFrame();
+ if ( mf != null ) {
+ if ( isShowDomainArchitectures() ) {
+ _domain_display_label.setVisible( true );
+ _zoom_in_domain_structure.setVisible( true );
+ _zoom_out_domain_structure.setVisible( true );
+ _decr_domain_structure_evalue_thr.setVisible( true );
+ _incr_domain_structure_evalue_thr.setVisible( true );
+ _domain_structure_evalue_thr_tf.setVisible( true );
+ if ( mf._right_line_up_domains_cbmi != null ) {
+ mf._right_line_up_domains_cbmi.setVisible( true );
+ }
+ if ( mf._show_domain_labels != null ) {
+ mf._show_domain_labels.setVisible( true );
+ }
}
- if ( getMainPanel().getMainFrame()._show_domain_labels != null ) {
- getMainPanel().getMainFrame()._show_domain_labels.setVisible( true );
+ else {
+ _domain_display_label.setVisible( false );
+ _zoom_in_domain_structure.setVisible( false );
+ _zoom_out_domain_structure.setVisible( false );
+ _decr_domain_structure_evalue_thr.setVisible( false );
+ _incr_domain_structure_evalue_thr.setVisible( false );
+ _domain_structure_evalue_thr_tf.setVisible( false );
+ if ( mf._right_line_up_domains_cbmi != null ) {
+ mf._right_line_up_domains_cbmi.setVisible( false );
+ }
+ if ( mf._show_domain_labels != null ) {
+ mf._show_domain_labels.setVisible( false );
+ }
}
}
- else {
- _domain_display_label.setVisible( false );
- _zoom_in_domain_structure.setVisible( false );
- _zoom_out_domain_structure.setVisible( false );
- _decr_domain_structure_evalue_thr.setVisible( false );
- _incr_domain_structure_evalue_thr.setVisible( false );
- _domain_structure_evalue_thr_tf.setVisible( false );
- if ( getMainPanel().getMainFrame()._right_line_up_domains_cbmi != null ) {
- getMainPanel().getMainFrame()._right_line_up_domains_cbmi.setVisible( false );
- }
- if ( getMainPanel().getMainFrame()._show_domain_labels != null ) {
- getMainPanel().getMainFrame()._show_domain_labels.setVisible( false );
- }
+ }
+ }
+
+ // This takes care of ArchaeopteryxE-issue.
+ // Can, and will, return null prior to ArchaeopteryxE initialization completion.
+ final private MainFrame getMainFrame() {
+ MainFrame mf = getMainPanel().getMainFrame();
+ if ( mf == null ) {
+ // Must be "E" applet version.
+ final ArchaeopteryxE e = ( ArchaeopteryxE ) ( ( MainPanelApplets ) getMainPanel() ).getApplet();
+ if ( e.getMainPanel() == null ) {
+ return null;
}
+ mf = e.getMainPanel().getMainFrame();
}
+ return mf;
}
void setVisibilityOfX() {
- try {
+ final MainFrame mf = getMainFrame();
+ if ( mf != null ) {
if ( ( getCurrentTreePanel() != null ) && ( getCurrentTreePanel().getPhylogeny() != null ) ) {
if ( AptxUtil.isHasAtLeastOneBranchWithSupportSD( getCurrentTreePanel().getPhylogeny() ) ) {
- if ( getMainPanel().getMainFrame()._show_confidence_stddev_cbmi != null ) {
- getMainPanel().getMainFrame()._show_confidence_stddev_cbmi.setVisible( true );
+ if ( mf._show_confidence_stddev_cbmi != null ) {
+ mf._show_confidence_stddev_cbmi.setVisible( true );
}
}
else {
- if ( getMainPanel().getMainFrame()._show_confidence_stddev_cbmi != null ) {
- getMainPanel().getMainFrame()._show_confidence_stddev_cbmi.setVisible( false );
+ if ( mf._show_confidence_stddev_cbmi != null ) {
+ mf._show_confidence_stddev_cbmi.setVisible( false );
}
}
if ( AptxUtil.isHasAtLeastOneNodeWithScientificName( getCurrentTreePanel().getPhylogeny() ) ) {
- if ( getMainPanel().getMainFrame()._abbreviate_scientific_names != null ) {
- getMainPanel().getMainFrame()._abbreviate_scientific_names.setVisible( true );
+ if ( mf._abbreviate_scientific_names != null ) {
+ mf._abbreviate_scientific_names.setVisible( true );
}
}
else {
- if ( getMainPanel().getMainFrame()._abbreviate_scientific_names != null ) {
- getMainPanel().getMainFrame()._abbreviate_scientific_names.setVisible( false );
+ if ( mf._abbreviate_scientific_names != null ) {
+ mf._abbreviate_scientific_names.setVisible( false );
}
}
if ( AptxUtil.isHasAtLeastOneNodeWithSequenceAnnotation( getCurrentTreePanel().getPhylogeny() ) ) {
- if ( getMainPanel().getMainFrame()._show_annotation_ref_source != null ) {
- getMainPanel().getMainFrame()._show_annotation_ref_source.setVisible( true );
+ if ( mf._show_annotation_ref_source != null ) {
+ mf._show_annotation_ref_source.setVisible( true );
}
}
else {
- if ( getMainPanel().getMainFrame()._show_annotation_ref_source != null ) {
- getMainPanel().getMainFrame()._show_annotation_ref_source.setVisible( false );
+ if ( mf._show_annotation_ref_source != null ) {
+ mf._show_annotation_ref_source.setVisible( false );
}
}
}
if ( isDrawPhylogram()
|| ( ( getCurrentTreePanel() != null ) && ( ( getCurrentTreePanel().getPhylogenyGraphicsType() == PHYLOGENY_GRAPHICS_TYPE.CIRCULAR ) || ( getCurrentTreePanel()
.getPhylogenyGraphicsType() == PHYLOGENY_GRAPHICS_TYPE.UNROOTED ) ) ) ) {
- if ( getMainPanel().getMainFrame()._non_lined_up_cladograms_rbmi != null ) {
- getMainPanel().getMainFrame()._non_lined_up_cladograms_rbmi.setVisible( false );
+ if ( mf._non_lined_up_cladograms_rbmi != null ) {
+ mf._non_lined_up_cladograms_rbmi.setVisible( false );
}
- if ( getMainPanel().getMainFrame()._uniform_cladograms_rbmi != null ) {
- getMainPanel().getMainFrame()._uniform_cladograms_rbmi.setVisible( false );
+ if ( mf._uniform_cladograms_rbmi != null ) {
+ mf._uniform_cladograms_rbmi.setVisible( false );
}
- if ( getMainPanel().getMainFrame()._ext_node_dependent_cladogram_rbmi != null ) {
- getMainPanel().getMainFrame()._ext_node_dependent_cladogram_rbmi.setVisible( false );
+ if ( mf._ext_node_dependent_cladogram_rbmi != null ) {
+ mf._ext_node_dependent_cladogram_rbmi.setVisible( false );
}
}
else {
- if ( getMainPanel().getMainFrame()._non_lined_up_cladograms_rbmi != null ) {
- getMainPanel().getMainFrame()._non_lined_up_cladograms_rbmi.setVisible( true );
+ if ( mf._non_lined_up_cladograms_rbmi != null ) {
+ mf._non_lined_up_cladograms_rbmi.setVisible( true );
}
- if ( getMainPanel().getMainFrame()._uniform_cladograms_rbmi != null ) {
- getMainPanel().getMainFrame()._uniform_cladograms_rbmi.setVisible( true );
+ if ( mf._uniform_cladograms_rbmi != null ) {
+ mf._uniform_cladograms_rbmi.setVisible( true );
}
- if ( getMainPanel().getMainFrame()._ext_node_dependent_cladogram_rbmi != null ) {
- getMainPanel().getMainFrame()._ext_node_dependent_cladogram_rbmi.setVisible( true );
+ if ( mf._ext_node_dependent_cladogram_rbmi != null ) {
+ mf._ext_node_dependent_cladogram_rbmi.setVisible( true );
}
}
if ( isDrawPhylogram() ) {
- if ( getMainPanel().getMainFrame()._show_scale_cbmi != null ) {
- getMainPanel().getMainFrame()._show_scale_cbmi.setVisible( true );
+ if ( mf._show_scale_cbmi != null ) {
+ mf._show_scale_cbmi.setVisible( true );
}
}
else {
- if ( getMainPanel().getMainFrame()._show_scale_cbmi != null ) {
- getMainPanel().getMainFrame()._show_scale_cbmi.setVisible( false );
+ if ( mf._show_scale_cbmi != null ) {
+ mf._show_scale_cbmi.setVisible( false );
}
}
if ( getCurrentTreePanel() != null ) {
if ( ( getCurrentTreePanel().getPhylogenyGraphicsType() == PHYLOGENY_GRAPHICS_TYPE.CIRCULAR )
|| ( getCurrentTreePanel().getPhylogenyGraphicsType() == PHYLOGENY_GRAPHICS_TYPE.UNROOTED ) ) {
- if ( getMainPanel().getMainFrame()._label_direction_cbmi != null ) {
- getMainPanel().getMainFrame()._label_direction_cbmi.setVisible( true );
- }
- if ( getMainPanel().getMainFrame()._show_branch_length_values_cbmi != null ) {
- getMainPanel().getMainFrame()._show_branch_length_values_cbmi.setVisible( false );
+ if ( mf._label_direction_cbmi != null ) {
+ mf._label_direction_cbmi.setVisible( true );
}
}
else {
- if ( getMainPanel().getMainFrame()._label_direction_cbmi != null ) {
- getMainPanel().getMainFrame()._label_direction_cbmi.setVisible( false );
- }
- if ( getMainPanel().getMainFrame()._show_branch_length_values_cbmi != null ) {
- getMainPanel().getMainFrame()._show_branch_length_values_cbmi.setVisible( true );
+ if ( mf._label_direction_cbmi != null ) {
+ mf._label_direction_cbmi.setVisible( false );
}
}
}
}
- catch ( final Exception ignore ) {
- //not important...
- }
}
void setVisibilityOfDomainStrucureCB() {
CHANGE_NODE_FONT,
COLOR_NODE_FONT;
}
-
- public boolean isShowMolSequences() {
- // TODO Auto-generated method stub
- return true;
- }
}