Hover text for Marker in Eclipse plugin

后端 未结 2 1444
小鲜肉
小鲜肉 2021-01-06 15:22

I have a custom editor with problem markers. The markers display correctly in the "problems" view with icon, location and text, and the problem icons display corre

相关标签:
2条回答
  • 2021-01-06 15:43

    This bug in eclipse plug-in xtext proposes a patch to show a marker tooltip on hover and status line. If you look at the attached patches you could find the answers you need.

    0 讨论(0)
  • 2021-01-06 15:49

    In your class that extends org.eclipse.jface.text.source.SourceViewerConfiguration, just include the following:

    @Override
    public IAnnotationHover getAnnotationHover(ISourceViewer sourceViewer) {
        return new DefaultAnnotationHover();
    }
    

    this includes the text of all markers of a line in the hover text of the problem marker in the margins of the text editor.

    0 讨论(0)
提交回复
热议问题