Auto Language detection via Hint
-
is there some feature for detecting the language settings to choice NOT based on file extension?
i want something like… scan the first 3 lines, and look for a specific string marker and then parse it for a language identifier
eg. in C languages
/*
n+±lang: .C
*/ -
Hi AJ Baxter,
what you can do is writing a python script which can do it.
Something likefor i in range(1,3): identifier = editor.getLine(i) if identifier == 'something to compare': notepad.setLangType(LANGTYPE.CPP) ...If you know how it can be identified and you are willing to go this way let me know.
Btw. what needs to be done, reagrding python script plugin installation and creation
of script can you read here.Cheers
Claudia
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login