Skip to content
This repository was archived by the owner on Aug 3, 2024. It is now read-only.
This repository was archived by the owner on Aug 3, 2024. It is now read-only.

Add some predictable way of labeling section headers #1164

@garetxe

Description

@garetxe

In working in updating #1078 to the latest version of haddock in git HEAD, I noticed that db3725f broke the capability of adding custom anchors for sections.

I do see the reasoning for the change (particularly in light of #1054), but I was wondering if there was any way to restore some equivalent functionality: that is, having a way of generating a predictable label that points to a section in the documentation.

Perhaps one way would be, instead of ignoring anchors in section headers, use the given anchor as the section id, instead of generating some numerical id automatically. I have not attempted to implement this, so I don't know how hard it is, but I could give it a try.

(The old possibility of adding anchors to section headers is used extensively in gi-gtk, for instance. Having the code generator keep track of the numbering of the sections across module boundaries is difficult and very brittle.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions