Package org.eclipse.jface.text

Examples of org.eclipse.jface.text.Document


      IOCloser.perform(in, stream);
    }
  }
 
  public TextBuffer create(String content) {
    return new TextBuffer(new Document(content));
  }
View Full Code Here


    return autoEditStrategy;
  }
 
  @Override
  protected Document createDocument() {
    Document document = super.createDocument();
    DeeTextTestUtils.installDeePartitioner(document);
    return document;
  }
View Full Code Here

      IStorageEditorInput input= (IStorageEditorInput) inp;
      IStorageDocumentProvider provider= (IStorageDocumentProvider) prov;

      if (doc == null)
        if (force || fDocumentRead)
          doc= new Document();
        else
          return;

      IJobManager jobMgr= Platform.getJobManager();
View Full Code Here

    if (content == null) {
      fViewer.setInput(null);
      return;
    }

    IDocument doc= new Document(content);
    fViewer.setInput(doc);
   
    // ensure that we can scroll enough
    ensureScrollable();
View Full Code Here

   * Factory method for creating empty documents.
   * @return the newly created document
   * @since 2.1
   */
  protected IDocument createEmptyDocument() {
    return new Document();
  }
View Full Code Here

   */
  protected SourceViewer createViewer(Composite parent) {
    SourceViewer viewer= new SourceViewer(parent, null, null, false, SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL);
    SourceViewerConfiguration configuration= new SourceViewerConfiguration();
    viewer.configure(configuration);
    IDocument document= new Document();
    viewer.setDocument(document);
    return viewer;
  }
View Full Code Here

     
      IDocument document= viewer.getDocument();
      if (document != null)
        document.set(pattern);
      else {
        document= new Document(pattern);
        viewer.setDocument(document);
      }

      int nLines= document.getNumberOfLines();
      if (nLines < 5) {
View Full Code Here

        }
        return null;
      }

      private IDocument createUnprotectedCopy(IDocument document) {
        return new Document(document.get());
      }
    };

    fInitializationJob.setSystem(true);
    fInitializationJob.setPriority(Job.DECORATE);
View Full Code Here

    viewer = new ScriptSourceViewer(parent, null, null, false, SWT.BORDER | SWT.V_SCROLL
            | SWT.H_SCROLL, store);
    ScriptSourceViewerConfiguration configuration = textTools.createSourceViewerConfiguraton(store,
            (ITextEditor) null);
    viewer.configure(configuration);
    viewer.setDocument(new Document("No results available yet!"));
  }
View Full Code Here

  public void setInformation(String content) {
    if (content == null) {
      viewer.setInput(null);
      return;
    }
    IDocument doc = new Document(content);
    IDLTKUILanguageToolkit uiToolkit = DLTKUILanguageManager
            .getLanguageToolkit(RutaLanguageToolkit.getDefault().getNatureId());
    ScriptTextTools textTools = uiToolkit.getTextTools();
    if (textTools != null) {
      textTools.setupDocumentPartitioner(doc, uiToolkit.getPartitioningId());
View Full Code Here

TOP

Related Classes of org.eclipse.jface.text.Document

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.