CoenraadS / vscode-Disable-Ligatures

VSCode extension to disable ligatures at the cursor position, or disable all ligatures on the line
https://marketplace.visualstudio.com/items?itemName=CoenraadS.disableligatures
MIT License
22 stars 2 forks source link

Ligatures are not being disabled in vscode 1.49 #7

Closed BenLanglois closed 3 years ago

BenLanglois commented 4 years ago

Description

Upgrading to vscode version 1.49 (August 2020) causes ligatures to not be disabled by this extension, in both cursor and line mode. I downgraded to vscode version 1.48 (July 2020) and the extension works as expected.

System Info

BenLanglois commented 4 years ago

I also submitted a similar issue in the ligatures limited extension: https://github.com/kshetline/ligatures-limited/issues/19

kshetline commented 4 years ago

If you replace createTextEditorDecorationType({ color: '' }) with createTextEditorDecorationType({ after: { contentText: '\u200A', width: '0' } }) that will likely fix the problem. I'd originally copied your color: '' trick for breaking up ligatures for use in my own extension, so hopefully my fix with work for you too.

Killea commented 3 years ago

If you replace createTextEditorDecorationType({ color: '' }) with createTextEditorDecorationType({ after: { contentText: '\u200A', width: '0' } }) that will likely fix the problem. I'd originally copied your color: '' trick for breaking up ligatures for use in my own extension, so hopefully my fix with work for you too.

Thanks, kshetlien, works fine!

CoenraadS commented 3 years ago

I found time to update it, but I recommend using a more actively maintained extension such as: https://marketplace.visualstudio.com/items?itemName=kshetline.ligatures-limited