Package javax.swing

Examples of javax.swing.JTextPane.addKeyListener()


    // create components for query input with syntax highlighting...
    final LuposDocument document = new LuposDocument();
    final JTextPane tp_query = new LuposJTextPane(document);
    document.init(SPARQLParser.createILuposParser(new LuposDocumentReader(document)), false, 100);

    tp_query.addKeyListener(this.getKeyListener(frame));
    tp_query.setFont(new Font("Courier New", Font.PLAIN, 12));
    tp_query.setPreferredSize(new Dimension(794, 200));
    tp_query.setText("PREFIX dc:      <http://purl.org/dc/elements/1.1/>\nPREFIX dcterms: <http://purl.org/dc/terms/>\n\nSELECT DISTINCT ?author ?yr\nWHERE {\n  ?doc1 dc:author ?author.\n  ?doc1 dc:ref ?doc2.\n  ?doc2 dc:ref ?doc3.\n  ?doc3 dc:ref ?doc1.\n  OPTIONAL {\n    ?doc1 dcterms:issued ?yr. FILTER(?yr < 1950)\n  }\n}\nORDER BY ASC(?author)");

    new LinePainter(tp_query, new Color(202, 223, 245));
View Full Code Here


          LuposDocument document = new LuposDocument();
          final JTextPane tp = new LuposJTextPane(document);
          document.init(JavaScanner.createILuposParser(new LuposDocumentReader(document)), true);

          tp.addKeyListener(parent.visualEditor.getKeyListener(frame));
          tp.setFont(new Font("Courier New", Font.PLAIN, 12));
          tp.setText(operator.getConditions());

          // create OK button, which starts query evaluation...
          JButton bt_ok = new JButton("OK");
View Full Code Here

    } catch (InvocationTargetException e) {
      System.err.println(e);
      e.printStackTrace();
    }
   
    tp.addKeyListener(this.getKeyListener(frame));
    tp.setFont(new Font("Courier New", Font.PLAIN, 12));
    tp.setEditable(false);
    tp.setText(text);

    new LinePainter(tp, new Color(202, 223, 245));
View Full Code Here

    final LuposDocument document = new LuposDocument();
    final JTextPane tp = new LuposJTextPane(document);
    document.init((query_or_n3) ? SPARQLParser.createILuposParser(new LuposDocumentReader(document)):TurtleParser.createILuposParser(new LuposDocumentReader(document)), false);

    tp.addKeyListener(this.getKeyListener(dialog));
    tp.setFont(new Font("Courier New", Font.PLAIN, 12));
    tp.setEditable(false);
    tp.setText(text);

    new LinePainter(tp, new Color(202, 223, 245));
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.