// creates disk file Kyocera FS-1000 (KPDL-2)"
// before it was Kyocera FS-1000 (KPDL-2).prn"
SET PRINTER TO ( Printername )

This won't work either way, it's Windows printer name.

// creates disk file 'IP_10.0.40.30'
// before it was 'IP_10.0.40.30.prn'
SET PRINTER TO ( Portname )

This also won't work, because it's a printer port
name not a printer _share name_.

[ I'm not sure what hbwin printing is capable of
and which terminology it uses, sorry. ]

Does it implies that Harbour either prints to a "file" ( disk file )
or any standard port like 'LPT1:~LPT4:   COM1:~COM4' ?

No. You can open lots more than just disk files
and LPT/COM using FOPEN() (thus SET PRINTER), most
importantly a printer share name which usually
looks like this:

\\server\hp4600
\\192.168.3.100\myprinter

On other platforms you can similarly use real and
virtual port names, but probably someone more familiar
with these other systems could tell you more.

It will be heartening to see
SET PRINTER TO ( cPrinterNameOrPort ) based on the OS in use.

Notice what you want is line/direct printing.
Windows printers are not line printers, but GDI ones.
Not all Windows printer support direct printing,
so it would be totally misleading for Harbour core
to suggest that this could reliably work.

[ Unless Harbour would offer a total HP PCL, IBM
PPDS or ESP/P[2] emulation on these ports and convert
them to graphics and route them to the platform
dependent "GDI" printer. But that's very much off
topic for Harbour, even if it would be a cool feature. ]

So, line (or raw, or direct) printing and graphic printing
are two different things, Harbour supports the former,
latter is - like GUI - very much platform dependent, and
Harbour support for Windows is implemented in hbwin lib.

Any ideas how can I direct SET PRINTER TO ... to behave as in xHarbour
as the basic code is implemented in set.c itself.

See above, I don't think we should implement this the
xhb way, as it can create all sorts of problems, like
breaking compatibility in the first place. What if
f.e. if user wants to print to a file named "hello", but
he happens to have a Windows printer named "hello"?

See Francesco's recent mail, just get the list of

Brgds,
Viktor

_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to