SupersetOdT opened a new issue, #36948:
URL: https://github.com/apache/superset/issues/36948

   ### Bug description
   
   For reports and alerts, no field offers to set the width of the PDF.
   
   <img width="468" height="845" alt="Image" 
src="https://github.com/user-attachments/assets/2e4ff22a-4b83-44fd-8eac-823c179376b9";
 />
   
   =============================================================
   
   Very strangely, the value of the width of the PDF can be fixed if it is 
previously written in "Edit Report" > "Content format" > "Send as PNG" > 
"Screenshot width"... , then by changing "Content format" to "Send as PDF"  🤔
   
   <img width="485" height="845" alt="Image" 
src="https://github.com/user-attachments/assets/6f6a8534-2916-410d-9fc2-6f03a9e55185";
 />
   
   =============================================================
   
   In the screenshot example above, my PDF is indeed output at a width of 2200 
pxl (= 776 mm *72 dpi / 25,4 mm/inch).
   (Indeed, I noticed that for a configuration set in 
"custom_superset_config.py" with "WEBDRIVER_WINDOW = {"pixel_density": 1,}" 
(which is the case in this example), all the screenshots are done at 72 dpi.)
   
   <img width="1308" height="811" alt="Image" 
src="https://github.com/user-attachments/assets/b6e3be79-499f-4e37-bb9f-1aab82f4ca1a";
 />
   
   =============================================================
   
   Moreover, given that the width of the reports must be located between 1200 
and 2400 pxl * {"pixel_density": X,} and given the 72 dpi or more of the 
screenshots, it should be noted that in the current state, it is impossible to 
generate a PDF with a width corresponding to the ISO A4, A3 or A2 format. (420 
mm = 1191 pxl). Only the widths of ISO A1 (594 mm = 1684 pxl) or even larger 
PDF formats... are possible.
   
   The solution would be to add a field "Edit Report" > "Content format" >  
"Send as PDF" > "Width in mm", where we could add the width of an ISO format 
with a resolution higher than 72 dpi (insufficient quality for A4 -> 200 or 300 
dpi would be ideal in this case).
   
   ### Screenshots/recordings
   
   _No response_
   
   ### Superset version
   
   6.0.0
   
   ### Python version
   
   3.11
   
   ### Node version
   
   18 or greater
   
   ### Browser
   
   Chrome
   
   ### Additional context
   
   _No response_
   
   ### Checklist
   
   - [ ] I have searched Superset docs and Slack and didn't find a solution to 
my problem.
   - [ ] I have searched the GitHub issue tracker and didn't find a similar bug 
report.
   - [ ] I have checked Superset's logs for errors and if I found a relevant 
Python stacktrace, I included it here as text in the "additional context" 
section.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to