Mathieu Malaterre | 3 Aug 2012 12:20
Picon

docbook qandaset

Hi,

  I'd like to prepare some exercise for some presentation I will be
doing. I am looking at qandaset as it seems the most appropriate for
doing question and answer style document. However I'd like to hide the
answer when presenting the question.

I tried a simple approach using hard-break
(http://www.sagehill.net/docbookxsl/PageBreaking.html). But this fails
with:

  Error reported by XML parser: The prefix "fo" for element "fo:block"
is not bound.

I cannot add a <?hard-pagebreak?> within <qandaentry/> element.

So my question is: is there another way of doing this ?
My initial approach was to use foil (from slides), but there is not
such properties as foil.autolabel for numbering of questions.

I am generating PDF output so I cannot use:
https://lists.oasis-open.org/archives/docbook-apps/201201/msg00083.html

Thanks
--
Mathieu
Thomas Schraitle | 3 Aug 2012 13:08
Picon

Re: docbook qandaset

Hi Mathieu,

On Fri, 3 Aug 2012 12:20:32 +0200
Mathieu Malaterre <mathieu.malaterre <at> gmail.com> wrote:

>   I'd like to prepare some exercise for some presentation I will be
> doing. I am looking at qandaset as it seems the most appropriate for
> doing question and answer style document. However I'd like to hide the
> answer when presenting the question.
> 
> I tried a simple approach using hard-break
> (http://www.sagehill.net/docbookxsl/PageBreaking.html). But this fails
> with:
> 
>   Error reported by XML parser: The prefix "fo" for element "fo:block"
> is not bound.

You've forgot to add the FO namespace. Check the header of your
stylesheet:

 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns:fo="http://www.w3.org/1999/XSL/Format"
                version='1.0'>

> So my question is: is there another way of doing this ?
> My initial approach was to use foil (from slides), but there is not
> such properties as foil.autolabel for numbering of questions.
>
> I am generating PDF output so I cannot use:
> https://lists.oasis-open.org/archives/docbook-apps/201201/msg00083.html
(Continue reading)

Mathieu Malaterre | 3 Aug 2012 13:48
Picon

Re: docbook qandaset

On Fri, Aug 3, 2012 at 1:08 PM, Thomas Schraitle <tom_schr <at> web.de> wrote:
> Hi Mathieu,
>
> On Fri, 3 Aug 2012 12:20:32 +0200
> Mathieu Malaterre <mathieu.malaterre <at> gmail.com> wrote:
>
>>   I'd like to prepare some exercise for some presentation I will be
>> doing. I am looking at qandaset as it seems the most appropriate for
>> doing question and answer style document. However I'd like to hide the
>> answer when presenting the question.
>>
>> I tried a simple approach using hard-break
>> (http://www.sagehill.net/docbookxsl/PageBreaking.html). But this fails
>> with:
>>
>>   Error reported by XML parser: The prefix "fo" for element "fo:block"
>> is not bound.
>
> You've forgot to add the FO namespace. Check the header of your
> stylesheet:
>
>  <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>                 xmlns:fo="http://www.w3.org/1999/XSL/Format"
>                 version='1.0'>
>

Indeed. That fixed the issue.

>> So my question is: is there another way of doing this ?
>> My initial approach was to use foil (from slides), but there is not
(Continue reading)

Stefan Seefeld | 3 Aug 2012 14:46

Re: docbook qandaset

On 2012-08-03 07:48, Mathieu Malaterre wrote:
> I am not looking for something like:
> http://www.sagehill.net/docbookxsl/HideAnswers.html I want to be able
> to display the question on the videoproject, leave 5 min to think,
> then display the answer. I really mean 'hide' temporarily, not remove.

You may be interested in the work that Gabor Kovesdan has been doing on
DocBook Slides, as part of this year's Google Summer of Code. There, a
new 'incremental' attributed is introduced, which is then used together
with new xhtml-based output media to add items incrementally to slide
presentations. I don't know whether that attribute is used in the fo /
pdf stylesheets. I imagine that the natural way to use it there would be
to regenerate the same page, but with an item previously hidden now
being displayed.

The above DocBook Slides work is planned to be merged into mainline over
the course of the next couple of weeks.

FWIW,
        Stefan

--

-- 

      ...ich hab' noch einen Koffer in Berlin...

Gmane