/* (non-Javadoc)
  * @see org.eclipse.draw2d.Figure#paint(org.eclipse.draw2d.Graphics)
  */
 @Override
 public void paint(Graphics graphics) {
   int oldAntialias = graphics.getAntialias();
   if (Animation.isAnimating() && Animation.getProgress() < .9) {
     graphics.setAntialias(SWT.OFF);
   } else {
     graphics.setAntialias(antialiasing);
   }
   super.paint(graphics);
   graphics.setAntialias(oldAntialias);
 }
 private void updateRenderingHints(Graphics graphics) {
   {
     int aa = SWT.DEFAULT;
     try {
       aa = graphics.getAntialias();
     } catch (Exception e) {
       // not supported
     }
     Object aaHint;
     if (aa == SWT.ON) {
       aaHint = RenderingHints.VALUE_ANTIALIAS_ON;
     } else if (aa == SWT.OFF) {
       aaHint = RenderingHints.VALUE_ANTIALIAS_OFF;
     } else {
       aaHint = RenderingHints.VALUE_ANTIALIAS_DEFAULT;
     }
     if (transcoder.getRenderingHints().get(RenderingHints.KEY_ANTIALIASING) != aaHint) {
       transcoder.getRenderingHints().put(RenderingHints.KEY_ANTIALIASING, aaHint);
       transcoder.contentChanged();
     }
   }
   {
     int aa = SWT.DEFAULT;
     try {
       aa = graphics.getTextAntialias();
     } catch (Exception e) {
       // not supported
     }
     Object aaHint;
     if (aa == SWT.ON) {
       aaHint = RenderingHints.VALUE_TEXT_ANTIALIAS_ON;
     } else if (aa == SWT.OFF) {
       aaHint = RenderingHints.VALUE_TEXT_ANTIALIAS_OFF;
     } else {
       aaHint = RenderingHints.VALUE_TEXT_ANTIALIAS_DEFAULT;
     }
     if (transcoder.getRenderingHints().get(RenderingHints.KEY_TEXT_ANTIALIASING) != aaHint) {
       transcoder.getRenderingHints().put(RenderingHints.KEY_TEXT_ANTIALIASING, aaHint);
       transcoder.contentChanged();
     }
   }
 }