Package cbg.editor.jedit

Examples of cbg.editor.jedit.Rule


    final boolean ignoreCase = rule.getIgnoreCase();
    type.accept(new IVisitor() {
      public void acceptSpan(Span span) {
        IToken defaultToken = token;
        if(span.hasDelegate()) {
          Rule delegateRule = mode.getRule(span.getDelegate());
          defaultToken = new DelegateToken(type, delegateRule, span.getEnd());
        }
        /* Using a PatternRule instead of a MultiLineRule because
         * PatternRule exposes the break on newline behavior. */
        PatternRule pat = new CasedPatternRule(span.getStart(), span.getEnd(),
View Full Code Here


  private void addDelegatedKeywords(PresentationReconciler reconciler) {
    Collection delegates = mode.getDelegates().keySet();
    for (Iterator rules = delegates.iterator(); rules.hasNext();) {
      String mungedName = (String)rules.next();
      Rule rule = (Rule) mode.getDelegates().get(mungedName);
      RuleBasedScanner scanner = getDelegateScanner(rule);
      DefaultDamagerRepairer dr= new DefaultDamagerRepairer(scanner);
      reconciler.setDamager(dr, mungedName);
      reconciler.setRepairer(dr, mungedName);
    }
View Full Code Here

  }

  public RuleBasedScanner getCodeScanner() {
    RuleBasedScanner scanner = new RuleBasedScanner();
    List rules = new ArrayList();
    Rule main = mode.getDefaultRuleSet();
    addWhitespaceRule(rules);

    IToken defaultToken = newToken(ColorsPreferencePage.NULL_COLOR);
    addTextSequenceRules(main, rules, defaultToken);
View Full Code Here

TOP

Related Classes of cbg.editor.jedit.Rule

Copyright © 2018 www.massapicom. 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.