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

Options per each tree item for including non-source files #13

Closed
ell1e opened this issue Oct 8, 2020 · 8 comments
Closed

Options per each tree item for including non-source files #13

ell1e opened this issue Oct 8, 2020 · 8 comments

Comments

@ell1e
Copy link

ell1e commented Oct 8, 2020

This is what happens when I load my executable, as you can see just main.c pops up:

Screenshot from 2020-10-08 09-31-13

This wouldn't be an issue if the tree shown to the left would actually allow me to browse the project folder for the other files. However, for some reason it doesn't, and opening them all up manually via "Load File" would take forever (since load file is unsorted as mentioned in #12 and doesn't start out in the directory I previously picked something from, making it really tedious to open up multiple files form the same folder). So some sort of "Show other files from this directory" context menu or button in the tree view to the left would really help, or alternatively a fix for whatever causes the other source files to not get detected in the first place. If you need more info for fixing that detection please tell me what you need, I'm happy to provide what I can.

@rohanrhu
Copy link
Owner

rohanrhu commented Oct 8, 2020

Hi, you can look this: https://github.com/rohanrhu/gdb-frontend#gdb-related-issues-and-tips

GDB does not give sources of linked object until stepping a line that calls a function from the linked object once. You can add break point a line and step it once, then you will see sources from linked object hereafter during the session.

@ell1e
Copy link
Author

ell1e commented Oct 8, 2020

Ah I see, that at least explains the technical side. However in my opinion that is extremely inconvenient to use, since I already know where I want to add my breakpoints so I don't want to manually step around or look up the line number in an external editor to do that. If I wanted to look up my breakpoints manually in an external text editor I could have used command line gdb to start with, the entire point of a frontend for me is to solve such inconveniences.

I suggest you just provide a way to easily expand the file tree to the left to work around this. For example, just giving the folders a context menu or a "fully expand" icon to the right of each folder entry would be useful, such that I can open the other source files immediately and set the breakpoints right in the UI.

Edit: here's a quick mockup idea:

Screenshot from 2020-10-08 09-31-13

@rohanrhu
Copy link
Owner

rohanrhu commented Oct 8, 2020

Usually, a breakpoint and stepping once a random line shows all sources. But i will look for a solution for this also.

Do you mean "Expand/Collapse All" buttons for left side?

You can also use Ctrl+P fuzzy finder.

@ell1e
Copy link
Author

ell1e commented Oct 8, 2020

I just added a quick mockup image, I hope that will help!

CTRL+P sounds useful, but sadly doesn't seem to pick up on subfolder paths inside all of the source folders. E.g. As you can see, the file /home/user/Develop/core.horse64.org/horse64/main.c is opened up. However, if I type compiler/scoperesolver.c to open up /home/user/Develop/core.horse64.org/horse64/compiler/scoperesolver.c, that entry won't be listed. I suspect it just doesn't look in that path where main.c is at, if it did that, that'd be very useful!

@rohanrhu
Copy link
Owner

rohanrhu commented Oct 8, 2020

Edit: here's a quick mockup idea:

Screenshot from 2020-10-08 09-31-13

Ok. Nice idea. A button for "list all" behaviour and I can make a "filter" setting for that. So you can set it to list only certain file types.

@ell1e
Copy link
Author

ell1e commented Oct 8, 2020

Your frontend is really good-looking by the way. Other than these small difficulties browsing the files it looks way more promising than all other frontends I have tried, which usually tend to feel really outdated and horrible to use for some reason. So I really appreciate this project.

Edit: e.g. "nemiver", the best one I've tried so far other than yours, has no "gdb" prompt at the bottom for whatever reason which is a huge downside if I can't find something in the UI, and it's also abandoned

@rohanrhu
Copy link
Owner

rohanrhu commented Oct 8, 2020

Thank you. You can also access to GDB shell with tmux a -t gdb-frontend command in terminal. (and you can use terminalless layout without /terminal/ path in URL.)

You can set that ID (gdb-frontend) with --terminal-id=ID option.

@rohanrhu rohanrhu changed the title "Load File" when picking an executable only loads one single source file, and doesn't let me browse the others in the tree Options per each tree item for including non-source files Oct 8, 2020
@rohanrhu rohanrhu added this to the v1.0 milestone Nov 15, 2020
@rohanrhu
Copy link
Owner

Hi,

I added FileBrowser opener buttons for each directory in SourceTree.

adittional-opener

I still have more feature ideas for SourceTree and planning them for v1.0.0.

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

No branches or pull requests

2 participants