Syntax Highlighting for Sublime Text 3

Hi there,

i did a tmLanguage file for Sublime Text 3 to have the GM Script syntax highlighted.
You can find it here: https://github.com/zwnk/GM-Script-Syntax

Comments

  • PaulTocknellPaulTocknell Forum Administrator Posts: 307
    Hey, that's awesome! Thanks for sharing that with us. Very useful.
  • zwnkzwnk Posts: 9
    you are welcome ;)
    im still have to figure out some stuff with the regex to make it a little bit better. detecting a line break does not work right now. would be helpfull to detect if the \ is set correctly at the end of the line. also the parameter detecting troubles me because its not consistently written inside " ". But well just details ;)
  • zwnkzwnk Posts: 9
    I added the EXPORT_WEB command and the related parameters.
  • RobertRRobertR GlobalMapper Fan! Posts: 285Trusted User
    Hey @zwnk !
    This is probably one the best thing this year on the forum. Cograts and many thanks.
    Maybe some highlighting for "RUN_COMMAND COMMAND_LINE" would be useful as I call other scripts from my gms one.

    All in all, really good stuff. Thank you again!
  • zwnkzwnk Posts: 9
    edited August 2015
    Hi @RobertR
    i added the the RUN_COMMAND and the parameters. Just download the file from github and replace the old one.
    You are welcome.

    Generally spoken, if i missed a command, parameter or you found an error. fell free to contact me!

    I will have a look to add the syntax highlighting to https://packagecontrol.io/ to enable an easy way to install it.

  • zwnkzwnk Posts: 9
    edited November 2015
    hi there,

    i will update the syntax file today. does somebody has contact with a guy of blue marble? 
    it would be nice to get a list that includes all commands an parameters. copying and cleaning the text from the oficial scripting guide is always so boring. ;)
    especally the available parameters in just one list would be great.

    DF
  • zwnkzwnk Posts: 9
    i updated alot of stuff. have fun!
  • zwnkzwnk Posts: 9
    edited November 2015
    New Update

    I created also a syntax highlighting for Atom! for the people that like free editors. ;)

    Sublime Text:
    https://github.com/zwnk/GM-Script-SUBLIME_TEXT

    Atom: https://atom.io
    https://github.com/zwnk/GM-Script-ATOM
    --> copy the files to c:\Users\"yourusername"\.atom\packages\gm-script\

    Is it possible for an administrator to change the title and add both links to the main post?


    P.S.: i will update the Sublime Text 3 to the JSON format,  the same ATOM is using, at github.
  • falqnfalqn Global Mapper User Posts: 123Trusted User
    Great job zwnk! Thanks!
  • zwnkzwnk Posts: 9
    Sublime Text 3: https://github.com/zwnk/GM-Script-ATOM

    Atom: https://github.com/zwnk/GM-Script-ATOM

    Notepad++: https://github.com/zwnk/GM-Script-NOTEPADpp

    That will be the last editor for me to support ;)
    Katrina
  • KatrinaKatrina Posts: 24
    In notepad++ you can go to Language menu> Define your language, and import the provided XML. Thanks for maintaining these. 
  • kbelliskbellis Global Mapper User Posts: 517Trusted User
    If anybody uses TextPad, attached is the syntax highlighter I worked on back in October 2013 (draft 01). Please feel free to update keywords, etc., since these may have changed with new items or retired items. And FWIW, it still is working for me :)

    Place global_mapper.syn under C:\Program Files\TextPad 8\system\

    Example appearance:



  • kbelliskbellis Global Mapper User Posts: 517Trusted User
    Katrina said:
    In notepad++ you can go to Language menu> Define your language, and import the provided XML. Thanks for maintaining these. 
    Notepad++ looks like a great free program
    @Katrina - What xml and where is it provided from; i.e., URL?

    For here on the forum
    Consider a (free) Vanilla Plugin for syntax highlighting in this forum:


  • kbelliskbellis Global Mapper User Posts: 517Trusted User
    @zwnk - Great looking highlighter! Thanks for your work on these.
  • zwnkzwnk Posts: 9
    welcome ;) i did ask blue marble if they could provide a list with all keywords to update the definitions. wasn't a succes ... so i won't update any new keywords anymore. feel free to fork or open a pr on github.
Sign In or Register to comment.