Package org.eclipse.jface.text

Examples of org.eclipse.jface.text.TextViewerUndoManager$DocumentUndoListener


            fViewer.setEditable(true);
            // if we don't check upstream tracing can throw assertion exceptions
            // see bug 181914
            document.set(condition == null ? "" : condition); //$NON-NLS-1$
            fViewer.setDocument(document);
            fViewer.setUndoManager(new TextViewerUndoManager(10));
            fViewer.getUndoManager().connect(fViewer);
            fDocumentListener = new IDocumentListener() {
                @Override
                public void documentAboutToBeChanged(final DocumentEvent event) {
                }
View Full Code Here


    textViewer.getControl().setBackground(NOTE_COLOR);
    textViewer.getControl().setLayoutData(new GridData(GridData.FILL_BOTH));
    textViewer.setDocument(new Document());
    textViewer.setHyperlinkPresenter(new DefaultHyperlinkPresenter(new RGB(0, 0, 255)));
    textViewer.setHyperlinkDetectors(new IHyperlinkDetector[] { new URLHyperlinkDetector() }, SWT.MOD1);
    textViewer.setUndoManager(new TextViewerUndoManager(100));
    textViewer.setTextDoubleClickStrategy(new DefaultTextDoubleClickStrategy(), IDocument.DEFAULT_CONTENT_TYPE);
    textViewer.getDocument().addDocumentListener(new IDocumentListener() {
      public void documentAboutToBeChanged(DocumentEvent event) {
       
      }
View Full Code Here

  public IUndoManager getUndoManager(ISourceViewer sourceViewer) {
    if (fPreferenceStore == null || !fPreferenceStore.contains(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_UNDO_HISTORY_SIZE))
      return super.getUndoManager(sourceViewer);

    int undoHistorySize= fPreferenceStore.getInt(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_UNDO_HISTORY_SIZE);
    return new TextViewerUndoManager(undoHistorySize);
  }
View Full Code Here

   *
   * @param sourceViewer the source viewer to be configured by this configuration
   * @return an undo manager or <code>null</code> if no undo/redo should not be supported
   */
  public IUndoManager getUndoManager(ISourceViewer sourceViewer) {
    return new TextViewerUndoManager(25);
  }
View Full Code Here

  public WodParserCache() throws CoreException, LocateException {
    init();
  }

  protected void init() throws CoreException, LocateException {
    _undoManager = new TextViewerUndoManager(25);
    _wodEntry = new WodCacheEntry(this);
    _htmlEntry = new HtmlCacheEntry(this);
    _wooEntry = new WooCacheEntry(this);
    clearCache();
  }
View Full Code Here

  }

  private ProjectionViewer createSourceViewer(Composite parent, AnnotationModel annotationModel) {
    final CompositeRuler ruler = new CompositeRuler();
    final ProjectionViewer sv = new ProjectionViewer(parent, ruler, null, false, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
    final TextViewerUndoManager undoManager = new TextViewerUndoManager(8);
    undoManager.connect(sv);
    final GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true);
    sv.getControl().setLayoutData(gd);
    return sv;
  }
View Full Code Here

                    return getCompletionProcessor();
            }
        });*/
        fViewer.setEditable(true);
        fViewer.setDocument(document);
        final IUndoManager undoManager = new TextViewerUndoManager(100);
        fViewer.setUndoManager(undoManager);
        undoManager.connect(fViewer);

        fViewer.getTextWidget().setFont(JFaceResources.getTextFont());

        Control control = fViewer.getControl();
        GridData gd = new GridData(GridData.FILL_BOTH);
View Full Code Here

   *
   * @param sourceViewer the source viewer to be configured by this configuration
   * @return an undo manager or <code>null</code> if no undo/redo should not be supported
   */
  public IUndoManager getUndoManager(ISourceViewer sourceViewer) {
    return new TextViewerUndoManager(25);
  }
View Full Code Here

    return null;
  }
 
  public IUndoManager getUndoManager(ISourceViewer sourceViewer) {
    IPreferenceStore generalTextStore= EditorsUI.getPreferenceStore();
    return new TextViewerUndoManager( generalTextStore.getInt(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_UNDO_HISTORY_SIZE) );
  }
View Full Code Here

TOP

Related Classes of org.eclipse.jface.text.TextViewerUndoManager$DocumentUndoListener

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.