类org.eclipse.jface.text.source.AnnotationPainter源码实例Demo

下面列出了怎么用org.eclipse.jface.text.source.AnnotationPainter的API类实例代码及写法,或者点击链接到github查看源代码。

源代码1 项目: saros   文件: CustomAnnotationManager.java
/**
 * Uninstalls the custom {@link AnnotationPainter annotation painter} from the given source
 * viewer. If there is no custom annotation painter installed this method just returns.
 *
 * @param sourceViewer
 * @param redraw
 */
public void uninstallPainter(ISourceViewer sourceViewer, boolean redraw) {

  AnnotationPainter painter = installedPainters.remove(sourceViewer);

  if (painter == null) return;

  painter.deactivate(redraw);
  painter.dispose();
}
 
源代码2 项目: uima-uimaj   文件: AnnotationEditor.java
@Override
protected ISourceViewer createSourceViewer(Composite parent,
        org.eclipse.jface.text.source.IVerticalRuler ruler, int styles) {
  SourceViewer sourceViewer = new SourceViewer(parent, ruler, styles);

  sourceViewer.setEditable(false);

  mPainter = new AnnotationPainter(sourceViewer, new AnnotationAccess());

  sourceViewer.addPainter(mPainter);
  
  return sourceViewer;
}
 
 类所在包
 类方法
 同包方法