Re: [gcpm] custom pages and page lists

Also sprach MURAKAMI Shinyu:

 > I'd like to change the meaning of the 'auto' value:
 > 
 > If the named page list contains 'auto' value, the next element with 
 > "page: auto" doesn't establish a new page sequence.

I agree that the "auto" value in a names page list can be used as a
flag. However, I don't like that a value in place changes the meaning
of a value in another place. How about this definition:

  an 'auto' value at the end of a named page list means that the page
  sequence will continue until replaced by another page sequence or reset
  with the 'normal' keyword.

 > e.g.,
 >     table { page: rotated auto }
 > 
 >     <table>...</table>
 >     <p>This text is rendered on a rotated page.</p>
 > 
 > If the named page list has no 'auto' value, the next element with 
 > "page: auto" ends the current page sequence and starts a new page
 > sequence.

This is an excerpt from UC4. I suggest solving the use case this way: 

UC4:

  <div>
    <table>...</table>
    <table>...</table>
    <p>This text is rendered on a 'narrow' page</p>
  </div>

  @page narrow { size: 9cm 18cm }
  @page rotated { size: landscape }
  div { page: narrow }
  table { page: rotated auto }
  table + table { page: rotated }

That is, by omitting the "auto" value on the last element, the page
sequence will end the current page sequence and will revert back to
what is set on the "div" element.

Here are the other use cases written according to this proposal:

UC1:
  <div class="chapter">
    <h1>The beginning</h1>
    ....
  </div>

  <div class="chapter">
    <h1>The end</h1>
    ....
  </div>

alternative 1:

  @page chapter { 
    @top-center { content: string(title) }
  }
  @page chapter:first { 
    @top-center { content: none }
  }

  div.chapter { page: chapter }
  h1 { string-set: title content() }

alternative 2:

  @page chapter { 
    @top-center { content: string(title) }
  }
  @page chapter-start { 
    @top-center { content: none }
  }

  div.chapter { page: chapter-start chapter }
  h1 { string-set: title content() }


UC2:

  <h1>The beginning</h1>
    ....
  <h1>The end</h1>
    ....

alternative 1:

  @page chapter { 
    @top-center { content: string(title) }
  }
  @page chapter:first { 
    @top-center { content: none }
  }
  h1 { page: chapter auto;
       string-set: title content() }

alternative 2:

  @page chapter { 
    @top-center { content: string(title) }
  }
  @page chapter-start { 
    @top-center { content: none }
  }
  h1 { page: chapter-start chapter auto;
       string-set: title content() }

UC3:

  <table>...</table>

  @page rotated { size: landscape }
  table { page: rotated }

UC4:

  <div>
    <table>...</table>
    <table>...</table>
    <p>This text is rendered on a 'narrow' page</p>
  </div>


  @page narrow { size: 9cm 18cm }
  @page rotated { size: landscape }
  div { page: narrow }
  table { page: rotated auto }
  table + table { page: rotated }

--

So, it seems, that we can address all use cases without the
'page-group' property.

-h&kon
              Håkon Wium Lie                          CTO °þe®ª
howcome@opera.com                  http://people.opera.com/howcome

Received on Thursday, 21 August 2008 15:00:43 UTC