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

Control-Click on Class Name May Return String Instance Instead Of Class Definition #3890

Closed
tbpassin opened this issue Apr 25, 2024 · 2 comments
Assignees
Milestone

Comments

@tbpassin
Copy link
Contributor

tbpassin commented Apr 25, 2024

When I CONTROL-Clicked Commands on this line:
c = leoCommands.Commands(fileName,

Leo navigated me to the following instead of the actual class definition:

    return {
        'ChapterCommandsClass': ['class ChapterController'],
        'EditCommandsClass': [
            'EditCommandsClass',
            'class Commands',
            'class LeoQtFrame',
            'class LeoBody',
        ],

IMHO, Leo should have navigated to the actual class definition line, not to the target in a quoted string. At a minimum, the target could be class Commands\s*[:(], but preferably there would be a check for surrounding quotations.

@tbpassin tbpassin added the Bug label Apr 25, 2024
@tbpassin tbpassin added this to the 6.7.9 milestone Apr 25, 2024
@edreamleo edreamleo self-assigned this May 23, 2024
@edreamleo edreamleo added Won'tFix Issues that EKR won't fix and removed First labels May 25, 2024
@edreamleo
Copy link
Member

@tbpassin This issue is too minor and too tricky to fix in any useful way. I am going to close it.

Yes, the results may not be optimal, but executing find-next (F3) or find-prev should mostly work.

The code contains this comment: re searches are more accurate, but not enough to be worth changing the user's settings. Saving and restoring the users settings is what makes #3871 so fraught.

@edreamleo edreamleo added lvl:minor Duplicate and removed Won'tFix Issues that EKR won't fix lvl:minor labels May 25, 2024
@edreamleo
Copy link
Member

@tbpassin Aha! Don't ever change search settings. See #3871 for details.

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

No branches or pull requests

2 participants