@Override public IHyperlinkPresenter getHyperlinkPresenter(ISourceViewer sourceViewer) { /* When using default implementation, the following exception appears: java.lang.IllegalStateException at org.eclipse.jface.text.TextViewer.setHyperlinkPresenter(TextViewer.java:5712) at org.eclipse.jface.text.source.SourceViewer.configure(SourceViewer.java:491) at com.github.vlsi.mat.optiq.editor.OptiqPane.createPartControl(OptiqPane.java:84) at org.eclipse.mat.ui.editor.MultiPaneEditor.addPage(MultiPaneEditor.java:585) at org.eclipse.mat.ui.editor.MultiPaneEditor.addPage(MultiPaneEditor.java:574) at org.eclipse.mat.ui.editor.MultiPaneEditor.doAddNewPage(MultiPaneEditor.java:552) at org.eclipse.mat.ui.editor.MultiPaneEditor.addNewPage(MultiPaneEditor.java:535) at org.eclipse.mat.ui.editor.MultiPaneEditor.addNewPage(MultiPaneEditor.java:489) at com.github.vlsi.mat.optiq.editor.OpenOptiqAction.run(OpenOptiqAction.java:22) */ return null; }
@Override public IHyperlinkPresenter getHyperlinkPresenter(ISourceViewer sourceViewer) { /* When using default implementation, the following exception appears: java.lang.IllegalStateException at org.eclipse.jface.text.TextViewer.setHyperlinkPresenter(TextViewer.java:5712) at org.eclipse.jface.text.source.SourceViewer.configure(SourceViewer.java:491) at CalcitePane.createPartControl(CalcitePane.java:84) at org.eclipse.mat.ui.editor.MultiPaneEditor.addPage(MultiPaneEditor.java:585) at org.eclipse.mat.ui.editor.MultiPaneEditor.addPage(MultiPaneEditor.java:574) at org.eclipse.mat.ui.editor.MultiPaneEditor.doAddNewPage(MultiPaneEditor.java:552) at org.eclipse.mat.ui.editor.MultiPaneEditor.addNewPage(MultiPaneEditor.java:535) at org.eclipse.mat.ui.editor.MultiPaneEditor.addNewPage(MultiPaneEditor.java:489) at OpenCalciteAction.run(OpenCalciteAction.java:22) */ return null; }
@Override public IHyperlinkPresenter getHyperlinkPresenter(ISourceViewer sourceViewer) { return super.getHyperlinkPresenter(sourceViewer); }
public IHyperlinkPresenter getHyperlinkPresenter(ISourceViewer sourceViewer) { RGB rgb = getCurrentTheme().getForegroundAsRGB("hyperlink"); //$NON-NLS-1$ return new MultipleHyperlinkPresenter(rgb); }
public void setHyperlinkPresenter(IHyperlinkPresenter hyperlinkPresenter) throws IllegalStateException { viewer.setHyperlinkPresenter(hyperlinkPresenter); }