Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Replacing UniSciTE with Notepad++

Discussion in 'Formats & External Tools' started by AnomalusUndrdog, Apr 2, 2010.

  1. ZoomDomain

    ZoomDomain

    Joined:
    Aug 30, 2012
    Posts:
    150
    okay I did another half an hour editing the relevant files because of working around admin privileges copying thousands of words into HTML files, I did it carefully by modifying the obsidian theme specifically as instructed-when I open a file with the new obsidian theme it says-loading stylers XML failed.I will have another go later.

    the perfect solution would be a patcher, or a utility like advanced find and replace which would insert the keywords into all 20 of the theme files, because that's why I really use notepad++ ! It's great to have lots of different themes!

    what would make would be to be able to enlarge the amount of words that can be pasted into notepad keyword fieldbut it's supposed to be!-I I expect that's in the core executable though.
     
    Last edited: Oct 11, 2012
  2. ZoomDomain

    ZoomDomain

    Joined:
    Aug 30, 2012
    Posts:
    150
    a couple of things-

    I can heartily recommend the function list plug-in although it seems to be a manual install rather than from plug-in manager, it gives you a list of your functions you can navigate on the right

    Also recommending multi clipboard plug-in

    %APPDATA%/Notepad++/plugins/config is also a faster way to find that folder, because just paste it and don't worry what Windows version you have
     
  3. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    You're still doing something wrong. Here's my obsidian.xml: http://pastebin.com/JiVJ9Ewg
     
  4. Member123456

    Member123456

    Joined:
    Oct 17, 2012
    Posts:
    237
    I am just wondering...I got the highlighting to work, but when trying to pick a different color in the style configurator, it still only highlights the words blue, even though I have set it to orange. It looks like its just pulling the standard keywords highlight color, no matter what I set it to. Since I'm new to unity and trying to learn everything it has, it would be nice to see the keywords in separate colors, if this is possible.
     
  5. ProbePLayer

    ProbePLayer

    Joined:
    Oct 19, 2012
    Posts:
    19
    Just wanted to say that Language Help and Intellisense worked for me perfectly(and if I tried Highlighting it probably would have worked as well), and that you are my best friend because of that. Even though I don't know you.
    My friend was convincing me that MonoDevelop is better for Unity scripting because of the auto-complete( Intellisense) feature, but you prove him wrong. Notepad++ is awesome because of the guys like you.
     
  6. ZoomDomain

    ZoomDomain

    Joined:
    Aug 30, 2012
    Posts:
    150
    thanks for all the help anomalous!

    I have managed the keywords now! I used a completely different method than mentioned in the wiki etc, -if anyone confirms this is an easy alternative then it could be worth mentioning in the wiki. I typed in %APPDATA% into the address bar,opened notepad folder,opened Lang.XML and added the keywords to the JavaScript list there, finally I have keywords!

    There is also a file called userdefinelang.XML that you can get online and install in the same directory but editing lang works for me. It may be that I edited the stylers is well but I tried the stylus previously without success.

    now on to auto complete:)
     
  7. ZoomDomain

    ZoomDomain

    Joined:
    Aug 30, 2012
    Posts:
    150
    try editing the file mentioned in the above post, otherwise make sure you browse down to the JavaScript option in the style configurator and set the keyword colour there and not in the global settings
     
  8. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    I tried doing the same thing. I wanted js/c# language keywords in one color, and unity "keywords" in another.

    Unfortunately, the way I understand it, adding another set of keywords for an existing language highlighter in N++ won't work unless you go so far as to edit N++'s source code. Creating your own user defined style and putting the Unity keywords there won't work, last I tried, Notepad++ crashed when I tried. User-defined styles are pretty limited anyway if you have to recreate the style for C#/JS.




    Thanks, that's very handy. In fact I think that's the more proper way to do it. I've updated the wiki.




    Haha, thanks man.
     
  9. magarcan

    magarcan

    Joined:
    Sep 25, 2012
    Posts:
    34
    As Notepad++ is free, would be really interesting if somebody download de portable version, make all this changes, and upload it.

    Would be easier for newbies ;)
     
  10. marcoantap

    marcoantap

    Joined:
    Sep 23, 2012
    Posts:
    215
    I finally found a way to use Notepad++ in MacOS!! Simply use Wineskin:

    http://wineskin.urgesoftware.com/tiki-index.php

    Install the latest engine and wrapper, download the latest installer of Notepad++ and install it with "Create New Blank Wrapper". That will generate a MacOS application, that will run Notepad++ using Wine. It will work for many other applications as well, how awesome is that? :cool:
     
  11. Rond

    Rond

    Joined:
    Oct 21, 2009
    Posts:
    175
    Can I make the color of the unity keywords different from the js/cs keywords? There is a way to do that?

    edit: oops, I just read about that in the previous posts.. thanks.
     
    Last edited: Apr 14, 2013
  12. Windexglow2

    Windexglow2

    Joined:
    Sep 23, 2012
    Posts:
    90
    A few days ago my anti virus (webroot) decided that several of the mono develop files (including the modified one for notepad++) were dangerous. After I restored them unity has been getting "Windows Script Host : Microsoft JScript compilation error" when I try to use this technique.

    -Restoring original monodevolop.exe makes unity use the default text editor without problem
    -Telling unity to use notepad++ directly does not cause an error
    -Redownloading package and following step by step does not work anymore
    -Disabling Webroot has no effect

    Kind of stumped on this.
     
  13. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Hmm.. I don't have any experience with Webroot. The External Script Editor Helper is really just a quick and dirty hack though. I'm not surprised an anti-virus would mistake it as malware. Really the best thing would be for Unity to fix file and line number jumping in the first place. I've sent a bug report, hopefully they'll do something about it.

    EDIT: This isn't needed anymore. Unity preferences allows you to change the command line arguments for your script editor.
     
    Last edited: Jun 14, 2014
  14. Kaz_Yamof

    Kaz_Yamof

    Joined:
    Jan 17, 2013
    Posts:
    28
    Hi!

    I didn't find C:\Program Files\Unity\Editor\Data\Tools\UniSciTE\unitykeywords.properties.
    Using Unity 4.3.4
    Ideas?

    Thanks
     
    Graives likes this.
  15. frogsbo

    frogsbo

    Joined:
    Jan 16, 2014
    Posts:
    79
    Function list in N++ 6.4 and later lists JS and C functions in a convenient list on the right, it's a button at top of n++. However most of the functions are missing and invisible, the parser isn't seeing them, i dont know why. it's difficult regex, i can't see where the error would be.

    simply isnt working properly:

    <parser id="js_function" displayName="Javascript" commentExpr="((/\*.*?\*)/|(//.*?$))">
    <function
    mainExpr="((^|[\s]+|[;\}\.])([_A-Za-z][\w_]*\.)*[_A-Za-z][\w_]*[\s]*[=:]|^|[\s;\}]+)[\s]*function([\s]+[_A-Za-z]?[\w_]*\([^\)\(]*\)|\([^\)\(]*\))[\n\s]*\{"
    displayMode="$className->$functionName">
    <functionName>
    <nameExpr expr="[_A-Za-z][\w_]*[\s]*[=:]|[_A-Za-z]?[\w_]*[\s]*\("/>
    <nameExpr expr="[_A-Za-z]?[\w_]*"/>
    </functionName>
    <className>
    <nameExpr expr="([_A-Za-z][\w_]*\.)*[_A-Za-z][\w_]*\."/>
    <nameExpr expr="([_A-Za-z][\w_]*\.)*[_A-Za-z][\w_]*"/>
    </className>
    </function>
    </parser>



    it seems overly complicated. this worked in the previous plugin version:

    function begin - function[\s]+
    function name - ["\w_]+
    function end - \s*\(.*\)
    seperator between - ;
    body begin - \{

    etc
     
    Last edited: May 29, 2014
  16. Graives

    Graives

    Joined:
    Jun 13, 2014
    Posts:
    2
    I also don't seem to have a UnityKeyWords.Properties, or even a UniSciTE folder. Where can I get the data from the file?
     
  17. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Hi @Graives and @daybson.paisante: UniSciTE was the old text editor bundled with Unity. They don't use that anymore and it's been replaced with MonoDevelop.

    Unfortunately, that means there's no keywords file anymore. There could be a way to generate a keywords list based on the UnityEngine.dll file but that requires coding a tool to extract the information and converting it to text that Notepad++ will understand. I don't have the time to do it but perhaps someone else can.
     
  18. Graives

    Graives

    Joined:
    Jun 13, 2014
    Posts:
    2
    So is Monodevelop the prefered editor now?

    Also, thanks for the quick reply Anomalus!
     
  19. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    @Graives: Yup, it seems that way, though personally I still don't like using MonoDevelop. Unity Technologies bundled an old version of MonoDevelop into Unity, and overall, it feels kinda sluggish. I hope they do something about that.

    I've simply settled for using Notepad++ without Unity class names getting highlighted and the Intellisense thing.
     
  20. alone1992

    alone1992

    Joined:
    Oct 23, 2012
    Posts:
    156
    Hi
    Can you update your post?