Class SalesReportViewer
java.lang.Object
team75.model.SalesReportViewer
Open a new JavaFX window to view a given pdf given as an array of raw bytes
Use
SalesReportViewer.viewPdf(byte[] pdfBytes).-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidviewPdf(byte[] pdfBytes) Renders every page of a PDF side by side in a new Stage.
-
Constructor Details
-
SalesReportViewer
public SalesReportViewer()This class should never be initialized
-
-
Method Details
-
viewPdf
Renders every page of a PDF side by side in a new Stage. Each page is scaled to FIXED_HEIGHT px tall (preserving aspect ratio), and the window width is set to the exact sum of all page widths. No scrolling, no spacing, no padding. Must be called on the JavaFX Application Thread.- Parameters:
pdfBytes- raw bytes of a valid PDF document- Throws:
IOException- if PDFBox cannot load or render the document
-