-
Notifications
You must be signed in to change notification settings - Fork 239
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 built-in search in code function #1905
base: master
Are you sure you want to change the base?
Conversation
Download the artifacts for this pull request here: GUI:
CLI: |
Fix loader dialog not closing when caching is used Fix result counts Results actually sorted Only one window allowed Focus on textbox when opening
|
Did some quick tests in Visual Studio right now: Snapshots № 1 is after loading DELTARUNE Chapter 1 & 2 DEMO's data.win, № 2 is after opening the search and getting to a text box, and № 3 is after showing the search results.
Yes, you can right click and copy all, or select the ones you want to copy. You can paste it in a spreadsheet if you want
The main reason is performance, the text box lagged massively when displaying large amounts of results. Other than that, most software uses a list of some kind when doing this sort of search. Sure, maybe in a grid it repeats too much the code name, but we could add a sort of grouping by that. The full line isn't visible (although you can hover over it to see it in full), but it's probably possible to make each line individually taller and with word wrap, but perhaps that's too cluttered in a grid format. BUT, uh, I just think it looks neater. |
Oh, wow, nice! |
(cherry picked from commit 68103f4)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no full review yet.
- more gui screenshots?
- This feels like something that should be mostly implemented in the Lib, not the GUI. Mostly for resusability.
…rl+Shift+F now selects the textbox for an easy new search.
What more do you want me to show? Everything is in that window pretty much.
I don't think there's a lot that can be moved out, unless you want some sort of generic function that searches everything to be used in the CLI, but I don't know exactly how that works. If you're using the command line I imagine you'll want to extract all the code files and search there with regular tools. I think that if and when this ever needs to be reused, do the move it then. |
Description
Added a search in code option (Ctrl+Shift+F or in the Search menu) that's meant to replace the Search.csx script. It's faster to open, has that shortcut, and has all the options in one screen. Related issues: #545, #942, #1814
Caveats
There's definitely improvements to be made
Notes
Mostly copied from Search.csx
and ClickableTextOutput, so it's a little messy. Using LoaderDialog sucks, not sure if that should be improved or there should be a new loading bar inside the window itself.That rich text box should probably be a table or list or something.Searches should be cancellable. Also I'm not sure how to deal with all those threads being used, might not be 100% thread-safe.