🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.prolog
Article #3230

Prolog to TeX/LaTeX

#3230
From: Arun Lakhotia
Date: Tue, 12 Apr 1988 06:03
24 lines
1508 bytes
Is anyone out there aware of any program to convert Prolog code to
TeX-pretty-print format, for printing code in paper or books?

I have a written a pl2tex myself. My work is a 'C' hack and does
reasonable work. If the code is already pretty-printed, I can LaTeX
it. I would like something that does the pretty-printing as well,
*** besides taking care of comments too**. I don't do a good job
with comments, other than having a kludge to change their fonts
as per user's wish.

In the absence of any other better work, I am ready to share my code.
It may be interfaced with emacs to provide command like
Prolog-To-Tex-region to do TeXing of code in-line a document. Or
one may TeX a whole source file into other file. This enables
including a TeXed-source-file into a document. Tie this with
`make' and you can keep your document upto-date with the code.
pl2tex uses a ~/.pl2tex startup file, which you may use
to customize the formatting.

The part of identifying a clause-head, body-goal, last-goal
and fact is a big hack, hence I am not keen on throwing the code
on the net. 

Arun
Technical Details
Message-ID: <2412@mandrill.CWRU.Edu>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!lll-winken!lll-tis!ames!pasteur!ucbvax!decvax!mandrill!arun

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!lll-winken!lll-tis!ames!pasteur!ucbvax!decvax!mandrill!arun
From: arun@mandrill (Arun Lakhotia)
Newsgroups: comp.lang.prolog
Subject: Prolog to TeX/LaTeX
Message-ID: <2412@mandrill.CWRU.Edu>
Date: 12 Apr 88 06:03:07 GMT
Sender: arun@mandrill.CWRU.Edu
Reply-To: arun@mandrill (Arun Lakhotia)
Organization: CWRU Dept of Computer Engineering and Science
Lines: 23