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

Regression in 7.8.3: double-clicking a found-result does not work properly if Word-Wrap is ON #7865

Closed
Yaron10 opened this issue Jan 18, 2020 · 5 comments
Assignees
Labels
accepted verified Issues verified to be valid and reproducible, PRs that have been tested thoroughly

Comments

@Yaron10
Copy link

Yaron10 commented Jan 18, 2020

Steps to reproduce:

Check View -> Word Wrap.
Search for a word in the current document (file A).
Switch to another tab.
Double-click a line in the Find Results window.

Result:
File A is activated, the search-term is selected but the relevant line may not be visible.
IOW, the visible lines do not change.

Probably related to 9387dcd (which is a major improvement in general).

Thank you.

@sasumner sasumner added the verified Issues verified to be valid and reproducible, PRs that have been tested thoroughly label Jan 19, 2020
@Yaron10
Copy link
Author

Yaron10 commented Jan 19, 2020

@cmeriaux,

Thank you for 9387dcd. 👍

Adding
(*_ppEditView)->_positionRestoreNeeded = false;
before
Searching::displaySectionCentered(fInfo._start, fInfo._end, *_ppEditView);
in FindReplaceDlg.cpp seems to solve the problem.

What do you think?

@cmeriaux
Copy link
Contributor

@Yaron10 Thank you for the encouragements
It seems the issue was already existing in the previous release (7.8.2): the displayed section is not centered in case of word wrap. Can you confirm ?
Could you also do a screencast please ?

@Yaron10
Copy link
Author

Yaron10 commented Jan 20, 2020

@cmeriaux,

Prior to 7.8.3 the line containing the search term is indeed not centered.
This should be investigated but it's relatively a minor issue.

In 7.8.3 the line containing the search term is not visible at all.

Open Notepad_plus.cpp (position 0, 0).
Search for pBuf->setUserReadOnly(isStarting);.
Switch to another tab.
Double-click pBuf->setUserReadOnly(isStarting); in the Find Results window.

This is prior to 7.8.3.
תמונה

And this is 7.8.3.
תמונה

@cmeriaux
Copy link
Contributor

Thanks @Yaron10 I was able to reproduce and to test with the fix you've give. Thanks
Sorry for the regression

@Yaron10
Copy link
Author

Yaron10 commented Jan 20, 2020

@cmeriaux,

Thank you for testing it and submitting the PR.
And thanks again for 9387dcd. I think it's important and useful.

@donho donho added the accepted label Jan 21, 2020
@donho donho closed this as completed in 5d1dcc1 Jan 23, 2020
alef162 pushed a commit to alef162/notepad-plus-plus that referenced this issue Oct 11, 2020
…Wrap is on

Regression: Double click a found in files result while Word-Wrap is on, if file hasn't been opened, then file will be opened but Notepad++ doesn't go to the found word position.

Fix notepad-plus-plus#7865, close notepad-plus-plus#7872
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted verified Issues verified to be valid and reproducible, PRs that have been tested thoroughly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants