I have a problem in printing right to left in my application. I use the codejock report control; it prints the left to right view very well and this is an example:
When the layout is rtl the control renders very well on the screen and also the print preview is fine, but printing results in a distorted document like the following:
I have tried to override the OnPrepareDC of the view and used the pDC->SetLayout(LAYOUT_RTL) but it failed, I need help on how to fix this.
Actually I have found a solution for RTL printing issue.
the reason of the problem is that not all the printer's drivers support mirroring so calling the SetLayout(RTL) function on the printer's DC will not work in all printer's drivers.
The first step is not to call SetLayout(RTL) at all, then you should override drawing methods in report paint manager class to set the alignment of each drawing rectangle when you are in RTL printing mode.