Program listings and PASAT

Jim Henry asked: I am trying to prepare an application for EFS that has a small section with data structures included. I need to be able to put the statements on separate lines so the listings are intelligible. It seems that manual line breaks don't work in EFS applications. I tried including it as a program listing but then it seems that there are no line breaks at all, not even for hard paragraphs! Am I doing something wrong? How can I include text with controlled line breaks and without paragraph numbers?

Carl Oppedahl responded: I would be very, very cautious with this PASAT work. (You didn't say, but I am guessing you are using PASAT.)

The last time I tried to include a program listing, some of the characters in the program listing somehow appeared to PASAT to be XML tags, which of course did not match pairwise the way XML tags are supposed to match. It led to parsing errors in the claims, and I never got that application to work in PASAT. I had to give up and file it on paper. Of course if PASAT were well designed, it would "quote" everything the program listing so that it would not be interpreted as XML tags.

Anyway, not that it helps, but when I was struggling with PASAT for my application that had a program listing, the line breaks *did* work. I don't know why they worked for me and not for you.

Benjamin Lee responded: Yes, I think I noticed this a while back. Unfortunately, PASAT doesn't really offer any good flexibility for handling this issue. The only way of handling a short snippet of code like that in PASAT is to include it as a tiff image. You can take the code in Word or something like that and save it as a tiff image that you include in PASAT.

Unfortunately, this is the only way of handling equations as well, even though the xml template provided by the PTO actually supports rudimentary mathml.

FYI, there is another way of handling your situation that requires getting your hands dirty with xml. There is an xml tag specified for handling this exact sort of specification issue that PASAT apparently does not recognize. It is the <program-listing> tag. This tag is normally used for the program listing deposit tags that show up in the specification, but it turns out that they can also be used for a paragraph in the detailed description.

So, all you have to do is pull up the specification in a regular text editor (even notepad will do) and search for the location of where you want to put the code excerpt. Then insert the following tags:

<program-listing id="code1">

...

</program-listing>

The id tag "code1" can be any text or numbers, as long as they don't overlap with any other xml tags. Then insert the program code in between the tags, with returns and tags. The returns and tabs should now show up in the specification.

One major hiccup if you do things this way: make sure that the code does not carry any special xml characters, i.e. a "<" or ">" (unfortunately, which code often does). You will need to translate these into xml readable characters using a global replace in the code only. You should replace these with &lt; and &gt; respectively for the code to come out right. Otherwise, you will get massive validation errors as it thinks the < or > represent the beginning and end of an xml tag.

By the way, my comments for Jim were directed to the situation of including a short program listing directly in the detailed description or any other part of the written specification.

As Carl pointed out, PASAT does allow you to put a program listing as a deposit in the spec also, but it is buggy to the point of being unusable.