public static void disableDoubleBuffering ( Component c ) { RepaintManager currentManager = RepaintManager . currentManager ( c ) ; currentManager . setDoubleBufferingEnabled ( false ) ; }
Turn the cache off so printing will work .