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

Add a removeLines method in CppDocument #24

Closed
narnaud opened this issue Jun 19, 2024 · 0 comments · Fixed by #154
Closed

Add a removeLines method in CppDocument #24

narnaud opened this issue Jun 19, 2024 · 0 comments · Fixed by #154
Assignees
Labels
⬆️ feature New feature or request 🙋 good first issue Good for newcomers

Comments

@narnaud
Copy link
Member

narnaud commented Jun 19, 2024

We sometimes want to remove a line (most likely based on a QueryMatch).

Would be nice to have a removeLines(RangeMark) method, that removes the query as well as all comments attached to it (either // or /* */).
Also remove the comment on the same line.

Something like that:

// This should stay

RemoveThisLine(); // <- only this line

// This should be removed
RemoveThisOtherLine(); // <- this line + the comment above

RemoveAnotherLine(); // Also remove this comment
@narnaud narnaud added the ⬆️ feature New feature or request label Jun 19, 2024
@LeonMatthesKDAB LeonMatthesKDAB added the 🙋 good first issue Good for newcomers label Jul 30, 2024
smnppKDAB added a commit to smnppKDAB/knut that referenced this issue Aug 27, 2024
smnppKDAB added a commit to smnppKDAB/knut that referenced this issue Aug 27, 2024
smnppKDAB added a commit to smnppKDAB/knut that referenced this issue Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⬆️ feature New feature or request 🙋 good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants