IBM / zopeneditor-about

IBM Z Open Editor: File issues here!
https://ibm.github.io/zopeneditor-about
Apache License 2.0
50 stars 20 forks source link

COBOL - Toggle line comment not working for non-blank lines #157

Closed ian-burnett closed 2 years ago

ian-burnett commented 3 years ago

Development environment used

Problem Description

Detailed steps for reproducing the problem:

  1. Create a basic COBOL file and open for editing
  2. Position the cursor on the line beginning "01"
  3. Use either the command "Toggle line comment" or keyboard shortcut Ctrl + / to toggle the line comment

Sample basic program:

       identification division.
       program-id.    mytest.

       data division.
       working-storage section.

      *    Return code
       01  rc pic s9(9) binary.

Observed behavior

            *  01  rc pic s9(9) binary.
                  * *  01  rc pic s9(9) binary.

Expected behavior

See also Comment lines in the COBOL documentation.

davidkcoblentz commented 3 years ago

COBOL - Code coloring on commented lines I am not sure but I think I should put this comment here also since it pertains to COBOL Comments. I noticed when a COBOL line is commented the whole line changes to the comment color including positions 1-6. But In the IBM TSO editor the coloring doesn't change positions 1-6 even if the line is commented. It only colors the rest of the line up to 72 with the comment color. The same is true for columns 73-80 which maintain a color other than the comment color. See an example the image below.

TSO Editor Color Example Positions 1-72 image to show 73-80 of the same lines above image

as compared to IBM Z Open Editor image

I am using VS Code: Version: 1.61.1 (user setup) Commit: c13f1abb110fc756f9b3a6f16670df9cd9d4cf63 Date: 2021-10-14T01:19:42.089Z Electron: 13.5.1 Chrome: 91.0.4472.164 Node.js: 14.16.0 V8: 9.1.269.39-electron.0 OS: Windows_NT x64 10.0.17763

IBM Z Open Editor extension: V1.2.7

phaumer commented 2 years ago

Added that in v1.4.1

ian-burnett commented 2 years ago

Works for me thanks!

davidkcoblentz commented 2 years ago

Yes, works great even if the selected lines have some comments already. Great Work!!

Thank you, @.***

From: Peter Haumer @.> Sent: Thursday, November 18, 2021 4:17 PM To: IBM/zopeneditor-about @.> Cc: Coblentz, David @.>; Comment @.> Subject: Re: [IBM/zopeneditor-about] COBOL - Toggle line comment not working for non-blank lines (#157)

Added that in v1.4.1

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://urldefense.com/v3/__https:/github.com/IBM/zopeneditor-about/issues/157*issuecomment-973402551__;Iw!!OgnrLJOUc50AAzM!cx-BZFXyllKFXKJEs-8AvS0Prbc8PHUMldc0GsM8XT9rrY3Y0C57qeuVIF2rOJ_CKQ$, or unsubscribehttps://urldefense.com/v3/__https:/github.com/notifications/unsubscribe-auth/ATC2YG5VW75VPVBTFEK5MZDUMWCNVANCNFSM5DVVNNRA__;!!OgnrLJOUc50AAzM!cx-BZFXyllKFXKJEs-8AvS0Prbc8PHUMldc0GsM8XT9rrY3Y0C57qeuVIF1m3DTI1w$. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.com/v3/__https:/apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675__;!!OgnrLJOUc50AAzM!cx-BZFXyllKFXKJEs-8AvS0Prbc8PHUMldc0GsM8XT9rrY3Y0C57qeuVIF1VEgfJhw$ or Androidhttps://urldefense.com/v3/__https:/play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign*3Dnotification-email*26utm_medium*3Demail*26utm_source*3Dgithub__;JSUlJSU!!OgnrLJOUc50AAzM!cx-BZFXyllKFXKJEs-8AvS0Prbc8PHUMldc0GsM8XT9rrY3Y0C57qeuVIF1SPRO_YA$.