Opened 16 years ago
Closed 15 years ago
#4907 closed defect (fixed)
Mixing Trac headlines and numbered headlines yields strange results
Reported by: | Owned by: | Martin Scharrer | |
---|---|---|---|
Priority: | normal | Component: | NumberedHeadlinesPlugin |
Severity: | minor | Keywords: | |
Cc: | Ryan J Ollos | Trac Release: | 0.11 |
Description
When I want to use the first level Trac headline (=) as an unnumbered Title for the wiki page and then start numbered headings in the second level (##), skipping the first level (#), then The numbering of the second-level headlines starts with 0.1.
I would rather suspect the second level to sense that there is no upper-level numbering and start the numbering in the first level that uses the numbering, so the headline descrbes above would be numbered as 1. Lorem ipsum
Usually in a document I want the main title to be unnumbered. In OOo for example there is a seperate format "Title" which we don't have here.
Maybe it would be intersting anyways to allow users to influence the numbering via arguments to the plugin (like specifying the id). One could add a feature to re-start the numbering at any point, or to override the depth level to use.
In my case, this could look like
= Document Title = ## First numbered heading ##start=1,depth=1
Attachments (0)
Change History (5)
comment:1 Changed 15 years ago by
Cc: | ryano@… added; anonymous removed |
---|
comment:2 Changed 15 years ago by
Cc: | Ryan J Ollos added; ryano@… removed |
---|
comment:3 Changed 15 years ago by
comment:4 Changed 15 years ago by
Status: | new → assigned |
---|
Our idea of user settings looks good, but will require much more work. In the meanwhile use revision [6853] or later with numbering_starts_at_level_two = true
in the config file.
See NumberedHeadlinesPlugin#Configuration.
It changes the behavior globally so that the following wiki text:
= Document Title = ## First numbered heading ## ### sub ### # Another title-like headline, unnumbered but resets numbers # ## Headline ## ### sub ### = Another title-like headline, unnumbered and does not reset numbers = ## Headline ## ### sub ###
becomes equivalent to:
<h1> Document Title </h1> <h2> 1. First numbered heading </h2> <h3> 1.1. sub </h3> <h1> Another title-like headline, unnumbered but resets numbers </h1> <h2> 1. Headline </h2> <h3> 1.1. sub </h3> <h1> Another title-like headline, unnumbered and does not reset numbers </h1> <h2> 2. Headline </h2> <h3> 2.1. sub </h3>
Displayed as HTML:
Document Title
1. First numbered heading
1.1. sub
Another title-like headline, unnumbered but resets numbers
1. Headline
1.1. sub
Another title-like headline, unnumbered and does not reset numbers
2. Headline
2.1. sub
comment:5 Changed 15 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
As of [6856] there is the support to set headline numbers manually. Also leading zeros are ignored. This should resolve this ticket.
(In [6853]) Added option for
numbering_starts_at_level_two
. See #4907.