2 * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3 * Copyright (C) $$Year-Rel$$ The Jalview Authors
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3
10 * of the License, or (at your option) any later version.
12 * Jalview is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty
14 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19 * The Jalview Authors are detailed in the 'AUTHORS' file.
21 package jalview.jbgui;
23 import jalview.fts.core.FTSDataColumnPreferences;
24 import jalview.fts.core.FTSDataColumnPreferences.PreferenceSource;
25 import jalview.fts.service.pdb.PDBFTSRestClient;
26 import jalview.gui.JvSwingUtils;
27 import jalview.gui.StructureViewer.ViewerType;
28 import jalview.util.MessageManager;
30 import java.awt.BorderLayout;
31 import java.awt.Color;
32 import java.awt.Component;
33 import java.awt.Dimension;
34 import java.awt.FlowLayout;
36 import java.awt.GridBagConstraints;
37 import java.awt.GridBagLayout;
38 import java.awt.GridLayout;
39 import java.awt.Insets;
40 import java.awt.Rectangle;
41 import java.awt.event.ActionEvent;
42 import java.awt.event.ActionListener;
43 import java.awt.event.FocusEvent;
44 import java.awt.event.KeyEvent;
45 import java.awt.event.MouseAdapter;
46 import java.awt.event.MouseEvent;
48 import javax.swing.BorderFactory;
49 import javax.swing.ButtonGroup;
50 import javax.swing.DefaultListCellRenderer;
51 import javax.swing.JButton;
52 import javax.swing.JCheckBox;
53 import javax.swing.JComboBox;
54 import javax.swing.JFileChooser;
55 import javax.swing.JLabel;
56 import javax.swing.JList;
57 import javax.swing.JPanel;
58 import javax.swing.JRadioButton;
59 import javax.swing.JScrollPane;
60 import javax.swing.JTabbedPane;
61 import javax.swing.JTextField;
62 import javax.swing.ListSelectionModel;
63 import javax.swing.SwingConstants;
64 import javax.swing.border.Border;
65 import javax.swing.border.EmptyBorder;
66 import javax.swing.border.EtchedBorder;
67 import javax.swing.border.TitledBorder;
68 import javax.swing.event.ChangeEvent;
69 import javax.swing.event.ChangeListener;
70 import javax.swing.event.ListSelectionEvent;
71 import javax.swing.event.ListSelectionListener;
74 * Base class for the Preferences panel.
79 public class GPreferences extends JPanel
81 private static final Font LABEL_FONT = JvSwingUtils.getLabelFont();
83 private static final Font LABEL_FONT_ITALIC = JvSwingUtils.getLabelFont(
87 * Visual tab components
89 protected JCheckBox fullScreen = new JCheckBox();
91 protected JCheckBox openoverv = new JCheckBox();
93 protected JCheckBox seqLimit = new JCheckBox();
95 protected JCheckBox rightAlign = new JCheckBox();
97 protected JComboBox<String> fontSizeCB = new JComboBox<String>();
99 protected JComboBox<String> fontStyleCB = new JComboBox<String>();
101 protected JComboBox<String> fontNameCB = new JComboBox<String>();
103 protected JCheckBox showUnconserved = new JCheckBox();
105 protected JCheckBox idItalics = new JCheckBox();
107 protected JCheckBox smoothFont = new JCheckBox();
109 protected JCheckBox scaleProteinToCdna = new JCheckBox();
111 protected JComboBox<String> gapSymbolCB = new JComboBox<String>();
113 protected JCheckBox wrap = new JCheckBox();
115 protected JComboBox<String> sortby = new JComboBox<String>();
117 protected JComboBox<String> sortAnnBy = new JComboBox<String>();
119 protected JComboBox<String> sortAutocalc = new JComboBox<String>();
121 protected JCheckBox startupCheckbox = new JCheckBox();
123 protected JTextField startupFileTextfield = new JTextField();
125 // below are in the 'second column'
126 protected JCheckBox annotations = new JCheckBox();
128 protected JCheckBox quality = new JCheckBox();
130 protected JCheckBox conservation = new JCheckBox();
132 protected JCheckBox identity = new JCheckBox();
134 protected JCheckBox showGroupConsensus = new JCheckBox();
136 protected JCheckBox showGroupConservation = new JCheckBox();
138 protected JCheckBox showConsensHistogram = new JCheckBox();
140 protected JCheckBox showConsensLogo = new JCheckBox();
142 protected JCheckBox showDbRefTooltip = new JCheckBox();
144 protected JCheckBox showNpTooltip = new JCheckBox();
147 * Structure tab and components
149 protected JPanel structureTab;
151 protected JCheckBox structFromPdb = new JCheckBox();
153 protected JCheckBox useRnaView = new JCheckBox();
155 protected JCheckBox addSecondaryStructure = new JCheckBox();
157 protected JCheckBox addTempFactor = new JCheckBox();
159 protected JComboBox<String> structViewer = new JComboBox<String>();
161 protected JTextField chimeraPath = new JTextField();
163 protected ButtonGroup mappingMethod = new ButtonGroup();
165 protected JRadioButton siftsMapping = new JRadioButton();
167 protected JRadioButton nwMapping = new JRadioButton();
170 * Colours tab components
172 protected JPanel minColour = new JPanel();
174 protected JPanel maxColour = new JPanel();
176 protected JComboBox<String> protColour = new JComboBox<String>();
178 protected JComboBox<String> nucColour = new JComboBox<String>();
181 * Connections tab components
183 protected JList linkURLList = new JList();
185 protected JTextField proxyServerTB = new JTextField();
187 protected JTextField proxyPortTB = new JTextField();
189 protected JTextField defaultBrowser = new JTextField();
191 protected JList linkNameList = new JList();
193 protected JCheckBox useProxy = new JCheckBox();
195 protected JCheckBox usagestats = new JCheckBox();
197 protected JCheckBox questionnaire = new JCheckBox();
199 protected JCheckBox versioncheck = new JCheckBox();
202 * Output tab components
204 protected JComboBox<Object> epsRendering = new JComboBox<Object>();
206 protected JLabel userIdWidthlabel = new JLabel();
208 protected JCheckBox autoIdWidth = new JCheckBox();
210 protected JTextField userIdWidth = new JTextField();
212 protected JCheckBox blcjv = new JCheckBox();
214 protected JCheckBox pileupjv = new JCheckBox();
216 protected JCheckBox clustaljv = new JCheckBox();
218 protected JCheckBox msfjv = new JCheckBox();
220 protected JCheckBox fastajv = new JCheckBox();
222 protected JCheckBox pfamjv = new JCheckBox();
224 protected JCheckBox pirjv = new JCheckBox();
226 protected JCheckBox modellerOutput = new JCheckBox();
228 protected JCheckBox embbedBioJSON = new JCheckBox();
231 * Editing tab components
233 protected JCheckBox autoCalculateConsCheck = new JCheckBox();
235 protected JCheckBox padGaps = new JCheckBox();
237 protected JCheckBox sortByTree = new JCheckBox();
242 protected JPanel dasTab = new JPanel();
247 protected JPanel wsTab = new JPanel();
250 * Creates a new GPreferences object.
252 public GPreferences()
257 } catch (Exception ex)
259 ex.printStackTrace();
264 * Construct the panel and its tabbed sub-panels.
268 private void jbInit() throws Exception
270 final JTabbedPane tabbedPane = new JTabbedPane();
271 this.setLayout(new BorderLayout());
272 JPanel okCancelPanel = initOkCancelPanel();
273 this.add(tabbedPane, BorderLayout.CENTER);
274 this.add(okCancelPanel, BorderLayout.SOUTH);
276 tabbedPane.add(initVisualTab(),
277 MessageManager.getString("label.visual"));
279 tabbedPane.add(initColoursTab(),
280 MessageManager.getString("label.colours"));
282 tabbedPane.add(initStructureTab(),
283 MessageManager.getString("label.structure"));
285 tabbedPane.add(initConnectionsTab(),
286 MessageManager.getString("label.connections"));
288 tabbedPane.add(initOutputTab(),
289 MessageManager.getString("label.output"));
291 tabbedPane.add(initEditingTab(),
292 MessageManager.getString("label.editing"));
295 * See DasSourceBrowser for the real work of configuring this tab.
297 dasTab.setLayout(new BorderLayout());
298 tabbedPane.add(dasTab, MessageManager.getString("label.das_settings"));
301 * See WsPreferences for the real work of configuring this tab.
303 wsTab.setLayout(new BorderLayout());
304 tabbedPane.add(wsTab, MessageManager.getString("label.web_services"));
307 * Handler to validate a tab before leaving it - currently only for
310 tabbedPane.addChangeListener(new ChangeListener()
312 private Component lastTab;
315 public void stateChanged(ChangeEvent e)
317 if (lastTab == structureTab
318 && tabbedPane.getSelectedComponent() != structureTab)
320 if (!validateStructure())
322 tabbedPane.setSelectedComponent(structureTab);
326 lastTab = tabbedPane.getSelectedComponent();
333 * Initialises the Editing tabbed panel.
337 private JPanel initEditingTab()
339 JPanel editingTab = new JPanel();
340 editingTab.setLayout(null);
341 autoCalculateConsCheck.setFont(LABEL_FONT);
342 autoCalculateConsCheck.setText(MessageManager
343 .getString("label.autocalculate_consensus"));
344 autoCalculateConsCheck.setBounds(new Rectangle(21, 52, 209, 23));
345 padGaps.setFont(LABEL_FONT);
346 padGaps.setText(MessageManager.getString("label.pad_gaps_when_editing"));
347 padGaps.setBounds(new Rectangle(22, 94, 168, 23));
348 sortByTree.setFont(LABEL_FONT);
350 .setText(MessageManager.getString("label.sort_with_new_tree"));
352 .setToolTipText(MessageManager
353 .getString("label.any_trees_calculated_or_loaded_alignment_automatically_sort"));
354 sortByTree.setBounds(new Rectangle(22, 136, 168, 23));
355 editingTab.add(autoCalculateConsCheck);
356 editingTab.add(padGaps);
357 editingTab.add(sortByTree);
362 * Initialises the Output tabbed panel.
366 private JPanel initOutputTab()
368 JPanel outputTab = new JPanel();
369 outputTab.setLayout(null);
370 JLabel epsLabel = new JLabel();
371 epsLabel.setFont(LABEL_FONT);
372 epsLabel.setHorizontalAlignment(SwingConstants.RIGHT);
373 epsLabel.setText(MessageManager.getString("label.eps_rendering_style"));
374 epsLabel.setBounds(new Rectangle(9, 31, 140, 24));
375 epsRendering.setFont(LABEL_FONT);
376 epsRendering.setBounds(new Rectangle(154, 34, 187, 21));
377 JLabel jLabel1 = new JLabel();
378 jLabel1.setFont(LABEL_FONT);
379 jLabel1.setHorizontalAlignment(SwingConstants.CENTER);
380 jLabel1.setText(MessageManager.getString("label.append_start_end"));
381 jLabel1.setFont(LABEL_FONT);
382 fastajv.setFont(LABEL_FONT);
383 fastajv.setHorizontalAlignment(SwingConstants.LEFT);
384 clustaljv.setText(MessageManager.getString("label.clustal") + " ");
385 blcjv.setText(MessageManager.getString("label.blc") + " ");
386 fastajv.setText(MessageManager.getString("label.fasta") + " ");
387 msfjv.setText(MessageManager.getString("label.msf") + " ");
388 pfamjv.setText(MessageManager.getString("label.pfam") + " ");
389 pileupjv.setText(MessageManager.getString("label.pileup") + " ");
390 msfjv.setFont(LABEL_FONT);
391 msfjv.setHorizontalAlignment(SwingConstants.LEFT);
392 pirjv.setText(MessageManager.getString("label.pir") + " ");
393 JPanel jPanel11 = new JPanel();
394 jPanel11.setFont(LABEL_FONT);
395 TitledBorder titledBorder2 = new TitledBorder(
396 MessageManager.getString("label.file_output"));
397 jPanel11.setBorder(titledBorder2);
398 jPanel11.setBounds(new Rectangle(30, 72, 196, 182));
399 GridLayout gridLayout3 = new GridLayout();
400 jPanel11.setLayout(gridLayout3);
401 gridLayout3.setRows(8);
402 blcjv.setFont(LABEL_FONT);
403 blcjv.setHorizontalAlignment(SwingConstants.LEFT);
404 clustaljv.setFont(LABEL_FONT);
405 clustaljv.setHorizontalAlignment(SwingConstants.LEFT);
406 pfamjv.setFont(LABEL_FONT);
407 pfamjv.setHorizontalAlignment(SwingConstants.LEFT);
408 pileupjv.setFont(LABEL_FONT);
409 pileupjv.setHorizontalAlignment(SwingConstants.LEFT);
410 pirjv.setFont(LABEL_FONT);
411 pirjv.setHorizontalAlignment(SwingConstants.LEFT);
412 autoIdWidth.setFont(LABEL_FONT);
413 autoIdWidth.setText(MessageManager
414 .getString("label.automatically_set_id_width"));
415 autoIdWidth.setToolTipText(JvSwingUtils.wrapTooltip(true,
417 .getString("label.adjusts_width_generated_eps_png")));
418 autoIdWidth.setBounds(new Rectangle(228, 96, 188, 23));
419 autoIdWidth.addActionListener(new ActionListener()
423 public void actionPerformed(ActionEvent e)
425 autoIdWidth_actionPerformed();
428 userIdWidthlabel.setFont(LABEL_FONT);
429 userIdWidthlabel.setText(MessageManager
430 .getString("label.figure_id_column_width"));
432 .setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager
433 .getString("label.manually_specify_width_left_column")));
435 .setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager
436 .getString("label.manually_specify_width_left_column")));
437 userIdWidthlabel.setBounds(new Rectangle(236, 120, 168, 23));
438 userIdWidth.setFont(JvSwingUtils.getTextAreaFont());
439 userIdWidth.setText("");
440 userIdWidth.setBounds(new Rectangle(232, 144, 84, 23));
441 userIdWidth.addActionListener(new ActionListener()
445 public void actionPerformed(ActionEvent e)
447 userIdWidth_actionPerformed();
450 modellerOutput.setFont(LABEL_FONT);
451 modellerOutput.setText(MessageManager
452 .getString("label.use_modeller_output"));
453 modellerOutput.setBounds(new Rectangle(228, 226, 168, 23));
454 embbedBioJSON.setFont(LABEL_FONT);
455 embbedBioJSON.setText(MessageManager.getString("label.embbed_biojson"));
456 embbedBioJSON.setBounds(new Rectangle(228, 200, 250, 23));
458 jPanel11.add(jLabel1);
460 jPanel11.add(clustaljv);
461 jPanel11.add(fastajv);
463 jPanel11.add(pfamjv);
464 jPanel11.add(pileupjv);
466 outputTab.add(autoIdWidth);
467 outputTab.add(userIdWidth);
468 outputTab.add(userIdWidthlabel);
469 outputTab.add(modellerOutput);
470 outputTab.add(embbedBioJSON);
471 outputTab.add(epsLabel);
472 outputTab.add(epsRendering);
473 outputTab.add(jPanel11);
478 * Initialises the Connections tabbed panel.
482 private JPanel initConnectionsTab()
484 JPanel connectTab = new JPanel();
485 connectTab.setLayout(new GridBagLayout());
486 JLabel serverLabel = new JLabel();
487 serverLabel.setText(MessageManager.getString("label.address"));
488 serverLabel.setHorizontalAlignment(SwingConstants.RIGHT);
489 serverLabel.setFont(LABEL_FONT);
490 proxyServerTB.setFont(LABEL_FONT);
491 proxyPortTB.setFont(LABEL_FONT);
492 JLabel portLabel = new JLabel();
493 portLabel.setFont(LABEL_FONT);
494 portLabel.setHorizontalAlignment(SwingConstants.RIGHT);
495 portLabel.setText(MessageManager.getString("label.port"));
496 JLabel browserLabel = new JLabel();
497 browserLabel.setFont(new java.awt.Font("SansSerif", 0, 11));
498 browserLabel.setHorizontalAlignment(SwingConstants.TRAILING);
499 browserLabel.setText(MessageManager
500 .getString("label.default_browser_unix"));
501 defaultBrowser.setFont(LABEL_FONT);
502 defaultBrowser.setText("");
503 usagestats.setText(MessageManager
504 .getString("label.send_usage_statistics"));
505 usagestats.setFont(LABEL_FONT);
506 usagestats.setHorizontalAlignment(SwingConstants.RIGHT);
507 usagestats.setHorizontalTextPosition(SwingConstants.LEADING);
508 questionnaire.setText(MessageManager
509 .getString("label.check_for_questionnaires"));
510 questionnaire.setFont(LABEL_FONT);
511 questionnaire.setHorizontalAlignment(SwingConstants.RIGHT);
512 questionnaire.setHorizontalTextPosition(SwingConstants.LEADING);
513 versioncheck.setText(MessageManager
514 .getString("label.check_for_latest_version"));
515 versioncheck.setFont(LABEL_FONT);
516 versioncheck.setHorizontalAlignment(SwingConstants.RIGHT);
517 versioncheck.setHorizontalTextPosition(SwingConstants.LEADING);
518 JButton newLink = new JButton();
519 newLink.setText(MessageManager.getString("action.new"));
520 newLink.addActionListener(new java.awt.event.ActionListener()
523 public void actionPerformed(ActionEvent e)
525 newLink_actionPerformed(e);
528 JButton editLink = new JButton();
529 editLink.setText(MessageManager.getString("action.edit"));
530 editLink.addActionListener(new java.awt.event.ActionListener()
533 public void actionPerformed(ActionEvent e)
535 editLink_actionPerformed(e);
538 JButton deleteLink = new JButton();
539 deleteLink.setText(MessageManager.getString("action.delete"));
540 deleteLink.addActionListener(new java.awt.event.ActionListener()
543 public void actionPerformed(ActionEvent e)
545 deleteLink_actionPerformed(e);
549 linkURLList.addListSelectionListener(new ListSelectionListener()
552 public void valueChanged(ListSelectionEvent e)
554 int index = linkURLList.getSelectedIndex();
555 linkNameList.setSelectedIndex(index);
559 linkNameList.addListSelectionListener(new ListSelectionListener()
562 public void valueChanged(ListSelectionEvent e)
564 int index = linkNameList.getSelectedIndex();
565 linkURLList.setSelectedIndex(index);
569 JScrollPane linkScrollPane = new JScrollPane();
570 linkScrollPane.setBorder(null);
571 JPanel linkPanel = new JPanel();
572 linkPanel.setBorder(new TitledBorder(MessageManager
573 .getString("label.url_linkfrom_sequence_id")));
574 linkPanel.setLayout(new BorderLayout());
575 GridLayout gridLayout1 = new GridLayout();
576 JPanel editLinkButtons = new JPanel();
577 editLinkButtons.setLayout(gridLayout1);
578 gridLayout1.setRows(3);
579 linkNameList.setFont(LABEL_FONT);
580 linkNameList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
581 BorderLayout borderLayout3 = new BorderLayout();
582 JPanel linkPanel2 = new JPanel();
583 linkPanel2.setLayout(borderLayout3);
584 linkURLList.setFont(LABEL_FONT);
585 linkURLList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
587 defaultBrowser.addMouseListener(new MouseAdapter()
590 public void mouseClicked(MouseEvent e)
592 if (e.getClickCount() > 1)
594 defaultBrowser_mouseClicked(e);
598 useProxy.setFont(LABEL_FONT);
599 useProxy.setHorizontalAlignment(SwingConstants.RIGHT);
600 useProxy.setHorizontalTextPosition(SwingConstants.LEADING);
601 useProxy.setText(MessageManager.getString("label.use_proxy_server"));
602 useProxy.addActionListener(new ActionListener()
605 public void actionPerformed(ActionEvent e)
607 useProxy_actionPerformed();
610 linkPanel.add(editLinkButtons, BorderLayout.EAST);
611 editLinkButtons.add(newLink, null);
612 editLinkButtons.add(editLink, null);
613 editLinkButtons.add(deleteLink, null);
614 linkPanel.add(linkScrollPane, BorderLayout.CENTER);
615 linkScrollPane.getViewport().add(linkPanel2, null);
616 linkPanel2.add(linkURLList, BorderLayout.CENTER);
617 linkPanel2.add(linkNameList, BorderLayout.WEST);
618 JPanel jPanel1 = new JPanel();
619 TitledBorder titledBorder1 = new TitledBorder(
620 MessageManager.getString("label.proxy_server"));
621 jPanel1.setBorder(titledBorder1);
622 jPanel1.setLayout(new GridBagLayout());
623 jPanel1.add(serverLabel, new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0,
624 GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0,
626 jPanel1.add(portLabel, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0,
627 GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0,
629 connectTab.add(linkPanel, new GridBagConstraints(0, 0, 2, 1, 1.0, 1.0,
630 GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(
631 16, 0, 0, 12), 359, -17));
632 connectTab.add(jPanel1, new GridBagConstraints(0, 2, 2, 1, 1.0, 1.0,
633 GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(
634 21, 0, 35, 12), 4, 6));
635 connectTab.add(browserLabel, new GridBagConstraints(0, 1, 1, 1, 0.0,
636 0.0, GridBagConstraints.WEST, GridBagConstraints.NONE,
637 new Insets(16, 0, 0, 0), 5, 1));
638 jPanel1.add(useProxy, new GridBagConstraints(0, 0, 2, 1, 0.0, 0.0,
639 GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0,
641 jPanel1.add(proxyPortTB, new GridBagConstraints(3, 1, 1, 1, 1.0, 0.0,
642 GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL,
643 new Insets(0, 2, 4, 2), 54, 1));
644 jPanel1.add(proxyServerTB, new GridBagConstraints(1, 1, 1, 1, 1.0, 0.0,
645 GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL,
646 new Insets(0, 2, 4, 0), 263, 1));
647 connectTab.add(defaultBrowser, new GridBagConstraints(1, 1, 1, 1, 1.0,
648 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL,
649 new Insets(15, 0, 0, 15), 307, 1));
650 connectTab.add(usagestats, new GridBagConstraints(0, 4, 1, 1, 1.0, 0.0,
651 GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL,
652 new Insets(0, 2, 4, 2), 70, 1));
653 connectTab.add(questionnaire, new GridBagConstraints(1, 4, 1, 1, 1.0,
654 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL,
655 new Insets(0, 2, 4, 2), 70, 1));
656 connectTab.add(versioncheck, new GridBagConstraints(0, 5, 1, 1, 1.0,
657 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL,
658 new Insets(0, 2, 4, 2), 70, 1));
663 * Initialises the parent panel which contains the tabbed sections.
667 private JPanel initOkCancelPanel()
669 JButton ok = new JButton();
670 ok.setText(MessageManager.getString("action.ok"));
671 ok.addActionListener(new ActionListener()
674 public void actionPerformed(ActionEvent e)
676 ok_actionPerformed(e);
679 JButton cancel = new JButton();
680 cancel.setText(MessageManager.getString("action.cancel"));
681 cancel.addActionListener(new ActionListener()
684 public void actionPerformed(ActionEvent e)
686 cancel_actionPerformed(e);
689 JPanel okCancelPanel = new JPanel();
690 okCancelPanel.add(ok);
691 okCancelPanel.add(cancel);
692 return okCancelPanel;
696 * Initialises the Colours tabbed panel.
700 private JPanel initColoursTab()
702 JPanel coloursTab = new JPanel();
703 coloursTab.setBorder(new TitledBorder(MessageManager
704 .getString("action.open_new_alignment")));
705 coloursTab.setLayout(new FlowLayout());
706 JLabel mincolourLabel = new JLabel();
707 mincolourLabel.setFont(LABEL_FONT);
708 mincolourLabel.setHorizontalAlignment(SwingConstants.RIGHT);
709 mincolourLabel.setText(MessageManager.getString("label.min_colour"));
710 minColour.setFont(LABEL_FONT);
711 minColour.setBorder(BorderFactory.createEtchedBorder());
712 minColour.setPreferredSize(new Dimension(40, 20));
713 minColour.addMouseListener(new MouseAdapter()
716 public void mousePressed(MouseEvent e)
718 minColour_actionPerformed(minColour);
721 JLabel maxcolourLabel = new JLabel();
722 maxcolourLabel.setFont(LABEL_FONT);
723 maxcolourLabel.setHorizontalAlignment(SwingConstants.RIGHT);
724 maxcolourLabel.setText(MessageManager.getString("label.max_colour"));
725 maxColour.setFont(LABEL_FONT);
726 maxColour.setBorder(BorderFactory.createEtchedBorder());
727 maxColour.setPreferredSize(new Dimension(40, 20));
728 maxColour.addMouseListener(new MouseAdapter()
731 public void mousePressed(MouseEvent e)
733 maxColour_actionPerformed(maxColour);
737 protColour.setFont(LABEL_FONT);
738 protColour.setBounds(new Rectangle(172, 225, 155, 21));
739 JLabel protColourLabel = new JLabel();
740 protColourLabel.setFont(LABEL_FONT);
741 protColourLabel.setHorizontalAlignment(SwingConstants.LEFT);
742 protColourLabel.setText(MessageManager
743 .getString("label.prot_alignment_colour") + " ");
744 JvSwingUtils.addtoLayout(coloursTab, MessageManager
745 .getString("label.default_colour_scheme_for_alignment"),
746 protColourLabel, protColour);
748 nucColour.setFont(LABEL_FONT);
749 nucColour.setBounds(new Rectangle(172, 240, 155, 21));
750 JLabel nucColourLabel = new JLabel();
751 nucColourLabel.setFont(LABEL_FONT);
752 nucColourLabel.setHorizontalAlignment(SwingConstants.LEFT);
753 nucColourLabel.setText(MessageManager
754 .getString("label.nuc_alignment_colour") + " ");
755 JvSwingUtils.addtoLayout(coloursTab, MessageManager
756 .getString("label.default_colour_scheme_for_alignment"),
757 nucColourLabel, nucColour);
759 JPanel annotationShding = new JPanel();
760 annotationShding.setBorder(new TitledBorder(MessageManager
761 .getString("label.annotation_shading_default")));
762 annotationShding.setLayout(new GridLayout(1, 2));
763 JvSwingUtils.addtoLayout(annotationShding, MessageManager
764 .getString("label.default_minimum_colour_annotation_shading"),
765 mincolourLabel, minColour);
766 JvSwingUtils.addtoLayout(annotationShding, MessageManager
767 .getString("label.default_maximum_colour_annotation_shading"),
768 maxcolourLabel, maxColour);
769 coloursTab.add(annotationShding); // , FlowLayout.LEFT);
774 * Initialises the Structure tabbed panel.
778 private JPanel initStructureTab()
780 structureTab = new JPanel();
782 structureTab.setBorder(new TitledBorder(MessageManager
783 .getString("label.structure_options")));
784 structureTab.setLayout(null);
785 final int width = 400;
786 final int height = 22;
787 final int lineSpacing = 25;
790 structFromPdb.setFont(LABEL_FONT);
792 .setText(MessageManager.getString("label.struct_from_pdb"));
793 structFromPdb.setBounds(new Rectangle(5, ypos, width, height));
794 structFromPdb.addActionListener(new ActionListener()
797 public void actionPerformed(ActionEvent e)
799 boolean selected = structFromPdb.isSelected();
800 // enable other options only when the first is checked
801 useRnaView.setEnabled(selected);
802 addSecondaryStructure.setEnabled(selected);
803 addTempFactor.setEnabled(selected);
806 structureTab.add(structFromPdb);
808 // indent checkboxes that are conditional on the first one
810 useRnaView.setFont(LABEL_FONT);
811 useRnaView.setText(MessageManager.getString("label.use_rnaview"));
812 useRnaView.setBounds(new Rectangle(25, ypos, width, height));
813 structureTab.add(useRnaView);
816 addSecondaryStructure.setFont(LABEL_FONT);
817 addSecondaryStructure.setText(MessageManager
818 .getString("label.autoadd_secstr"));
819 addSecondaryStructure.setBounds(new Rectangle(25, ypos, width, height));
820 structureTab.add(addSecondaryStructure);
823 addTempFactor.setFont(LABEL_FONT);
824 addTempFactor.setText(MessageManager.getString("label.autoadd_temp"));
825 addTempFactor.setBounds(new Rectangle(25, ypos, width, height));
826 structureTab.add(addTempFactor);
829 JLabel viewerLabel = new JLabel();
830 viewerLabel.setFont(LABEL_FONT);
831 viewerLabel.setHorizontalAlignment(SwingConstants.LEFT);
832 viewerLabel.setText(MessageManager.getString("label.structure_viewer"));
833 viewerLabel.setBounds(new Rectangle(10, ypos, 200, height));
834 structureTab.add(viewerLabel);
836 structViewer.setFont(LABEL_FONT);
837 structViewer.setBounds(new Rectangle(160, ypos, 120, height));
838 structViewer.addItem(ViewerType.JMOL.name());
839 structViewer.addItem(ViewerType.CHIMERA.name());
840 structViewer.addActionListener(new ActionListener()
843 public void actionPerformed(ActionEvent e)
845 structureViewer_actionPerformed((String) structViewer
849 structureTab.add(structViewer);
852 JLabel pathLabel = new JLabel();
853 pathLabel.setFont(new java.awt.Font("SansSerif", 0, 11));
854 pathLabel.setHorizontalAlignment(SwingConstants.LEFT);
855 pathLabel.setText(MessageManager.getString("label.chimera_path"));
856 final String tooltip = JvSwingUtils.wrapTooltip(true,
857 MessageManager.getString("label.chimera_path_tip"));
858 pathLabel.setToolTipText(tooltip);
859 pathLabel.setBounds(new Rectangle(10, ypos, 140, height));
860 structureTab.add(pathLabel);
862 chimeraPath.setFont(LABEL_FONT);
863 chimeraPath.setText("");
864 chimeraPath.setBounds(new Rectangle(160, ypos, 300, height));
865 chimeraPath.addMouseListener(new MouseAdapter()
868 public void mouseClicked(MouseEvent e)
870 if (e.getClickCount() == 2)
872 String chosen = openFileChooser();
875 chimeraPath.setText(chosen);
880 structureTab.add(chimeraPath);
883 nwMapping.setFont(LABEL_FONT);
884 nwMapping.setText(MessageManager.getString("label.nw_mapping"));
885 siftsMapping.setFont(LABEL_FONT);
886 siftsMapping.setText(MessageManager.getString("label.sifts_mapping"));
887 mappingMethod.add(nwMapping);
888 mappingMethod.add(siftsMapping);
889 JPanel mappingPanel = new JPanel();
890 mappingPanel.setFont(LABEL_FONT);
891 TitledBorder mmTitledBorder = new TitledBorder(
892 MessageManager.getString("label.mapping_method"));
893 mmTitledBorder.setTitleFont(LABEL_FONT);
894 mappingPanel.setBorder(mmTitledBorder);
895 mappingPanel.setBounds(new Rectangle(10, ypos, 452, 45));
896 // GridLayout mappingLayout = new GridLayout();
897 mappingPanel.setLayout(new GridLayout());
898 mappingPanel.add(nwMapping);
899 mappingPanel.add(siftsMapping);
900 structureTab.add(mappingPanel);
904 FTSDataColumnPreferences docFieldPref = new FTSDataColumnPreferences(
905 PreferenceSource.PREFERENCES, PDBFTSRestClient.getInstance());
906 docFieldPref.setBounds(new Rectangle(10, ypos, 450, 120));
907 structureTab.add(docFieldPref);
913 * Action on choosing a structure viewer from combobox options.
915 * @param selectedItem
917 protected void structureViewer_actionPerformed(String selectedItem)
922 * Show a dialog for the user to choose a file. Returns the chosen path, or
927 protected String openFileChooser()
929 String choice = null;
930 JFileChooser chooser = new JFileChooser();
932 // chooser.setFileView(new JalviewFileView());
933 chooser.setDialogTitle(MessageManager
934 .getString("label.open_local_file"));
935 chooser.setToolTipText(MessageManager.getString("action.open"));
937 int value = chooser.showOpenDialog(this);
939 if (value == JFileChooser.APPROVE_OPTION)
941 choice = chooser.getSelectedFile().getPath();
947 * Validate the structure tab preferences; if invalid, set focus on this tab.
951 protected boolean validateStructure(FocusEvent e)
953 if (!validateStructure())
955 e.getComponent().requestFocusInWindow();
961 protected boolean validateStructure()
967 * Initialises the Visual tabbed panel.
971 private JPanel initVisualTab()
973 JPanel visualTab = new JPanel();
974 visualTab.setBorder(new TitledBorder(MessageManager
975 .getString("action.open_new_alignment")));
976 visualTab.setLayout(null);
977 fullScreen.setFont(LABEL_FONT);
978 fullScreen.setHorizontalAlignment(SwingConstants.RIGHT);
979 fullScreen.setHorizontalTextPosition(SwingConstants.LEFT);
980 fullScreen.setText(MessageManager.getString("label.maximize_window"));
981 quality.setEnabled(false);
982 quality.setFont(LABEL_FONT);
983 quality.setHorizontalAlignment(SwingConstants.RIGHT);
984 quality.setHorizontalTextPosition(SwingConstants.LEFT);
985 quality.setSelected(true);
986 quality.setText(MessageManager.getString("label.quality"));
987 conservation.setEnabled(false);
988 conservation.setFont(LABEL_FONT);
989 conservation.setHorizontalAlignment(SwingConstants.RIGHT);
990 conservation.setHorizontalTextPosition(SwingConstants.LEFT);
991 conservation.setSelected(true);
992 conservation.setText(MessageManager.getString("label.conservation"));
993 identity.setEnabled(false);
994 identity.setFont(LABEL_FONT);
995 identity.setHorizontalAlignment(SwingConstants.RIGHT);
996 identity.setHorizontalTextPosition(SwingConstants.LEFT);
997 identity.setSelected(true);
998 identity.setText(MessageManager.getString("label.consensus"));
999 JLabel showGroupbits = new JLabel();
1000 showGroupbits.setFont(LABEL_FONT);
1001 showGroupbits.setHorizontalAlignment(SwingConstants.RIGHT);
1002 showGroupbits.setHorizontalTextPosition(SwingConstants.LEFT);
1003 showGroupbits.setText(MessageManager.getString("action.show_group")
1005 JLabel showConsensbits = new JLabel();
1006 showConsensbits.setFont(LABEL_FONT);
1007 showConsensbits.setHorizontalAlignment(SwingConstants.RIGHT);
1008 showConsensbits.setHorizontalTextPosition(SwingConstants.LEFT);
1009 showConsensbits.setText(MessageManager.getString("label.consensus")
1011 showConsensHistogram.setEnabled(false);
1012 showConsensHistogram.setFont(LABEL_FONT);
1013 showConsensHistogram.setHorizontalAlignment(SwingConstants.RIGHT);
1014 showConsensHistogram.setHorizontalTextPosition(SwingConstants.LEFT);
1015 showConsensHistogram.setSelected(true);
1016 showConsensHistogram.setText(MessageManager
1017 .getString("label.histogram"));
1018 showConsensLogo.setEnabled(false);
1019 showConsensLogo.setFont(LABEL_FONT);
1020 showConsensLogo.setHorizontalAlignment(SwingConstants.RIGHT);
1021 showConsensLogo.setHorizontalTextPosition(SwingConstants.LEFT);
1022 showConsensLogo.setSelected(true);
1023 showConsensLogo.setText(MessageManager.getString("label.logo"));
1024 showGroupConsensus.setEnabled(false);
1025 showGroupConsensus.setFont(LABEL_FONT);
1026 showGroupConsensus.setHorizontalAlignment(SwingConstants.RIGHT);
1027 showGroupConsensus.setHorizontalTextPosition(SwingConstants.LEFT);
1028 showGroupConsensus.setSelected(true);
1029 showGroupConsensus.setText(MessageManager.getString("label.consensus"));
1030 showGroupConservation.setEnabled(false);
1031 showGroupConservation.setFont(LABEL_FONT);
1032 showGroupConservation.setHorizontalAlignment(SwingConstants.RIGHT);
1033 showGroupConservation.setHorizontalTextPosition(SwingConstants.LEFT);
1034 showGroupConservation.setSelected(true);
1035 showGroupConservation.setText(MessageManager
1036 .getString("label.conservation"));
1037 showNpTooltip.setEnabled(true);
1038 showNpTooltip.setFont(LABEL_FONT);
1039 showNpTooltip.setHorizontalAlignment(SwingConstants.RIGHT);
1040 showNpTooltip.setHorizontalTextPosition(SwingConstants.LEFT);
1041 showNpTooltip.setSelected(true);
1042 showNpTooltip.setText(MessageManager
1043 .getString("label.non_positional_features"));
1044 showDbRefTooltip.setEnabled(true);
1045 showDbRefTooltip.setFont(LABEL_FONT);
1046 showDbRefTooltip.setHorizontalAlignment(SwingConstants.RIGHT);
1047 showDbRefTooltip.setHorizontalTextPosition(SwingConstants.LEFT);
1048 showDbRefTooltip.setSelected(true);
1049 showDbRefTooltip.setText(MessageManager
1050 .getString("label.database_references"));
1051 annotations.setFont(LABEL_FONT);
1052 annotations.setHorizontalAlignment(SwingConstants.RIGHT);
1053 annotations.setHorizontalTextPosition(SwingConstants.LEADING);
1054 annotations.setSelected(true);
1055 annotations.setText(MessageManager.getString("label.show_annotations"));
1056 annotations.setBounds(new Rectangle(169, 12, 200, 23));
1057 annotations.addActionListener(new ActionListener()
1060 public void actionPerformed(ActionEvent e)
1062 annotations_actionPerformed(e);
1065 identity.addActionListener(new ActionListener()
1068 public void actionPerformed(ActionEvent e)
1070 annotations_actionPerformed(e);
1073 showGroupConsensus.addActionListener(new ActionListener()
1076 public void actionPerformed(ActionEvent e)
1078 annotations_actionPerformed(e);
1081 showUnconserved.setFont(LABEL_FONT);
1082 showUnconserved.setHorizontalAlignment(SwingConstants.RIGHT);
1083 showUnconserved.setHorizontalTextPosition(SwingConstants.LEFT);
1084 showUnconserved.setSelected(true);
1085 showUnconserved.setText(MessageManager
1086 .getString("action.show_unconserved"));
1087 showUnconserved.addActionListener(new ActionListener()
1090 public void actionPerformed(ActionEvent e)
1092 showunconserved_actionPerformed(e);
1096 // TODO these are not yet added to / action from Preferences
1097 // JCheckBox shareSelections = new JCheckBox();
1098 // shareSelections.setFont(verdana11);
1099 // shareSelections.setHorizontalAlignment(SwingConstants.RIGHT);
1100 // shareSelections.setHorizontalTextPosition(SwingConstants.LEFT);
1101 // shareSelections.setSelected(true);
1102 // shareSelections.setText(MessageManager
1103 // .getString("label.share_selection_across_views"));
1104 // JCheckBox followHighlight = new JCheckBox();
1105 // followHighlight.setFont(verdana11);
1106 // followHighlight.setHorizontalAlignment(SwingConstants.RIGHT);
1107 // followHighlight.setHorizontalTextPosition(SwingConstants.LEFT);
1108 // // showUnconserved.setBounds(new Rectangle(169, 40, 200, 23));
1109 // followHighlight.setSelected(true);
1110 // followHighlight.setText(MessageManager
1111 // .getString("label.scroll_highlighted_regions"));
1113 seqLimit.setFont(LABEL_FONT);
1114 seqLimit.setHorizontalAlignment(SwingConstants.RIGHT);
1115 seqLimit.setHorizontalTextPosition(SwingConstants.LEFT);
1116 seqLimit.setText(MessageManager.getString("label.full_sequence_id"));
1117 smoothFont.setFont(LABEL_FONT);
1118 smoothFont.setHorizontalAlignment(SwingConstants.RIGHT);
1119 smoothFont.setHorizontalTextPosition(SwingConstants.LEADING);
1120 smoothFont.setText(MessageManager.getString("label.smooth_font"));
1121 scaleProteinToCdna.setFont(LABEL_FONT);
1122 scaleProteinToCdna.setHorizontalAlignment(SwingConstants.RIGHT);
1123 scaleProteinToCdna.setHorizontalTextPosition(SwingConstants.LEADING);
1124 scaleProteinToCdna.setText(MessageManager
1125 .getString("label.scale_protein_to_cdna"));
1126 scaleProteinToCdna.setToolTipText(MessageManager
1127 .getString("label.scale_protein_to_cdna_tip"));
1128 JLabel gapLabel = new JLabel();
1129 gapLabel.setFont(LABEL_FONT);
1130 gapLabel.setHorizontalAlignment(SwingConstants.RIGHT);
1131 gapLabel.setText(MessageManager.getString("label.gap_symbol") + " ");
1132 JLabel fontLabel = new JLabel();
1133 fontLabel.setFont(LABEL_FONT);
1134 fontLabel.setHorizontalAlignment(SwingConstants.RIGHT);
1135 fontLabel.setText(MessageManager.getString("label.font"));
1136 fontSizeCB.setFont(LABEL_FONT);
1137 fontSizeCB.setBounds(new Rectangle(320, 112, 65, 23));
1138 fontStyleCB.setFont(LABEL_FONT);
1139 fontStyleCB.setBounds(new Rectangle(382, 112, 80, 23));
1140 fontNameCB.setFont(LABEL_FONT);
1141 fontNameCB.setBounds(new Rectangle(172, 112, 147, 23));
1142 gapSymbolCB.setFont(LABEL_FONT);
1143 gapSymbolCB.setBounds(new Rectangle(172, 215, 69, 23));
1144 DefaultListCellRenderer dlcr = new DefaultListCellRenderer();
1145 dlcr.setHorizontalAlignment(DefaultListCellRenderer.CENTER);
1146 gapSymbolCB.setRenderer(dlcr);
1148 startupCheckbox.setText(MessageManager.getString("action.open_file"));
1149 startupCheckbox.setFont(LABEL_FONT);
1150 startupCheckbox.setHorizontalAlignment(SwingConstants.RIGHT);
1151 startupCheckbox.setHorizontalTextPosition(SwingConstants.LEFT);
1152 startupCheckbox.setSelected(true);
1153 startupFileTextfield.setFont(LABEL_FONT);
1154 startupFileTextfield.setBounds(new Rectangle(172, 310, 330, 20));
1155 startupFileTextfield.addMouseListener(new MouseAdapter()
1158 public void mouseClicked(MouseEvent e)
1160 if (e.getClickCount() > 1)
1162 startupFileTextfield_mouseClicked();
1167 sortby.setFont(LABEL_FONT);
1168 sortby.setBounds(new Rectangle(172, 260, 155, 21));
1169 JLabel sortLabel = new JLabel();
1170 sortLabel.setFont(LABEL_FONT);
1171 sortLabel.setHorizontalAlignment(SwingConstants.RIGHT);
1172 sortLabel.setText(MessageManager.getString("label.sort_by"));
1173 sortAnnBy.setFont(LABEL_FONT);
1174 sortAnnBy.setBounds(new Rectangle(172, 285, 110, 21));
1175 JLabel sortAnnLabel = new JLabel();
1176 sortAnnLabel.setFont(LABEL_FONT);
1177 sortAnnLabel.setHorizontalAlignment(SwingConstants.RIGHT);
1178 sortAnnLabel.setText(MessageManager.getString("label.sort_ann_by"));
1179 sortAutocalc.setFont(LABEL_FONT);
1180 sortAutocalc.setBounds(new Rectangle(290, 285, 165, 21));
1182 JPanel annsettingsPanel = new JPanel();
1183 annsettingsPanel.setBounds(new Rectangle(173, 34, 320, 75));
1184 annsettingsPanel.setLayout(new FlowLayout(FlowLayout.LEFT, 0, 0));
1185 annsettingsPanel.setBorder(new EtchedBorder());
1186 visualTab.add(annsettingsPanel);
1187 Border jb = new EmptyBorder(1, 1, 4, 5);
1188 quality.setBorder(jb);
1189 conservation.setBorder(jb);
1190 identity.setBorder(jb);
1191 showConsensbits.setBorder(jb);
1192 showGroupbits.setBorder(jb);
1193 showGroupConsensus.setBorder(jb);
1194 showGroupConservation.setBorder(jb);
1195 showConsensHistogram.setBorder(jb);
1196 showConsensLogo.setBorder(jb);
1198 JPanel autoAnnotSettings = new JPanel();
1199 autoAnnotSettings.setLayout(new GridLayout(3, 3));
1200 annsettingsPanel.add(autoAnnotSettings);
1201 autoAnnotSettings.add(quality);
1202 autoAnnotSettings.add(conservation);
1203 autoAnnotSettings.add(identity);
1204 autoAnnotSettings.add(showGroupbits);
1205 autoAnnotSettings.add(showGroupConservation);
1206 autoAnnotSettings.add(showGroupConsensus);
1207 autoAnnotSettings.add(showConsensbits);
1208 autoAnnotSettings.add(showConsensHistogram);
1209 autoAnnotSettings.add(showConsensLogo);
1211 JPanel tooltipSettings = new JPanel();
1212 tooltipSettings.setBorder(new TitledBorder(MessageManager
1213 .getString("label.sequence_id_tooltip")));
1214 tooltipSettings.setBounds(173, 140, 220, 62);
1215 tooltipSettings.setLayout(new GridLayout(2, 1));
1216 tooltipSettings.add(showDbRefTooltip);
1217 tooltipSettings.add(showNpTooltip);
1218 visualTab.add(tooltipSettings);
1220 wrap.setFont(LABEL_FONT);
1221 wrap.setHorizontalAlignment(SwingConstants.TRAILING);
1222 wrap.setHorizontalTextPosition(SwingConstants.LEADING);
1223 wrap.setText(MessageManager.getString("label.wrap_alignment"));
1224 rightAlign.setFont(LABEL_FONT);
1225 rightAlign.setForeground(Color.black);
1226 rightAlign.setHorizontalAlignment(SwingConstants.RIGHT);
1227 rightAlign.setHorizontalTextPosition(SwingConstants.LEFT);
1228 rightAlign.setText(MessageManager.getString("label.right_align_ids"));
1229 idItalics.setFont(LABEL_FONT_ITALIC);
1230 idItalics.setHorizontalAlignment(SwingConstants.RIGHT);
1231 idItalics.setHorizontalTextPosition(SwingConstants.LEADING);
1232 idItalics.setText(MessageManager
1233 .getString("label.sequence_name_italics"));
1234 openoverv.setFont(LABEL_FONT);
1235 openoverv.setActionCommand(MessageManager
1236 .getString("label.open_overview"));
1237 openoverv.setHorizontalAlignment(SwingConstants.RIGHT);
1238 openoverv.setHorizontalTextPosition(SwingConstants.LEFT);
1239 openoverv.setText(MessageManager.getString("label.open_overview"));
1240 JPanel jPanel2 = new JPanel();
1241 jPanel2.setBounds(new Rectangle(7, 17, 158, 310));
1242 jPanel2.setLayout(new GridLayout(14, 1));
1243 jPanel2.add(fullScreen);
1244 jPanel2.add(openoverv);
1245 jPanel2.add(seqLimit);
1246 jPanel2.add(rightAlign);
1247 jPanel2.add(fontLabel);
1248 jPanel2.add(showUnconserved);
1249 jPanel2.add(idItalics);
1250 jPanel2.add(smoothFont);
1251 jPanel2.add(scaleProteinToCdna);
1252 jPanel2.add(gapLabel);
1254 jPanel2.add(sortLabel);
1255 jPanel2.add(sortAnnLabel);
1256 jPanel2.add(startupCheckbox);
1257 visualTab.add(jPanel2);
1258 visualTab.add(annotations);
1259 visualTab.add(startupFileTextfield);
1260 visualTab.add(sortby);
1261 visualTab.add(sortAnnBy);
1262 visualTab.add(sortAutocalc);
1263 visualTab.add(gapSymbolCB);
1264 visualTab.add(fontNameCB);
1265 visualTab.add(fontSizeCB);
1266 visualTab.add(fontStyleCB);
1270 protected void autoIdWidth_actionPerformed()
1272 // TODO Auto-generated method stub
1276 protected void userIdWidth_actionPerformed()
1278 // TODO Auto-generated method stub
1282 protected void maxColour_actionPerformed(JPanel panel)
1286 protected void minColour_actionPerformed(JPanel panel)
1290 protected void showunconserved_actionPerformed(ActionEvent e)
1292 // TODO Auto-generated method stub
1302 public void ok_actionPerformed(ActionEvent e)
1312 public void cancel_actionPerformed(ActionEvent e)
1322 public void annotations_actionPerformed(ActionEvent e)
1329 public void startupFileTextfield_mouseClicked()
1333 public void newLink_actionPerformed(ActionEvent e)
1338 public void editLink_actionPerformed(ActionEvent e)
1343 public void deleteLink_actionPerformed(ActionEvent e)
1348 public void defaultBrowser_mouseClicked(MouseEvent e)
1353 public void linkURLList_keyTyped(KeyEvent e)
1358 public void useProxy_actionPerformed()
1360 proxyServerTB.setEnabled(useProxy.isSelected());
1361 proxyPortTB.setEnabled(useProxy.isSelected());