Skip to content

Go to definition (documentation) for built-in classes #78

Open

Description

@saminton

In VSCode I can use the "Go to definition" feature on any built-in class and it'll open up a .gddoc file with the documentation for it.

Image

Super useful to see the list of all methods, signals etc without having to go Godot's documentation website each time.

Using the "Go to definition" feature in Zed it'll simply open up the list of references. I'm guessing it's a fallback as the Definition is not defined 🤷. I'm not sure where VSCode is pulling the .gddoc file from but it would be great if we could have a similar feature in Zed to access the documentation without having to leave the editor.

Activity

  1. NathanLovato commented on Feb 28, 2026

    @NathanLovato
    Contributor

    Zed does not give the same kind of plug-in support at the moment, I don't think it's possible in the current state of their extension system.

  2. HolonProduction commented on Mar 22, 2026

    @HolonProduction

    The intended flow for simple LSP clients is to enable https://docs.godotengine.org/en/latest/classes/class_editorsettings.html#class-editorsettings-property-network-language-server-show-native-symbols-in-editor and view the docs in the Godot editor.

    However that is currently broken for "Go to definition" and only works with "Go to declaration".

  3. NathanLovato commented on Mar 23, 2026

    @NathanLovato
    Contributor

    Thanks for letting me know! I'll mention this in the README for users.

  4. HolonProduction commented on Mar 23, 2026

    @HolonProduction

    Maybe we could change the defaults in Godot 🤔 Would need checking whether it might behave odd with VSCode though.

  5. HolonProduction commented on Apr 27, 2026

    @HolonProduction

    So I did a bit of investigation on this in an attempt to fix it for "Go to definition". However the approach seems to not be viable for that endpoint.

    Zed prefetches the results of that endpoint as soon as one starts hovering over the identifier. So we would steal focus from Zed even when the user did not click.

    Sadly the only way forward on this, that I see, would be providing the documentation as documents to the editor. This would require textDocumentContent which is part of the unreleased LSP 3.18 version, which even VSCode does not implement as far as I'm aware. I'm not sure if there is any timeline on releasing a new protocol version.

  6. NathanLovato commented on Apr 27, 2026

    @NathanLovato
    Contributor

    Thank you very much for looking into this as always!

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions