Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a debug panel, containing sections with relevant debugging information #5954

Open
filipdutescu opened this issue Feb 12, 2023 · 9 comments
Labels
A-debug-adapter Area: Debug adapter client A-helix-term Area: Helix term improvements C-enhancement Category: Improvements

Comments

@filipdutescu
Copy link
Contributor

filipdutescu commented Feb 12, 2023

Description

Currently, it is very hard to view the values of variables and their inner fields, see all existing breakpoints, the call stack and there are no existing watches. This makes it very hard to debug any complex program, where any or all of the aforementioned items would be necessary.

Proposal

Add a configurable panel of widgets for locals, watches, call stack and breakpoints, which should be able to be placed in any of the following positions: left, top, bottom, right. Each widget should itself be placeable independently from the others, in any of those directions. Those settings should be set in the config.toml file.

Values should be expandable, using the same mechanism that the explorer will expand directories (see #5768). They and watches should also be editable, with a prompt shown beneath the statusline, prefilled with the existing value.

UI mockups

image

Updated design, by @CptPotato:
image

@filipdutescu filipdutescu added the C-enhancement Category: Improvements label Feb 12, 2023
@the-mikedavis the-mikedavis added the A-debug-adapter Area: Debug adapter client label Feb 12, 2023
@pascalkuthe pascalkuthe added the A-helix-term Area: Helix term improvements label Feb 12, 2023
@CptPotato
Copy link
Contributor

Looks really nice. I'm personally a fan of "less borders", so here's some variations:

screenshot

image

If the debug panel uses a different background, the vertical divider can be left out, too:

image

@filipdutescu
Copy link
Contributor Author

Thanks a lot for the feedback and kind words! I do really like your suggestions, especially the one with only the top separator, at the right of the title.

I did it the way I did since there is already support for that exact border right now in Helix. I thought it would make this issue even more complex to allow customisation of borders for each widget. Is this assessment correct? Ideally you would be able to choose from all styles

@CptPotato
Copy link
Contributor

I did it the way I did since there is already support for that exact border right now in Helix. I thought it would make this issue even more complex to allow customisation of borders for each widget. Is this assessment correct? Ideally you would be able to choose from all styles

I guess you're right. The style of border you chose is in line with the existing ones, so maybe it's better to stay consistent for the first attempt.

@pascalkuthe
Copy link
Member

I doubt it would actually be much harder to render this way, Rendering border like this is mostly custom code and not that complex to begin with. I also prefer the variants suggested by @CptPotato as that makes the screen less cluttered. I don't think we necesssairly need to offer customization here and instead just choose one good default look

@filipdutescu
Copy link
Contributor Author

I guess you're right. The style of border you chose is in line with the existing ones, so maybe it's better to stay consistent for the first attempt.

If you are so kind, you could open an issue precisely for this improvement and add it to the tracking issue

@pascalkuthe
Copy link
Member

I guess you're right. The style of border you chose is in line with the existing ones, so maybe it's better to stay consistent for the first attempt.

If you are so kind, you could open an issue precisely for this improvement and add it to the tracking issue

I don't think this is a separate issue and just a detail of how the panel would be styled

@filipdutescu
Copy link
Contributor Author

I doubt it would actually be much harder to render this way, Rendering border like this is mostly custom code and not that complex to begin with. I also prefer the variants suggested by @CptPotato as that makes the screen less cluttered. I don't think we necesssairly need to offer customization here and instead just choose one good default look

Then I would go for the first option @CptPotato presented, which can have the divider hidden as well, seems cleanest

@pascalkuthe
Copy link
Member

I doubt it would actually be much harder to render this way, Rendering border like this is mostly custom code and not that complex to begin with. I also prefer the variants suggested by @CptPotato as that makes the screen less cluttered. I don't think we necesssairly need to offer customization here and instead just choose one good default look

Then I would go for the first option @CptPotato presented, which can have the divider hidden as well, seems cleanest

In that case it might be nice to update the issue description with the new mockup

@filipdutescu
Copy link
Contributor Author

Will do later. I will update the tracking one as well, so there is a history of how the design changed (this way we might get even more feedback).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-debug-adapter Area: Debug adapter client A-helix-term Area: Helix term improvements C-enhancement Category: Improvements
Projects
None yet
Development

No branches or pull requests

4 participants