Bug 140004 - Allow commenting out or disabling of code blocks in BASIC IDE
Summary: Allow commenting out or disabling of code blocks in BASIC IDE
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: BASIC (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium enhancement
Assignee: Rafael Lima
URL:
Whiteboard: target:24.8.0 inReleaseNotes:24.8
Keywords:
Depends on:
Blocks: BASIC-IDE
  Show dependency treegraph
 
Reported: 2021-01-29 16:05 UTC by info
Modified: 2024-06-04 13:43 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description info 2021-01-29 16:05:26 UTC
BASIC urgently needs a way to comment out code blocks. This is essential for convenient coding and debugging. I would suggest C-style /* ... */ code blocks and even the option to use // for single line commenting as this is much more convenient than 'rem'.
Comment 1 [REDACTED] 2021-01-30 11:24:01 UTC
It isn't required to use REM, you may also use single quote '
Comment 2 Aron Budea 2021-12-02 13:06:24 UTC
I presume the request was about being able to select a code block, and toggle whether it should be commented out or not. Seems like a reasonable idea.
Comment 3 Rafael Lima 2022-12-06 14:04:54 UTC
In code editors as PyCharm or Kate we have the Ctrl+/ shortcut that adds/removes comment marks from the selected code.

This shouldn't be too difficult to implement. Let me know if you like the idea.
Comment 4 Rafael Lima 2024-01-14 16:17:24 UTC
Proposed patch in:

https://gerrit.libreoffice.org/c/core/+/162005
Comment 5 Commit Notification 2024-02-01 12:38:20 UTC
Rafael Lima committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/22b5007e2740e1f461968f3c8e919326eb4d4785

tdf#140004 Toggle comment in the Basic IDE

It will be available in 24.8.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.