Module talk:TOCstyle

Alternating models on Pages
Would it be possible to program/plug in something like
 * row1,5,7,9,11,13model = c

or

for TOCs that alternate between different models on any given Page? It would save time and space. Londonjackbooks (talk) 21:35, 9 November 2015 (UTC)
 * row3to6model = H5.P
 * Good idea. I am looking into it and will get back to you. AuFCL (talk) 21:57, 9 November 2015 (UTC)
 * A few false leads but (I think!) it is all now working again with pretty much what you described above. The usual suspect at User:AuFCL/SandBox seems to be working. Beware there is a precedence:  is always overruled if   is requested; and   overrules both of them if X<=Z<=Y. Hope this makes sense. AuFCL (talk) 05:24, 10 November 2015 (UTC)
 * I forgot to add: threw in new option  as a "built-in" shortcut to centred narrow TOCs. All it does is to alter the default layout to include the   discussed elsewhere. AuFCL (talk) 05:30, 10 November 2015 (UTC)
 * Decided to round out the set with  as an alias for  . Use of both forms together is not wise (I am not quite sure but as far as I can tell LUA actually randomises parameter order—bizarre!) but unless somebody actually complains I am not going to fix this. Good to have a few actual known bugs? AuFCL (talk) 07:36, 10 November 2015 (UTC)

How to ...?
Suggestions for Page:U.S. Government Printing Office Style Manual 2008.djvu/321 please…
 * table 1. A leaderless line 6
 * table 2. This is a standard printers' format for long page number lists, apparently

I've also come across a left aligned page number column and wondered how that would be done?

Cheers, — Zoeannl (talk) 10:42, 23 August 2016 (UTC)


 * I am very much in two minds about this. Firstly you have pointed out some clear oversights (e.g. page number alignment was always planned to be flexible yet somehow has never actually been implemented as anything but hard right aligned. It probably only makes sense to allow control of this when is also specified. Perhaps a new  might be introduced?)
 * On the other hand without changing any coding choosing a simpler model set and existing other template building blocks the required effect(s) (at least for U.S.G.P.O.S.M.2008/321) can already readily be achieved as demonstrated. AuFCL (talk) 04:50, 26 August 2016 (UTC)

Annoying numbers
Hi. Thank you for creating such a useful template. We use it in our local wikisource (fa.wikisource.org). It is fully compatible. The only problem is that no matter how we use it, it will add ordinal numbers before each line. Would you please be kind and help us over there. it is a sample page: fa:برگه:Tavalludi Digar - Farogh Farrukhzad.pdf/۱۱ --Yousef (talk) 10:36, 8 June 2017 (UTC)
 * It looks like there's a CSS rule from...somewhere, I don't understand how all this stuff works anymore, which says that HTML ordered lists in Farsi pages get Farsi numbers. TOCstyle uses HTML ordered lists and tries to suppress numbering, but I think because of how CSS is applied based on the specificity of the rule the numbering rule defeats the no-numbering rule. Maybe if your TOCstyle template were modified to apply a certain class to the TOCs and a rule were added to your common.css that says that .tocclass ol:lang(fa) li { list-style-type: none; } it would work? I'm not totally sure. Prosody (talk) 23:38, 12 June 2017 (UTC)

Not displaying dots on ToC
See Page:O'Higgins--The Adventures of Detective Barney.djvu/13. Chapter one has no dots. —Justin ( koavf ) ❤T☮C☺M☯ 15:44, 26 August 2017 (UTC)
 * Observe option  which is requesting the behaviour you are complaining about. Remove same and re-observe result. QED. 121.216.218.199 22:15, 26 August 2017 (UTC)

lcr with dots inbetween
See Page:The Atlantic Monthly, Volume 18.djvu/7, the text is in 2 columns with the page numbers in a third. The only model I can see that does something similar is CD.P or lcr but these either lack the dots and spacing beteen the first two columns or lack the dots overall. -Einstein95 (talk) 22:56, 4 September 2017 (UTC)

Extraction of section of TOC
Is it possible to extract this section of the TOC for separate transclusion? Londonjackbooks (talk) 14:13, 17 October 2017 (UTC)
 * Simplistic answer is to add a &lt;section/&gt; begin/end to this page as normal (i.e. enclosing the page body) and then when trancluding lead the &lt;pages&gt; directive with a dummy (i.e. reproduce the current Page:-space construction.) 121.217.127.91 10:24, 18 October 2017 (UTC)


 * The rows render as bulleted. Londonjackbooks (talk) 11:18, 18 October 2017 (UTC)


 * The unwanted bullets may be suppressed by use of a CSS hack. Something akin to: does the trick but this will only work until next time the mediawiki parser changes characteristics. All in all this may be a lost cause (insertion of the offending &lt;UL&gt; tag SHOULD NOT HAPPEN - but nevertheless it currently does!) 101.161.12.77 04:14, 19 October 2017 (UTC)
 * Ok. Thanks for your help. Perhaps I will just re-create that portion of the TOC in the Main manually rather than transclude. Londonjackbooks (talk) 11:13, 19 October 2017 (UTC)

Hanging indented matter split between two pages
How to join two TOC pages where hanging indented text continues on to next page. Thanks, Londonjackbooks (talk) 02:17, 6 February 2018 (UTC)
 * Example here. 114.74.130.95 09:22, 10 February 2018 (UTC)
 * Thanks much. It was right in front of me, wasn't it, but I didn't see it. Londonjackbooks (talk) 11:45, 10 February 2018 (UTC)

Template:Ditto
Why does ditto refuse to behave in this template, and is there any way to fix it? Example:

Outside the template that would be:

Example 1 ... 1 2 ... 2 —Nizolan (talk) 16:22, 31 May 2019 (UTC)

Lack of dotted indented description/page # model
Hello,

I recently noticed that there is a lack of a dotted indented description-page number model for the TOC. Can we have such a template with the model ID 2H.P?

Thank you.--BlobcatsAreCool (talk) 12:45, 12 August 2019 (UTC)

Indentation after rowRmodel=c
I've noticed that after creating a centred row in a TOC that's otherwise using a CD.P model, the following two chapters are indented for some reason. See e.g. Page:Baladhuri-Hitti1916.djvu/11 and subsequent pages. Is there a fix for this? —CalendulaAsteraceae (talk) 22:53, 27 May 2021 (UTC)
 * …Never mind, I forgot that chapters are right-aligned. —CalendulaAsteraceae (talk) 23:29, 27 May 2021 (UTC)

small caps
It seems that the template small-caps is ignored in the TOC for some reason, see e. g. Page:The Game of Life.djvu/5. Can anything be done about it? -- Jan Kameníček (talk) 17:24, 30 October 2022 (UTC)