POV-Ray : Newsgroups : povray.off-topic : Publishing : Re: Publishing Server Time
28 Jul 2024 16:24:22 EDT (-0400)
  Re: Publishing  
From: Francois Labreque
Date: 16 Jun 2014 21:07:52
Message: <539f94e8$1@news.povray.org>
Le 2014-06-16 17:25, Orchid Win7 v1 a écrit :
>>>>> DocBook is an XML standard. So - in theory - it's "trivial" to make it
>>>>> do what you want.
>>>>>
>>>>> ...in reality, I found it hellishly difficult to change even the
>>>>> tiniest
>>>>> detail about it. Perhaps it would be simpler to rewrite the XSLT from
>>>>> scratch rather than try to figure out how it works.
>>>>
>>>> Right, because RTFMing is impossible...
>>>
>>> Most things to do with XML are hard. For whatever reason, XML is
>>> absurdly overcomplicated, considering what it actually does.
>>>
>>
>> Convince your boss to buy you this:
>> http://shop.oreilly.com/product/9780596805012.do
>
> I sorely doubt that any of that book will say anything whatsoever about
> the toolchain problems I'm struggling with. It'll just be 500 pages
> about the actual DocBook markup itself - which I'm having no problem with.
>

Sorry.  Linked the wrong book.  This is the one you need.

http://www.sagehill.net/book-description.html

By the way, both books are available online for free:

http://www.docbook.org/tdg5/en/html/docbook.html
http://www.sagehill.net/docbookxsl/index.html


>> But what's so complicated about:
>>
>> <chapter>
>> <title>Lorem ipsum</title>
>> <para>dolor sit amet</para>
>> </Chapter>
>
> OK, now go re-read what I actually said.
>
> Writing the DocBook stuff itself is easy enough. (That's why I'm looking
> at it in the first place.) Configuring the DocBook XSLT stuff is
> difficult. Trying to make entities work is difficult. Trying to split
> the file into parts is difficult. All the stuff that isn't to do with
> writing the actual textual content just seems really difficult.
>
>>> It took me hours of Google searching just to figure out how to make
>>> DocBook allow me to write character entities. (The manual says it works
>>> already... Oh, wait, that's for DocBook v4. OK, so how do you make it
>>> work for v5? Oh yeah, we removed that feature. Great, so how do I turn
>>> it back on?) I got there eventually, but it was a hell of a lot of work.
>>
>> http://www.docbook.org/docs/howto/#entities
>
> This is about how to make XSLT not strip off custom entities that you
> personally have defined (e.g., your product's name). It has nothing to
> do with standard entities like  .
>

Ok.  i thought it had to do with not losing entities in a v4 doc when 
upgrading to v5.  I thought you were upgrading v4 documents to v5, not 
using a v4 book to write v5 docs.  Sorry.

>> http://www.docbook.org/docs/howto/#faq-authoring-general-entities
>
> This is the *actual* solution. Do you have *any idea* how many Google
> searches it took me to find this exact page?? (Also, why does every
> single webpage related to DocBook take five lifetimes to load?)
>

It took me one attempt.

google "docbook".
docbook.org seems promising...
Oh! they have a Documentation section...
Ah! There's a "Users migrating from v4 to v5 should read..." link.
Hey!  They even mention entities...

Sometimes Google just shows you how to fish.  It doesn't always serve 
you grilled salmon with a mango chutney.


>>> Similar fun with XInclude. The manual tells you that XInclude is a great
>>> way to make modular documents - and so much better than the old entity
>>> workaround we used to recommend you use. Except, you know what? My XML
>>> validator and my XSLT processor both POINT-BLANK INGORE any and all
>>> XInclude declarations. Isn't that wonderful?
>>
>> Upgrade?
>
> To what? I'm using the latest versions of the tools recommended from the
> DocBook website! :-P
>

So you're saying that the latest and greatest release of your tool has a 
problem with this:

   1 <book xmlns="http://docbook.org/ns/docbook"
   2       xmlns:xi="http://www.w3.org/2001/XInclude" version="5.0">
     <title>My First Book</title>
   4 <xi:include href="chap1.xml"/>
     <xi:include href="chap2.xml"/>
   6 <xi:include href="chap3.xml"/>
     <xi:include href="appa.xml"/>
   8 <xi:include href="appb.xml"/>
     </book>

(actual example from chapter 2 of the aforementioned O'RLY book)

That XInclude page is dated 2 May 2005.  I maintain my suggestion to 
upgrade to something more recent...

>>>> Your problem, is that you do not like the default CSS used by your
>>>> docbook editor, not that it can't be convinced to produce nice output.
>>>
>>> I don't have a "DocBook editor", I have a text editor with a vague
>>> understanding of XML. And then I have various command-line tools which,
>>> after about a day of research, I was able to convince to produce PDF
>>> output. Fortunately, all of this knowledge can be embedded into scripts.
>>> ;-)
>>
>> http://www.docbook.org/docs/howto/#editors
>
> OK, so... Emacs, oXygen (which is just a general XML editor) and a
> couple of other XML editors. Doesn't really offer any meaningful
> advantage over any other text editor. And really, this isn't the part
> that's causing trouble in the first place.
>

They have embedded XML validators, syntax highlighting, online help, etc...

>>> Yes, but can it render the chapter titles in a blue box with rounded
>>> corners and a fuzzy drop-shadow? Probably not.
>>
>> The fuzzy drop shadow and rounded corners are not part of the CSS
>> specification (yet!)
>
> Indeed. That's my point. A tool focused on flashy graphics will have all
> these sorts of capabilities - possibly at the expense of making it
> harder to update the content though. (I say *possibly* - I still haven't
> got to the bottom of what InDesign's actual capabilities may or may not
> be.)
>

You shouldn't have any problem updating the title of any chapter, while 
having it retain its blue box with fuzzy drop shadows.  you may, 
however, have problems keeping section numbers in order, if you start 
moving stuff around, as it looks as if people didn't know how to work 
with the document (much like most people are horrible at working with 
titles, subtitles, and bulleted lists in Word)


-- 
/*Francois Labreque*/#local a=x+y;#local b=x+a;#local c=a+b;#macro P(F//
/*    flabreque    */L)polygon{5,F,F+z,L+z,L,F pigment{rgb 9}}#end union
/*        @        */{P(0,a)P(a,b)P(b,c)P(2*a,2*b)P(2*b,b+c)P(b+c,<2,3>)
/*   gmail.com     */}camera{orthographic location<6,1.25,-6>look_at a }


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.