Re: [help-texinfo] User defined sectioning numbers when using @unnumbered

2019-01-02 Thread Gavin Smith
On Wed, Jan 02, 2019 at 07:52:12PM +0100, Christopher Dimech wrote:
> The reason is that I am writing a book. Each chapter has an appendix section.
> In summary, an appendix needs to relate directly to the subject. In addition,
> I aim to have chapters only about the topics I wish to discuss.
> 
> Consequently, any License and Copyright Documents would use a different 
> numbering
> sequence different than for chapters or appendices.

I'm sorry, I don't get it.  You want to have three different numbering 
sequences in the table of contents: chapters, appendices, and other 
license and copyright documents?

> Naturally, I also have separate License and Copyright Documents sectioned as
> chapter and appendices too so I may use them as necessary in other documents
> I write.   
>
> For the @unnumbered version, I would need a way to define the sectioning 
> format
> so I can use them in different documents, but at the same time I can use the
> same @include ./license--unnumbered.texi This means that different documents 
> can have different sectioning even though they may call the same 
> ./license--unnumbered.texi

The chapter structuring commands in the included file will follow the 
numbering of the top-level file that is being included into.



Re: [help-texinfo] User defined sectioning numbers when using @unnumbered

2019-01-02 Thread Christopher Dimech
The reason is that I am writing a book. Each chapter has an appendix section.
In summary, an appendix needs to relate directly to the subject. In addition,
I aim to have chapters only about the topics I wish to discuss.

Consequently, any License and Copyright Documents would use a different 
numbering
sequence different than for chapters or appendices.

Naturally, I also have separate License and Copyright Documents sectioned as
chapter and appendices too so I may use them as necessary in other documents
I write.   
   
For the @unnumbered version, I would need a way to define the sectioning format
so I can use them in different documents, but at the same time I can use the
same @include ./license--unnumbered.texi This means that different documents 
can have different sectioning even though they may call the same 
./license--unnumbered.texi

├── freelic
│   ├── cc
│   └── gnu
│   ├── agpl--chapter.texi
│   ├── agpl--appendix.texi
│   ├── agpl--unnumbered.texi
│   ├── gfdl--chapter.texi
│   ├── gfdl--appendix.texi
│   └── gfdl--unnumbered.texi



> Sent: Wednesday, January 02, 2019 at 7:05 PM
> From: "Gavin Smith" 
> To: "Christopher Dimech" 
> Cc: help-texinfo@gnu.org
> Subject: Re: [help-texinfo] User defined sectioning numbers when using 
> @unnumbered
>
> On Wed, Jan 02, 2019 at 06:32:33PM +0100, Christopher Dimech wrote:
> > Dear Compeers,
> > 
> > I am using an @unnumbered chapter so it displays in the contents section
> > when I call @contents. Is there any way to add section numbers such as
> 
> I don't understand why you don't just use @chapter or @appendix instead 
> of @unnumbered if you want the chapter to be numbered.
> 
> > Define label--preamb, label--appldef, label--verbatim in some top level file
> 
> Possibly with
> 
> @set label--preamb 1.2.3
> 
> then refer to it with @value{label--preamb}.  However, there is a
> chance this won't work when processed with TeX.
> 
> > top--level--document.texi:
> >   @page
> >   @node license--unnumbered
> >   @unnumbered label--license License
> >   @include ./license--unnumbered.texi
> > 
> > license--unnumbered.texi:
> >   @unnumberedsec label--preamb Preamble
> >   @unnumberedsec label--appldef Applicability and Definitions
> >   @unnumberedsec label--copying Verbatim Copying
> >   @unnumberedsubsec label--cpinq Copying in Quantity
> > 
> > 
> > 
>



Re: [help-texinfo] User defined sectioning numbers when using @unnumbered

2019-01-02 Thread Gavin Smith
On Wed, Jan 02, 2019 at 06:32:33PM +0100, Christopher Dimech wrote:
> Dear Compeers,
> 
> I am using an @unnumbered chapter so it displays in the contents section
> when I call @contents. Is there any way to add section numbers such as

I don't understand why you don't just use @chapter or @appendix instead 
of @unnumbered if you want the chapter to be numbered.

> Define label--preamb, label--appldef, label--verbatim in some top level file

Possibly with

@set label--preamb 1.2.3

then refer to it with @value{label--preamb}.  However, there is a
chance this won't work when processed with TeX.

> top--level--document.texi:
>   @page
>   @node license--unnumbered
>   @unnumbered label--license License
>   @include ./license--unnumbered.texi
> 
> license--unnumbered.texi:
>   @unnumberedsec label--preamb Preamble
>   @unnumberedsec label--appldef Applicability and Definitions
>   @unnumberedsec label--copying Verbatim Copying
>   @unnumberedsubsec label--cpinq Copying in Quantity
> 
> 
> 



[help-texinfo] User defined sectioning numbers when using @unnumbered

2019-01-02 Thread Christopher Dimech
Dear Compeers,

I am using an @unnumbered chapter so it displays in the contents section
when I call @contents. Is there any way to add section numbers such as

@unnumbered 1 Preamble 
@unnumberedsec 1.1 Applicability and Definitions
@unnumberedsubsec 1.1.1 Verbatim Copying

However, rather than hardwiring the sectioning numerical sequence (e.g., 1, 
1.1, 1.1.1, ...etc),
is it possible to define some variables in another file and they then get 
replaced at the beginning
of the @unnumbered @unnumberedsec and @unnumberedsubsec names?

Define label--preamb, label--appldef, label--verbatim in some top level file

top--level--document.texi:
  @page
  @node license--unnumbered
  @unnumbered label--license License
  @include ./license--unnumbered.texi

license--unnumbered.texi:
  @unnumberedsec label--preamb Preamble
  @unnumberedsec label--appldef Applicability and Definitions
  @unnumberedsec label--copying Verbatim Copying
  @unnumberedsubsec label--cpinq Copying in Quantity