User Defined Language_NCL
-
Hi, sir,
I use NCL and I do have a NCL language style (.xml) downloaded from the website.
Followed the guide, I copy this file to …/AppData/Notepad/userDefinedLang.xml (with new replacing the original).However, when I open a ncl file and choose to use “user defined” in the “Language” setting, it cannot work yet. Does anyone help to how to cope with it? Or what should I do?
Thanks,
Nelson
-
Since you didn’t link us to the NCL language style .xml file, or quote it here, or provide a sample NCL source code so we could see if it worked for us, there’s not a lot you should expect us to be able to help you with. (As always, with any user discussion group or other help forum, the more relevant details you give, including concrete examples of what works and what doesn’t work, the easier it is for someone to help you.)
You said
.../AppData/Notepad/userDefinedLang.xml. Did you really put it there, or did you put it into.../AppData/Roaming/Notepad++/userDefineLang.xml? Because those are two very different paths (on the first, you probably would have had to create the folders yourself; on the second, they should have already existed; and there shouldn’t be a lowercase “d” in theuserDefineLang.xml).Please go to the
? > Debug Info..., click oncopy debug info to clipboard, paste it into an empty Notepad++ tab,Ctrl+Ato select all,TABto indent,Ctrl+Cto copy, and paste it into your reply. That will give us more information to help you, like whether you have a normal config (where theuserDefineLang.xmlshould go in the AppData hierarchy), or a “local config” (aka standalone or portable installation, whereuserDefineLang.xmlwill be in the same directory as the Notepad++ executable).Looking for possible problems with your installation of the UDL (User Defined Language): If you look in the
Languagemenu, does it list NCL (or similar) somewhere near the bottom, or does it go directly fromDefine Your Language...toUser-Defined? If you click onLanguage > Define Your Language..., and then select eitherNCL(or similar, if it’s listed) orUser Define Language(ifNCLisn’t listed), and go through the various tabs in that interface, are there any keywords, number, formats, or operators listed? If there isn’t anNCLlisted, and there isn’t anything in theUser Define Languagedefinitions, you haven’t actually installed the UDL like you think you have.In good instructions for installing a specific User Defined Language, the author/distributor should instruct you to use the
Language > Define Your Language...>IMPORTbutton to load in their specific language. It will then show up under a specific name in theLanguagemenu below theDefine Your Language...but aboveUser-Defined. This way, they aren’t telling you to delete all other UDL you’ve already defined.For example, I did a quick search for “NCL notepad++ UDL” and found this ncl.ucar.edu page, which has downloads for both a User Defined Language (syntax highlighting) and Auto-Completion. Those instructions explicitly use the “import” method for installing the syntax highlighting. Assuming that site is for the same “NCL” language that you’re mentioning (we cannot know, because you didn’t define what NCL is, either), then you might try to use those instructions with their definition.
I hope all my random guesses as to what you wanted were able to in some way help, or at least point you in a new direction. If not, we may be able to help you better if you provide us with more information.