I have to print with a special photo printer, which allows only a
piece of paper formats:
9*13; 10*15, 13*18 , 15*20 , 15*21 and 15*23 (in cm)
(and my current paper is for 13*18 only)
I need to set the good paperId otherwise the printer will not print.
How can I get it?
I tryed to get the paperId after selecting it in the printDialog, but
I didn't manage to find how to get this information...
I thought I remembered a way to get the appropriate paper ID from the size of the paper, but I can't seem to find it right now. But perhaps just setting the paper size in the wx.PrintData (with the SetPaperSize(wx.Size) method, passing size in mm) object will do the right thing.
···
On 1/21/11 1:11 PM, joora wrote:
Hi!
I have to print with a special photo printer, which allows only a
piece of paper formats:
9*13; 10*15, 13*18 , 15*20 , 15*21 and 15*23 (in cm)
(and my current paper is for 13*18 only)
I need to set the good paperId otherwise the printer will not print.
How can I get it?
I tryed to get the paperId after selecting it in the printDialog, but
I didn't manage to find how to get this information...
Hi!
Quote: " Have you tried using wx.SetPaperSize(wx.Size()) after using
wx.SetPaperId(wxPAPER_NONE)? "
Answer:
Yes I have tried this
pd.SetPaperId(wxPAPER_NONE)
pd.SetPaperSize(wxSize(127, 178))
but same problem again, "paper size doesn't fit", I can't print...
···
___
Re: [wxPython-users] Find the good PaperId...
On 29/01/2011 7:50 PM, Robin Dunn wrote:
On 1/29/11 4:52 AM, joora wrote:
Hi!
I tried with SetPaperSize(wx.Size) but it doesn't work either.
I did not found any solution
Help me please!
Sorry, I don't know either. Try asking about it on the wx-users list.
Have you tried using wx.SetPaperSize(wx.Size()) after using
wx.SetPaperId(wxPAPER_NONE)? From the wx documents
wxPrintData::SetPaperId
*void* *SetPaperId*(*wxPaperSize*/paperId/)
Sets the paper id. This indicates the type of paper to be used. For a
mapping between paper id, paper size and string name, see
wxPrintPaperDatabase in paper.h (not yet documented).
/paperId/ can be one of:
wxPAPER_NONE, // Use specific dimensions
and
wxPageSetupDialogData::SetPaperSize
*void* *SetPaperSize*(*const wxSize& */size/)
Sets the paper size in millimetres. If a corresponding paper id is
found, it will be set in the internal wxPrintData object, otherwise the
paper size overrides the paper id.
Please ask about this on wx-users and/or create a ticket about it at trac.wxwidgets.org.
···
On 2/2/11 12:03 PM, joora wrote:
Hi!
Quote: " Have you tried using wx.SetPaperSize(wx.Size()) after using
wx.SetPaperId(wxPAPER_NONE)? "
Answer:
Yes I have tried this
pd.SetPaperId(wxPAPER_NONE)
pd.SetPaperSize(wxSize(127, 178))
but same problem again, "paper size doesn't fit", I can't print...