Open BW2001 opened 1 year ago
Since v1.6.0 snippets should be inserted with the indention, but as mentioned in the release notes, I have only been able to test it for a few languages.
From your report I am not able to spot what language you are using. Could you please tell me, so I can take a closer look.
Hello
Thanks for responding.
I am new to Notepad++ and snippets. I have had another look at the problem and it seems that the snippets plugin ignores indents (ie TAB or spaces) within the body text – see attached screen grab I tried various combinations and found a workaround using “Before cursor” entry only followed by selection and TABbing to correct indent although not ideal.
Also, is there any way I can change the target language. Originally I edited the overrideMap to refer to a copy of Pascal function definition ie
The language is a derivative of Pascal
Vectorscript web page https://developer.vectorworks.net/index.php/VectorScript
Good Example https://developer.vectorworks.net/index.php/VS:Progress_Dialog
Thanks
Bill Wood
From: Frank Fesevur @.> Sent: Friday, June 9, 2023 8:30 PM To: ffes/nppsnippets @.> Cc: BW2001 @.>; Author @.> Subject: Re: [ffes/nppsnippets] Does nppsnippets respect TABed cursor position (Issue #59)
Since v1.6.0 snippets should be inserted with the indention, but as mentioned in the release notes, I have only been able to test it for a few languages.
From your report I am not able to spot what language you are using. Could you please tell me, so I can take a closer look.
— Reply to this email directly, view it on GitHubhttps://github.com/ffes/nppsnippets/issues/59#issuecomment-1585041282, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AOVBNSVH2HH3LGGAE6J2H7LXKN2S7ANCNFSM6AAAAAAY6K5OZE. You are receiving this because you authored the thread.Message ID: @.***>
There are various issues with UDL and plugins (including my Snippets plugin). AFAIK for a plugin it is impossible to properly detect a UDL. Therefore things like adding the right language to a libraries, and apparently indenting (haven't tested it myself yet) don't work. See #43 as well.
+1
Looking back at the whitespace before insert position, and prepending it to each and every following linebreak should solve the problem.
Hello
I have a lot of TABed code and find that the plugin doesn’t respect the initial cursor TABed (or multiple space indent) position for the inserted snippet code -see below. Is there anything I can do to fix this anomaly.
Before cursor
After cursor
Some example code
If I add snippet at cursor position above, I get the following