http://bugs.winehq.org/show_bug.cgi?id=4268
------- Additional Comments From michal.okresa@ifne.sk 2006-21-01 10:59 ------- Ok, so far we invested 34 hours into this problem, and this is where we are right now:
1) Problem with leading space in printer name
trace:winspool:GetDefaultPrinterW L"xerox_230,WINEPS,LPR:xerox_230" trace:winspool:GetDefaultPrinterA 0x0000000a/0x00000104:L"xerox_230" trace:winspool:OpenPrinterW (printerName: L" xerox_230", pDefault (nil)) trace:winspool:OpenPrinterW Can't find printer L" xerox_230" in registry
It looks like ISS (application we are trying to run under Wine) asks for default printer name, takes the result, adds leading space and then calls OpenPrinterW(), which fails. Nothing comes out of the printer. This looks like a bug in ISS itself, probably fixed by Windows API.
Temporary solution we used is copy of "xerox_230" registry key as " xerox_230", while preserving subkeys value. This "solves" situation, so we could proceed to next point.
Real solution is probably to do the same as Windows does (or what we believe it does), which is trim() of OpenPrinterW() parameter.
2) Missing PrinterDriverData registry key
trace:winspool:GetPrinterDataExA (0x2, "PrinterDriverData", "PPD File" (nil), (nil), 00000000, 0x406bc094) warn:winspool:GetPrinterDataExA Can't open subkey "PrinterDriverData" err:psdrv:PSDRV_FindPrinterInfo Error 2 getting PPD file name for printer ' xerox_230'
We solved it by definition of this key:
[System\CurrentControlSet\Control\Print\Printers\ xerox_230\PrinterDriverData] 1137859786 "PPD File"="/etc/cups/ppd/xerox_230.ppd"
At this point, is starts to print something, even it is not what is should be.
3) Missing PrinterDriverData\FontSubTable key
This is probably not a problem, since FontSubTable defines table of font substitions. We created the key to get rid of error message in log file.
Note that notepad application is able to print on xerox_230, so this key should not matter.
4) Ability to change printers in print dialog With Wine_20050310, it was not possible to change printer in print dialog. With latest CVS Wine (20060120), this problem is fixed.
5) Windows version emulation If Wine emulates WinNT40, dialog where you can change printer works.
If Wine emulates WinXP or Win2k version, dialog where you can change printer does not list any printers, this can be found in log:
fixme:commdlg:PrintDlgExA stub
Problem can be fixed by using native WinXP comdlg32.dll (as Detlef pointed out).
Currently, ISS is able to print, but text is missing, while lines are there. See attached missing_text.ps file (which we produced be definition of to_file printer, which generated *.ps file).
Any suggestions are greatly appreciated.