P is for Practical | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
With POD it's easy enough to add new paragraph level directives using =for and =begin/=end, but there's no way built into POD to add new X<< ... >> directives. Partly because there's only so many single letter directives to go around, and partly because POD parsers just don't support this kind of extensibility.Maybe I am just not getting what you mean, but POD is extensible in those ways and more, isn't it? For instance, Pod::Parser, unless I recall totally wrong, does not care one bit what commands or interior sequences you feed it. You get the comand name, or the letter of the sequence (and lots of other data, like delimiter used), and then it is up to you what to do with it. So whatever you want the commands to do, and whichever commands (as long as they follow normal POD standard) is totally up to you. Granted, then you can not directly use the core parsers, but let's face it. For the most part, you would need to modify or completely rewrite them anyways, since they are specialized to deal with perl docs, and lots of them do produce output that you need to modify anyways. Pod::HTML is a prime example. But yes, that would require some extra work, although I suspect most of the modules probably only take subclassing and overriding certain methods, possibly passing whatever you got on to the next level after your amendments. XML is just fine to use, of course, with one notable 'if': If you have some kind of editor that makes the tags for you, and hides them when typing. XML is humanreadable, yes, for certain values of readable... and writable raw? Ugh. I think some word processors do save their documents in XML, like AbiWord maybe? I don't recall. But that would be a great start to convert to other formats, of course. If I misunderstood you, I apologize. :) You have moved into a dark place. It is pitch black. You are likely to be eaten by a grue. In reply to Re: Re: Creating Books and Manuals with Perl
by Dog and Pony
|
|