Examples of Caption


Examples of org.apache.uima.tools.util.gui.Caption

      southernPanel.setLayout(new BoxLayout(southernPanel, BoxLayout.Y_AXIS));

      JPanel controlsPanel = new JPanel();
      controlsPanel.setLayout(new SpringLayout());

      Caption displayFormatLabel = new Caption("Results Display Format:");
      controlsPanel.add(displayFormatLabel);

      JPanel displayFormatPanel = new JPanel();
      displayFormatPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
      displayFormatPanel.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

    southernPanel.setLayout(new BoxLayout(southernPanel, BoxLayout.Y_AXIS));

    JPanel controlsPanel = new JPanel();
    controlsPanel.setLayout(new SpringLayout());

    Caption displayFormatLabel = new Caption("Results Display Format:");
    controlsPanel.add(displayFormatLabel);

    JPanel displayFormatPanel = new JPanel();
    displayFormatPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
    displayFormatPanel.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

    southernPanel.setLayout(new BoxLayout(southernPanel, BoxLayout.Y_AXIS));

    JPanel controlsPanel = new JPanel();
    controlsPanel.setLayout(new SpringLayout());

    Caption displayFormatLabel = new Caption("Results Display Format:");
    controlsPanel.add(displayFormatLabel);

    JPanel displayFormatPanel = new JPanel();
    displayFormatPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
    displayFormatPanel.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

    menuBar.add(fileMenu);
    menuBar.add(helpMenu);

    // Labels to identify the text fields
    // final Caption labelJdbcProps = new Caption("JDBC Properties File: ");
    final Caption labelStyleMapFile = new Caption(
        "TypeSystem or AE Descriptor File: ");

    JPanel controlPanel = new JPanel();
    controlPanel.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
    controlPanel.setLayout(new SpringLayout());

    // Once we add components to controlPanel, we'll
    // call SpringUtilities::makeCompactGrid on it.

    // controlPanel.setLayout(new GridLayout(4, 2, 8, 4));

    // // Set default values for input fields

    taeDescriptorFileSelector = new FileSelector("", "TAE Descriptor File",
        JFileChooser.FILES_ONLY, uimaHomeDir);

    File descriptorFile = new File(uimaHomeDir,
        "examples/descriptors/analysis_engine/PersonTitleAnnotator.xml");
    taeDescriptorFileSelector.setSelected(descriptorFile.getAbsolutePath());
    Caption labelDocumentID = new Caption("Document ID:");
    this.documentIDField = new JTextField();

    controlPanel.add(labelStyleMapFile);
    controlPanel.add(taeDescriptorFileSelector);
    controlPanel.add(labelDocumentID);
    controlPanel.add(documentIDField);

    // ------ copied here
    Caption displayFormatLabel = new Caption("Results Display Format:");
    controlPanel.add(displayFormatLabel);

    JPanel displayFormatPanel = new JPanel();
    displayFormatPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
    displayFormatPanel.setBorder(BorderFactory
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

    helpMenu.add(helpMenuItem);
    menuBar.add(fileMenu);
    menuBar.add(helpMenu);

    // Labels to identify the text fields
    final Caption labelInputDir = new Caption("Input Directory: ");
    final Caption labelStyleMapFile = new Caption("TypeSystem or AE Descriptor File: ");

    JPanel controlPanel = new JPanel();
    controlPanel.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
    controlPanel.setLayout(new SpringLayout());
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

    menuBar.add(helpMenu);

    // setResizable(false);

    // Labels to identify the text fields
    final Caption labelInputFile;
    final Caption labelOutputFile;
    final Caption labelXmlFile;
    final Caption labelRunParameters;
    final Caption labelLanguage;
    final Caption labelEncoding;

    // Strings for the labels
    final String inputString = "Input Directory: ";
    final String outputString = "Output Directory: ";
    final String xmlString = "Location of Analysis Engine XML Descriptor: ";
    final String runParametersString = "XML Tag containing Text (optional): ";

    // Create field label captions (right-aligned JLabel):

    labelInputFile = new Caption(inputString);

    labelOutputFile = new Caption(outputString);

    labelXmlFile = new Caption(xmlString);

    labelRunParameters = new Caption(runParametersString);

    labelLanguage = new Caption("Language: ");

    labelEncoding = new Caption("Character Encoding: ");

    JPanel controlPanel = new JPanel();
    controlPanel.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
    controlPanel.setLayout(new SpringLayout());
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

      southernPanel.setLayout(new BoxLayout(southernPanel, BoxLayout.Y_AXIS));

      JPanel controlsPanel = new JPanel();
      controlsPanel.setLayout(new SpringLayout());

      Caption displayFormatLabel = new Caption("Results Display Format:");
      controlsPanel.add(displayFormatLabel);

      JPanel displayFormatPanel = new JPanel();
      displayFormatPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
      displayFormatPanel.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
View Full Code Here

Examples of org.apache.uima.tools.util.gui.Caption

    southernPanel.setLayout(new BoxLayout(southernPanel, BoxLayout.Y_AXIS));

    JPanel controlsPanel = new JPanel();
    controlsPanel.setLayout(new SpringLayout());

    Caption displayFormatLabel = new Caption("Results Display Format:");
    controlsPanel.add(displayFormatLabel);

    JPanel displayFormatPanel = new JPanel();
    displayFormatPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
    displayFormatPanel.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
View Full Code Here

Examples of org.livesub.input.Caption

    }
   
    @Override
    public void run() {
        try {
            Caption current = currentCaption.getElement();

            playTime++;

            if(playTime > subtitleList.getLast().getElement().getDisappear()) {
                stop();
            } else if (playTime >= current.getAppear() && playTime <= current.getDisappear()) {
                setText(current.getContents());
            } else if(playTime > current.getDisappear()) {
                currentCaption = currentCaption.getNext();
                setText(null);
            }
        } catch(Exception e) {
            LOG.error("SubtitleTask Error!", e);
View Full Code Here

Examples of org.livesub.input.Caption

            line = br.readLine();
        } catch (IOException ex) {
            Logger.getLogger(SrtParser.class.getName()).log(Level.SEVERE, null, ex);
        }
       
        Caption caption = null;
        int lineNumber = 0;
               
        while(line != null){
            if (line.matches("[0-9]+:[0-9]+:[0-9]+,[0-9]+\\s-->\\s[0-9]+:[0-9]+:[0-9]+,[0-9]+")) {
                long startTime = Utils.dateParseRegExp(line.split("\\s-->\\s")[0]);
                long endTime = Utils.dateParseRegExp(line.split("\\s-->\\s")[1]);
                caption = new Caption(startTime, endTime);
                caption.setNumericCounter(lineNumber);
            } else if (line.matches("[0-9]+") && caption == null) {
                lineNumber = Integer.parseInt(line);
            } else if (line.matches(".+")) {
                if (caption != null) {
                    caption.setContents(line);
                }
            } else {
                if (caption != null) {
                    subs.put(caption, caption.getNumericCounter());
                    caption = null;
                }
            }
            try {
                line = br.readLine();
            } catch (IOException ex) {
                Logger.getLogger(SrtParser.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
       
        if (caption != null) {
            subs.put(caption, caption.getNumericCounter());
        }
       
        return subs;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.