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

Minor issue in TCustomSynEdit.ExecCmdCaseChange #88

Closed
MShark67 opened this issue Nov 10, 2021 · 2 comments
Closed

Minor issue in TCustomSynEdit.ExecCmdCaseChange #88

MShark67 opened this issue Nov 10, 2021 · 2 comments
Labels

Comments

@MShark67
Copy link
Contributor

Issue: The various case changing commands exit early if the caret is at the end of a word.

Fix:
procedure TCustomSynEdit.ExecCmdCaseChange has check:
if ReadOnly or (GetWordAtRowCol(CaretXY) = '') then Exit;
should just be:
if ReadOnly then Exit;

-Mark

@pyscripter
Copy link
Contributor

pyscripter commented Nov 10, 2021

Related to #51
What is your view?

@MShark67
Copy link
Contributor Author

I do think #51 is a good change, however I'd still remove the GetWord check OR add a check for SelAvail in the "if" above. Mainly the issue is that you could select some text with trailing whitespace such that the caret is between two whitespace chars. You'd still want to do the case change, even though the caret isn't on a word.

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

No branches or pull requests

2 participants