Pyanepsion Posted September 30, 2021 Share Posted September 30, 2021 Hello everyone. The book I am working on has 20 chapters and 165 sub-chapters. According to the usual format of one line per page, the table of contents will therefore use about 9 pages (red preview on the right). I would like to reduce this number by indicating the chapter title on one line as usual, but then separating the sub-chapters by a comma (green preview on the left). Like this. How do I do this? Thank you for your explanations Quote 6 cœurs, 12 processus - Windows 11 pro - 4K - DirectX 12 - Suite universelle Affinity (Affinity Publisher, Affinity Designer, Affinity Photo). ███ Mais je vous le demande, peut-on imaginer une police sans sérifs ? Link to comment Share on other sites More sharing options...
Wosven Posted September 30, 2021 Share Posted September 30, 2021 (edited) Hello, Does regular expressions work in the TOC? If so, I would flow out of the page (to avoid adding/removing them), and use a regExp Quote Replace: ^([^\t]+)\t(.+)\n by: $1 ($2), Edited September 30, 2021 by Wosven Added missing "+" Pyanepsion 1 Quote Link to comment Share on other sites More sharing options...
walt.farrell Posted September 30, 2021 Share Posted September 30, 2021 4 hours ago, Wosven said: Does regular expressions work in the TOC? Yes, a regular expression Find/Replace will work within the TOC that you've generated. However, as we know, Find/Replace cannot be easily limited in scope. It will apply to the full document, which makes using it more difficult for this. But it should be possible if you start within the TOC and make sure not to click Replace All. For safety, I would save a copy first Also, you will need to redo the Find/Replace if you need to regenerate the TOC. Wosven 1 Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. iPad: iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1 Link to comment Share on other sites More sharing options...
Wosven Posted September 30, 2021 Share Posted September 30, 2021 2 hours ago, walt.farrell said: Also, you will need to redo the Find/Replace if you need to regenerate the TOC. Yes, but usually, TOC is done at the end (that's the way I work and explain to clients, since articles or titles can move or be modified, and automation need some fine tuning in the end). Being able to give a scope would be nice. The usual "replace/find next/replace and find next/replace all" options get all their importance compared to the few APub give. At least when needing to avoid missteps. Quote Link to comment Share on other sites More sharing options...
Old Bruce Posted September 30, 2021 Share Posted September 30, 2021 I am going to chime in here as a reader. I would much prefer the Large ToC. Perhaps have two Tables of Contents, the small then the larger more detailed one. Again, I am speaking as a reader. Anything that makes my experience of reading easier is better, a ToC with lots of space between the items is easier to read. Too often as designers we get caught up in minutia and forget about the final customers, not the people who actually hired us, but the people who will be reading / looking at / consuming the book. Occasionally it will help if we point out potential problems for the readers to our paying bosses (who may be unaware of the poor legibility of their favourite font or what ever other thing which they are obsessing over at that moment). Having said all that I do know that there are jobs that need to fit into 16 pages and there is no money in the budget for it to be 24 pages. Quote Mac Pro (Late 2013) Mac OS 12.7.4 Affinity Designer 2.4.1 | Affinity Photo 2.4.1 | Affinity Publisher 2.4.1 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
Pyanepsion Posted September 30, 2021 Author Share Posted September 30, 2021 I was hoping that there would be the possibility to set up the sequences of the table of contents. For the Regex tag, I would have written instead: ^([^\t]+)\t(.{1,})\n then , \n Be careful not to Replace all, otherwise the last item in the series will end with Quote item 19 (32), Usual table of content Wosven 1 Quote 6 cœurs, 12 processus - Windows 11 pro - 4K - DirectX 12 - Suite universelle Affinity (Affinity Publisher, Affinity Designer, Affinity Photo). ███ Mais je vous le demande, peut-on imaginer une police sans sérifs ? Link to comment Share on other sites More sharing options...
Wosven Posted September 30, 2021 Share Posted September 30, 2021 Oups, my expression missed a "+", no need to write "{1,}", it's the same meaning with less characters! Pyanepsion 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.