Beefy Boxes and Bandwidth Generously Provided by pair Networks
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
in thread Creating Books and Manuals with Perl by skazat

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2024-04-23 15:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found