public class CutAndPasteTransfer extends GCutAndPasteTransfer
{
- public CutAndPasteTransfer(boolean forImport)
- {
- super();
- for (int i = 0; i < jalview.io.FormatAdapter.formats.size(); i++) {
- formatChoice.addItem((String)jalview.io.FormatAdapter.formats.elementAt(i));
- }
-
- if(forImport)
- {
- formatLabel.setVisible(false);
- formatChoice.setVisible(false);
- textarea.setBounds(new Rectangle(9, 6, 383, 284));
- }
- }
-
- // this method is called once the user has selected an output format
- public void formatForOutput()
- {
- textarea.setFont(new Font("Monospaced", Font.PLAIN, 12));
- setLayout(new BorderLayout());
- add(scrollPane, BorderLayout.CENTER);
- remove(formatLabel);
- remove(formatChoice);
- }
-
- public String getFormat()
- {
- return formatChoice.getSelectedItem().toString();
- }
public String getText()
{
return textarea.getText();