I am writing a reference manual for a component(a particle system) in our game engine. There are many modules in this system. And each of them has a module type. I can write specifications for every module type by type.

However, some modules of different module types may cooperate to achieve one task. So I want to write specifications for every module "task by task".

I think that two aspects are not compatible to reside in a single rooted "chapter-section-subsection" tree-like structure. And I do not want to repeat module's specification text in two separate chapters.

To make my question more clearly I write some expected LaTeX here: (I do not know whether this example involves too much domain knowledge for you. If so I will try to write another one)

\chapter{Modules by type}
        % ...
        \tasks{Simulation, Rendering}
        % Every task tag should be linked to corresponding task section.

        % ...

        % ...
        \tasks{Simulation, Rendering}

\chapter{Modules by task}
    % ...
    % Modules with "Simulation" task tag should be listed here.

    % ...

Above code is just one of my expected ways to do the work. And this question is not confined to making that code work. I would like to hear your suggestions on multiple aspects organization.


Thank you for advices.

I try to make this question more specific here.

Suppose that I have a collection of (sub)sections(Which are "Position", "Color", "Integrator" in original statements) in one chapter.

Every section may fall in several categories(I called it "task" in original statements).

And later in another chapter I want to list above sections for every category automatically. In original question statements, I use a imaginary command called \listrelatedmodules{<category>} for this.

Generally speaking, my goal is to let every section register itself to a document-wise list. And later I can traverse this list variable to output references in that list. How to do that in LaTeX?

P.S. I am not sure whether this approach is a conventional usage of LaTeX so I asked a more general question above, to allow a different but elegant solution.

closed as off-topic by user36296, Mensch, marmot, Torbjørn T., egreg Dec 24 '17 at 1:02

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question does not fall within the scope of TeX, LaTeX or related typesetting systems as defined in the help center." – user36296, Mensch, marmot, Torbjørn T., egreg
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 3
    Welcome to SE TeX. It isn't clear to me whether your question is best served by this site or whether it is really off-topic and might be better asked elsewhere. This site is really about the technical site of TeX and friends. So if you want to do X, Y and Z, you might ask how to do those. (And the answer might be use another tool or you can't or you can or whatever.) But as you've explained it right now, your question seems to concern what X, Y and Z should be. But that's not a TeX question. Could you clarify? – cfr Mar 6 '14 at 3:15
  • 2
    This is a style question, but as it is given in terms of Latex and there might be existing Latex infrastructure and experience supporting the kind of thing the qner wants (maybe some Knuthian literate programming ideas are relevant here), I think we should allow this. – Charles Stewart Mar 6 '14 at 10:06
  • This is somehow connected to a CMS, but I know of none for LaTeX – user31729 Mar 6 '14 at 11:33

Browse other questions tagged or ask your own question.