コード例 #1
0
 public void actionPerformed(ActionEvent e) {
   float newZoom = viewerState.getZoom() * (1.0f / ZOOM_INCREMENT);
   viewerState.storeZoom(newZoom);
   pdfDecoder.setPageParameters(newZoom, viewerState.getPage(), PAGE_ROTATION);
   pdfDecoder.invalidate();
   mainFrame.repaint();
 }
コード例 #2
0
 public void actionPerformed(ActionEvent e) {
   float newZoom = viewerState.getZoom() * ZOOM_INCREMENT;
   viewerState.storeZoom(newZoom);
   // System.out.println ("setting zoom at " + newZoom);
   pdfDecoder.setPageParameters(newZoom, viewerState.getPage(), PAGE_ROTATION);
   pdfDecoder.invalidate();
   mainFrame.repaint();
 }
コード例 #3
0
 public void actionPerformed(ActionEvent e) {
   int currentPage = viewerState.getPage();
   if (currentPage < pdfDecoder.getPageCount()) {
     currentPage += 1;
     viewerState.setPage(currentPage);
     try {
       pdfDecoder.decodePage(currentPage);
       pdfDecoder.invalidate();
       mainFrame.repaint();
     } catch (Exception e1) {
       System.err.println("forward 1 page");
       e1.printStackTrace();
     }
   }
 }