Re: DOCBOOK-APPS: Re: scaling images in PDF but not in HTML?

2002-04-23 Thread Jirka Kosek

Steinar Bang wrote:

 So the question is: do I massage the !DOCTYPE?  Or do I try to make
 saxon use the proxy server?

The best solution is to use catalog files within your XML/SGML system.
One way how to add them to Saxon is described in
http://www.kosek.cz/xml/saxon/. Other way is to use XML resolver classes
from Norm, I didn't URL in my hand, try Google or search archives.

Jirka

-- 
-
  Jirka Kosek
  e-mail: [EMAIL PROTECTED]
  http://www.kosek.cz



Re: DOCBOOK-APPS: Re: scaling images in PDF but not in HTML?

2002-04-23 Thread Bob Stayton

On Tue, Apr 23, 2002 at 12:21:27PM +0200, Steinar Bang wrote:
  Steinar Bang [EMAIL PROTECTED]:
 
 [snip!]
  The resulting document looks good on visual inspection (ie. only the
  imageobject elements with arch=pdf are left), and _validates_
  against the DTD.
 
  But when I try to format this, using both the HTML and FO style sheets
  from DocBook-XSL 1.48, saxon loops forever.
 
 The problem is the !DOCTYPE header, created by profile.xsl:
 
 !DOCTYPE article PUBLIC -//OASIS//DTD DocBook XML V4.1.2//EN
 http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd;
 
 saxon hits the firewall when it's trying to open the DTD from the
 URL of the SYSTEM identifier.
 
 Appearently it doesn't pick up the http_proxy setting from the
 environment, or it is unable to use it.
 
 So the question is: do I massage the !DOCTYPE?  Or do I try to make
 saxon use the proxy server?

It might be easier to resolve the DTD reference locally.
You can use an XML catalog to map the PUBLIC ID 
to a local filesystem DTD, like this:

catalog xmlns=urn:oasis:names:tc:entity:xmlns:xml:catalog
  group xml:base=/usr/share/xml/ prefer=public 
   public 
 publicId=-//OASIS//DTD DocBook XML V4.1.2//EN
 uri=docbook412/docbookx.dtd/
  /group
/catalog

The group element provides the base path and the
preference for using the public id.  So this would
resolve the PUBLIC ID to the local file
/usr/share/xml/docbook412/docbookx.dtd.

You can use the Sun catalog resolver with Saxon.
That's described in Dave Pawson's FAQ:

http://www.dpawson.co.uk/docbook/catalogs.html

-- 

Bob Stayton 400 Encinal Street
Publications Architect  Santa Cruz, CA  95060
Technical Publications  voice: (831) 427-7796
Caldera International, Inc. fax:   (831) 429-1887
email: [EMAIL PROTECTED]