void ensureAnnotationsLoaded() { if (!annotationsLoaded) { /*ERR.log(Level.FINE,"CES.ensureAnnotationsLoaded Enter Asynchronous" + " Time:" + System.currentTimeMillis() + " Thread:" + Thread.currentThread().getName());*/ annotationsLoaded = true; Line.Set lines = getLineSet(); for (AnnotationProvider act : Lookup.getDefault().lookupAll(AnnotationProvider.class)) { act.annotate(lines, lookup); } } }
void ensureAnnotationsLoaded() { if (!annotationsLoaded) { annotationsLoaded = true; Line.Set lines = getLineSet(); Lookup.Result result = Lookup.getDefault().lookup(new Lookup.Template(AnnotationProvider.class)); for (Iterator it = result.allInstances().iterator(); it.hasNext(); ) { AnnotationProvider act = (AnnotationProvider)it.next(); act.annotate(lines, lookup); } } }
void ensureAnnotationsLoaded() { if (!annotationsLoaded) { annotationsLoaded = true; Line.Set lines = getLineSet(); Lookup.Result result = Lookup.getDefault().lookup(new Lookup.Template(AnnotationProvider.class)); for (Iterator it = result.allInstances().iterator(); it.hasNext(); ) { AnnotationProvider act = (AnnotationProvider)it.next(); act.annotate(lines, lookup); } } }
/** Register line. */ Object readResolve() throws ObjectStreamException { // return Set.registerLine (this); //Set.registerPendingLine(this); return this.pos.getCloneableEditorSupport().getLineSet().registerLine(this); }
/** Register line. */ Object readResolve() throws ObjectStreamException { // return Set.registerLine (this); //Set.registerPendingLine(this); return this.pos.getCloneableEditorSupport().getLineSet().registerLine(this); }
/** Get the line set for all paragraphs in the document. * @return positions of all paragraphs on last save */ public Line.Set getLineSet() { CloneableEditorSupport redirect = CloneableEditorSupportRedirector.findRedirect(this); if (redirect != null) { return redirect.getLineSet(); } return updateLineSet(false); }
/** Register line. */ Object readResolve() throws ObjectStreamException { // return Set.registerLine (this); //Set.registerPendingLine(this); return this.pos.getCloneableEditorSupport().getLineSet().registerLine(this); }
@Override public void run() { javax.swing.JEditorPane[] panes = support.getOpenedPanes(); if (panes != null) { if (lineNumber >= 0 && lineNumber < support.getLineSet().getLines().size()) { support.getLineSet().getCurrent(lineNumber).show(Line.ShowOpenType.NONE, Line.ShowVisibilityType.FRONT); } org.netbeans.modules.mercurial.ui.annotate.AnnotateAction.showAnnotations(panes[0], originalFile, revision.getRevisionNumber()); } } });
public void open() { try { PositionRef pos = ed.getRange().getBegin(); int line = pos.getLine(); int column = pos.getColumn(); Line l = pos.getCloneableEditorSupport().getLineSet().getCurrent(line); l.show(Line.SHOW_GOTO, column); } catch (IOException ex) { Exceptions.printStackTrace(ex); } }
public void removeUpdate(javax.swing.event.DocumentEvent p0) { int elem = root.getElementCount (); int delta = lines - elem; lines = elem; int lineNumber = NbDocument.findLineNumber (doc, p0.getOffset ()); if (delta > 0) { struct.deleteLines ( lineNumber, delta ); } if ( support == null) return; Line.Set set = support.getLineSet (); if (!(set instanceof DocumentLine.Set)) return; // Notify lineSet there was changed range of lines. ((DocumentLine.Set)set).linesChanged(lineNumber, lineNumber+delta, p0); if (delta > 0) { // Notify Line.Set there was moved range of lines. ((DocumentLine.Set)set).linesMoved(lineNumber, elem); } }
public void insertUpdate(javax.swing.event.DocumentEvent p0) { int elem = root.getElementCount (); int delta = elem - lines; lines = elem; int lineNumber = NbDocument.findLineNumber (doc, p0.getOffset ()); if (delta > 0) { struct.insertLines ( lineNumber, delta ); } if ( support == null) return; Line.Set set = support.getLineSet (); if (!(set instanceof DocumentLine.Set)) return; // Nptify Line.Set there was changed range of lines. ((DocumentLine.Set)set).linesChanged(lineNumber, lineNumber, p0); if (delta > 0) { // Notify Line.Set there was moved range of lines. ((DocumentLine.Set)set).linesMoved(lineNumber, elem); } }
public void removeUpdate(javax.swing.event.DocumentEvent p0) { int elem = root.getElementCount (); int delta = lines - elem; lines = elem; int lineNumber = NbDocument.findLineNumber (doc, p0.getOffset ()); if (delta > 0) { struct.deleteLines ( lineNumber, delta ); } if ( support == null) return; Line.Set set = support.getLineSet (); if (!(set instanceof DocumentLine.Set)) return; // Notify lineSet there was changed range of lines. ((DocumentLine.Set)set).linesChanged(lineNumber, lineNumber+delta, p0); if (delta > 0) { // Notify Line.Set there was moved range of lines. ((DocumentLine.Set)set).linesMoved(lineNumber, elem); } }
public void insertUpdate(javax.swing.event.DocumentEvent p0) { int elem = root.getElementCount (); int delta = elem - lines; lines = elem; int lineNumber = NbDocument.findLineNumber (doc, p0.getOffset ()); if (delta > 0) { struct.insertLines ( lineNumber, delta ); } if ( support == null) return; Line.Set set = support.getLineSet (); if (!(set instanceof DocumentLine.Set)) return; // Nptify Line.Set there was changed range of lines. ((DocumentLine.Set)set).linesChanged(lineNumber, lineNumber, p0); if (delta > 0) { // Notify Line.Set there was moved range of lines. ((DocumentLine.Set)set).linesMoved(lineNumber, elem); } }
public void removeUpdate(javax.swing.event.DocumentEvent p0) { int elem = root.getElementCount(); int delta = lines - elem; lines = elem; StyledDocument doc = support.getDocument(); if (doc == null) { return; } int lineNumber = NbDocument.findLineNumber(doc, p0.getOffset()); if (delta > 0) { struct.deleteLines(lineNumber, delta); } if (support == null) { return; } Line.Set set = support.getLineSet(); if (!(set instanceof DocumentLine.Set)) { return; } // Notify lineSet there was changed range of lines. ((DocumentLine.Set) set).linesChanged(lineNumber, lineNumber + delta, p0); if (delta > 0) { // Notify Line.Set there was moved range of lines. ((DocumentLine.Set) set).linesMoved(lineNumber, elem); } }
Line.Set set = support.getLineSet();