示例#1
0
 @Override
 protected void connectPartitioningToElement(IEditorInput input, IDocument document) {
   if (document instanceof IDocumentExtension3) {
     IDocumentExtension3 extension = (IDocumentExtension3) document;
     if (extension.getDocumentPartitioner(IXQueryPartitions.XQUERY_PARTITIONING) == null) {
       XQueryDocumentSetupParticipant participant = new XQueryDocumentSetupParticipant();
       participant.setup(document);
     }
   }
   if (!(input instanceof IFileEditorInput)) {
     // disable folding
     IPreferenceStore store = XQueryUI.getDefault().getPreferenceStore();
     store.setDefault(PreferenceConstants.EDITOR_FOLDING_ENABLED, false);
     store.setDefault(PreferenceConstants.EDITOR_COMMENTS_FOLDING_ENABLED, false);
   }
 }
示例#2
0
 @Override
 public ScriptTextTools getTextTools() {
   return XQueryUI.getDefault().getTextTools();
 }
示例#3
0
 @Override
 public IPreferenceStore getScriptPreferenceStore() {
   return XQueryUI.getDefault().getPreferenceStore();
 }