Export to PDF not honouring column widths


#1

Hi,

I am trialing export to PDF for the scheduler timeline view.
Our scheduler has defined column widths, however the column widths are not be honoured in the export, as exported scheduler is stretching to fill the full width of the output page.

Is it possible to retain our defined column widths in the exported PDF?

We have trialled the setting additional_settings:{width:“content”}, however the service times out.


#2

Hello @uxplease ,

Probably the issue occurs on the scrollable timeline when the schedule takes part of the screen?

This can pass styles of the scheduler container in the header parameter of the export method:

function exp(){
  var header = `
<style>

.dhx_cal_container{
width:80% !important;
height: !important;
}
</style>

  scheduler.exportToPDF({
    name: "myscheduler.pdf",
    header: header,
  });
}

Here is a demo, where the scheduler keeps its width and columns width during export:
http://snippet.dhtmlx.com/5/65bd79fb4