Package org.eclipse.php.internal.ui.editor

Examples of org.eclipse.php.internal.ui.editor.PHPStructuredTextViewer$StructuredDocumentToTextAdapterForPhp


  private void addMethodSignaturePreview(Composite composite) {
    Label previewLabel= new Label(composite, SWT.NONE);
    previewLabel.setText(RefactoringMessages.ExtractMethodInputPage_signature_preview);

   
    fPreviewViewer = new PHPStructuredTextViewer(composite, null, null, false, SWT.READ_ONLY | SWT.V_SCROLL | SWT.WRAP);
    fPreviewViewer.setDocument(new Document());
    //fPreviewViewer.adaptBackgroundColor(composite);
   
    StyledText textWidget = fPreviewViewer.getTextWidget();
   
View Full Code Here


        String type = TextUtilities.getContentType(document,
            getDocumentPartitioning(), pos, true);
        boolean activated = true;
        if (type != PHPPartitionTypes.PHP_DEFAULT) {
          if (fViewer instanceof PHPStructuredTextViewer) {
            PHPStructuredTextViewer phpViewer = (PHPStructuredTextViewer) fViewer;
            if (phpViewer.getViewerConfiguration() instanceof PHPStructuredTextViewerConfiguration) {
              PHPStructuredTextViewerConfiguration viewerConfiguration = (PHPStructuredTextViewerConfiguration) phpViewer
                  .getViewerConfiguration();
              IContentAssistProcessor[] processors = viewerConfiguration
                  .getProcessorMap().get(type);
              if (processors != null) {
                StringBuffer sb = new StringBuffer();
View Full Code Here

    ICompletionProposal[] res = null;

    ISourceViewer viewer = quickAssistContext.getSourceViewer();
    if (viewer instanceof PHPStructuredTextViewer) {

      PHPStructuredTextViewer textViewer = (PHPStructuredTextViewer) viewer;
      initAssistant(textViewer);

      int documentOffset = quickAssistContext.getOffset();

      IEditorPart part = fAssistant.getEditor();
View Full Code Here

  public void install(ProjectionViewer viewer) {
    Assert.isLegal(viewer != null);

    internalUninstall();

    PHPStructuredTextViewer viewer1 = (PHPStructuredTextViewer) viewer;
    ITextEditor editor = viewer1.getTextEditor();

    this.viewer = viewer1;

    Assert.isLegal(editor != null);
View Full Code Here

      IEditorPart editor = editorReference.getEditor(false);
      if (editor instanceof PHPStructuredEditor) {
        PHPStructuredEditor phpEditor = (PHPStructuredEditor) editor;
        boolean isDirty = phpEditor.isDirty();
        if (phpEditor.getTextViewer() instanceof PHPStructuredTextViewer) {
          PHPStructuredTextViewer textViewer = (PHPStructuredTextViewer) phpEditor
              .getTextViewer();
          IDocumentAdapter documentAdapter = textViewer
              .getDocumentAdapter();
          IDocument document = phpEditor.getDocument();
          String content = document.get();
          if (documentAdapter != null) {
            documentAdapter.replaceTextRange(0, content.length(),
View Full Code Here

    public void install(ProjectionViewer viewer)
    {

        internalUninstall();

        PHPStructuredTextViewer viewer1 = (PHPStructuredTextViewer) viewer;
        ITextEditor editor = viewer1.getTextEditor();

        this.viewer = viewer1;

        if (editor instanceof PHPStructuredEditor) {
View Full Code Here

TOP

Related Classes of org.eclipse.php.internal.ui.editor.PHPStructuredTextViewer$StructuredDocumentToTextAdapterForPhp

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.