OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: RE: [docbook-apps] profiling=hiding?


Not sure on the string quotes/Ant thing. If 'pdf' doesn't get through
and is interprested as an XPath element name, wouldn't no profiling
occur at all (everything would appear in the PDF)? All variations on the
<arg> except the one I'm using result in an error or no profiling at
all:

<arg value="profile.condition=pdf" />
<arg value="profile.condition="pdf"" />
<arg value=profile.condition=pdf />
<arg value=profile.condition="pdf" />

don't work

But
<arg value="profile.condition='pdf'" />
actually causes something to be hidden in the PDF. It's just the exact
opposite of what I think should be hidden.

I'm not sure I understand what you mean by "setting the stylesheet
parameter within your customization layer".   Do you mean setting
profile.condition in my customization layer? Doesn't the condition need
to be set in the first step when processing with profile.xsl, not in the
second step when processing with my customized stylesheet?

thanks so much for your thoughts!
cheri

-----Original Message-----
From: Bob Stayton [mailto:bobs@sagehill.net] 
Sent: Thursday, May 24, 2007 11:31 AM
To: Dennison, Cheri; docbook-apps@lists.oasis-open.org
Subject: Re: [docbook-apps] profiling=hiding?

I think perhaps your string quotes are being lost in the processing of
the <arg> element?  If 'pdf' doesn't get through to the stylesheet as a
string, then it will be interpreted as an XPath element name, which will
not match any element.  I don't know Ant well enough to know if that is
the case, though.  Setting the stylesheet parameter within your
customization layer would be a good test, though.

Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobs@sagehill.net


----- Original Message -----
From: "Dennison, Cheri" <cherid@amazon.com>
To: <docbook-apps@lists.oasis-open.org>
Sent: Thursday, May 24, 2007 10:22 AM
Subject: RE: [docbook-apps] profiling=hiding?



1. I'm assigning condition="pdf" to elements I want to appear in the
PDF.

2. I've got an ant script that does two-pass processing, first
processing the incoming XML with profile.xsl and then processing that
output with my customized stylesheet. The part that processes the
incoming XML includes this line to specify the profiling condition:
<arg value="profile.condition='pdf'"/>.


Below is the original XML corresponding to the attached PDF files
showing the results.

<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"

"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd"; []>

<chapter id="Introduction" role="topic">
<title id="Introduction.title">Introduction</title>
<para condition="pdf">This para has condition="pdf" assigned to
it.</para>
<para>This para has no condition attribute at all.</para>

<section condition="pdf">
<title>Section 1</title>
<para>This section has condition="pdf" assigned
to it.</para>
</section>

<section>
<title>Section 2</title>
<para>This section has no condition attribute at
all.</para>
</section>
</chapter>


If I turn off profiling, I get the results in no_profiling.pdf as
expected.

When I turn on profiling, everything tagged with condition="pdf"
disappears, as shown in with_profiling.pdf.

When I change the arg statment in the ant script to say:
<arg value="profile.condition='blah'"/>
I get the exact same results as in with_profiling.pdf.
So, it doesn't seem to matter what value I use for profile.condition.
Anything with a condition attribute disappears.


This seems backwards. What am I missing here?

thanks!!
cheri
-----Original Message-----
From: Ken Morse [mailto:kenneth.morse@gmail.com]
Sent: Wednesday, May 23, 2007 6:09 PM
To: docbook-apps@lists.oasis-open.org
Subject: Re: [docbook-apps] profiling=hiding?

How are you doing the profiling, Cheri?

You need to set the condition to what you want to show up -- any other
setting for that condition (including no setting at all) makes it
disappear during the profiling phase.

For example, if you have the following code:
<sect1 condition="internal">
  <title>Awesome title goes here</title>
  ...
</sect1>

Then setting condition to "internal" will keep it in the document;
setting it to "external", "fred", or anything else will exclude it from
the document. Don't forget to process the profiled version using either
Single-pass or Two-pass processing.

Ken

On 5/23/07, Dennison, Cheri <cherid@amazon.com> wrote:
> Hi,
>
> I'm using:
> *       Saxon 6.5.5
> *       Xerces 2.8.0
> *       Apache FOP 0.20.5
>
> Context:
> I just want to confirm that my experience of profiling is correct,
> because it contradicts the description of profiling in the chapter in
> Bob Stayton's book. My task is to try to control what goes in the PDF.
>
> My Results:
> -- Any element with attribute condition="anyvalue" gets hidden and
> doesn't show up in the PDF. So, the attribute is removing the element
> from the output instead of putting the element into the output. That
> seems to be the opposite of how profiling is described in the book.
> -- It doesn't matter what I set profile.condition to when I process
> the guide. Any value causes any element with a condition attribute to
> be hidden from the PDF.
>
> Does this sound right? It seems to work consistently, but it just
> doesn't work like I thought it would.
>
> Thanks so much for any thoughts you have!!
> cheri
>
> --
> Cheri Dennison / Technical Writer
> AWS Platform Group
> cherid@amazon.com
>




[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]