Skip to content

Minimap and Syntaxes - A means of distinguishing between code folding and region markers/headers #213275

Closed as not planned

Description

@sancarn

#190759 added headers wherever there is a region. Correct me if I'm wrong, but regions are also the only way to define code-folding.

As a result some language extensions which have enabled regions on loops (for collapsability) now have minimap markers, making the map look quite cluttered:

image

Might be worth being able to distinguish in syntax between regions for folding, and markers for minimap.

Activity

  1. added
    feature-request
    editor-minimap
    on Jun 3, 2024
  2. vscodenpa commented on Jun 3, 2024

    @vscodenpa

    This feature request is now a candidate for our backlog. The community has 60 days to upvote the issue. If it receives 20 upvotes we will move it to our backlog. If not, we will close it. To learn more about how we handle feature requests, please see our documentation.

    Happy Coding!

  3. spartanatreyu commented on Jun 5, 2024

    @spartanatreyu

    Aren't regions supposed to be manually defined by the programmer and not by an extension?

  4. sancarn commented on Jun 5, 2024

    @sancarn
    Author

    That may well have been the intention but currently the following:

        "folding": {
            "markers": {
                "start": "^\\s*(Private|Protected|Friend|Public|Sub|Function|If|While|Do|For|Loop)\\b",
                "end": "^\\s*(End|Next|Wend)\\b"
            }
        },

    is adding to the minimap, where I imagine it really shouldn't be...

  5. ian-h-chamberlain commented on Jul 1, 2024

    @ian-h-chamberlain

    I think related to this are #219561 and #209904 — since the section headers are defined by the language configuration, perhaps customizing the tags would be sufficient to workaround this, if the editor.minimap.sectionHeaderDetectionRegExp regex didn't match?

    Even if that feature is accepted, it does seem like there should be a way to control the different header types:

    • MARK: (now: hardcoded, possible future: sectionHeaderDetectionRegExp matches)
    • folding.markers in language-configuration.json. This seems to affect some languages more than others, maybe due to some other regex matching?
  6. vs-code-engineering commented on Jul 24, 2024

    @vs-code-engineering
    Contributor

    This feature request has not yet received the 20 community upvotes it takes to make to our backlog. 10 days to go. To learn more about how we handle feature requests, please see our documentation.

    Happy Coding!

  7. sancarn commented on Jul 24, 2024

    @sancarn
    Author

    I think related to this are #219561 and #209904 — since the section headers are defined by the language configuration, perhaps customizing the tags would be sufficient to workaround this, if the editor.minimap.sectionHeaderDetectionRegExp regex didn't match?

    Even if that feature is accepted, it does seem like there should be a way to control the different header types:

    • MARK: (now: hardcoded, possible future: sectionHeaderDetectionRegExp matches)
    • folding.markers in language-configuration.json. This seems to affect some languages more than others, maybe due to some other regex matching?

    Yeah I think you're right, thanks for the headsup :)

  8. vs-code-engineering commented on Aug 20, 2024

    @vs-code-engineering
    Contributor

    🙁 In the last 60 days, this feature request has received less than 20 community upvotes and we closed it. Still a big Thank You to you for taking the time to create this issue! To learn more about how we handle feature requests, please see our documentation.

    Happy Coding!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    editor-minimapfeature-request

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions