https://issues.apache.org/bugzilla/show_bug.cgi?id=48334

--- Comment #1 from Andreas L. Delmelle <adelme...@apache.org> 2011-01-16 
16:05:45 EST ---
Created an attachment (id=26496)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=26496)
prototype implementation

Attached patch adds a rough prototype implementation of xml:base by means of a
new URIProperty (+ small fotree testcase). 
Currently, in addition to xml:base, only the src property has been marked as a
URIProperty in FOPropertyMapping, but a quick glance through the spec reveals
others that might use this functionality.

Nothing really changes if it is not used, except that the value of "src" is now
validated against the URI syntax. I assume that, if an exception were to arise
there, this would normally happen further downstream anyway.
If xml:base is used, relative URIs on the element itself or its descendants
will be resolved against it.
The property is assumed to be inherited.
If it is itself specified as a relative URI, then it will be resolved against
the inherited value. If no inherited value is present, it will lead to behavior
similar to a regular relative URI.
That is, given:

<fo:block xml:base="./resources/">
  <fo:external-graphic src="images/image-1.png" />
</fo:block>

The "src" property will be resolved to "resources/images/image-1.png", which
will trigger the usual relative URI resolution downstream. It will be stored in
resolved form only. The originally specified relative URI is not retained
(although that could easily be added).

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

Reply via email to