Previous Thread
Next Thread
Print Thread
GDI on Linux #37282 17 Apr 24 05:36 PM
Joined: Jun 2001
Posts: 11,794
J
Jack McGregor Offline OP
Member
OP Offline
Member
J
Joined: Jun 2001
Posts: 11,794
This question pops up every few years -- how to process an A-Shell GDI file (with embedded commands like //RECTANGLE, //SETFONT, etc.) under LInux.

I'm not sure there's ever been a really good answer but thought it might be worth checking to see what ideas others may have. The latest query into the subject comes with the objective of producing a PDF file that can be delivered to a browser client.

Basically, the two traditional GDI-in-Linux options I'm familiar with are:
  • Print the file to the AUXLOC: printer to let ATE process it
  • Set up a standalone Windows "print server" on the network, send the file to it, probably using ASHLPR.


The first one is out of the question for the browser environment. The second one is at best, very complex in the web service environment, since the CGI process would need to wait around for the printer server to act, would have very little way to detect errors, would require a shared network directory, etc.

It may be possible to install PDFX directly on the web server, slightly simplifying the "print server" scenario, but it's still pretty sketchy. And weird, if even allowed, for a web server to allow printing.

Another theoretical possibility would be some kind of converter that reads in GDI files and spits out something that can be converted more directly to PDF under Linux (LaTex, ghostscript, etc.) The main hurdle there is the difficulty of perfectly translating the GDI directives and plain text into the necessary equivalent of the target idiom. For any one project, it would make more sense to just modify the application to output, say, LaTex or ghostscript compatible files directly.

Re: GDI on Linux [Re: Jack McGregor] #37283 17 Apr 24 08:14 PM
Joined: Nov 2006
Posts: 2,223
S
Stephen Funkhouser Offline
Member
Offline
Member
S
Joined: Nov 2006
Posts: 2,223
Have you researched using WINE for Linux to support this?


Stephen Funkhouser
Diversified Data Solutions
Re: GDI on Linux [Re: Jack McGregor] #37284 17 Apr 24 09:54 PM
Joined: Jun 2001
Posts: 11,794
J
Jack McGregor Offline OP
Member
OP Offline
Member
J
Joined: Jun 2001
Posts: 11,794
I haven’t actually tried it but have my doubts. First, it requires not just any device context but specifically a printer driver. And in the case of PDF, our implementation requires ActivX, which I am led to believe is not really supported. The PDFX driver is also rather finicky about wanting a user (rather than server) context.


Moderated by  Jack McGregor, Ty Griffin 

Powered by UBB.threads™ PHP Forum Software 7.7.3