Aquamacs is an Emacs text editor for macOS. It is based on GNU Emacs, currently tracking the GNU Emacs version 25.3 branch. Although GNU Emacs has had native UI support on macOS using the Cocoa API since version 23, Aquamacs modifies the user interface to conform with macOS standards in favor of Emacs standards. 2 Tutorial: Aquamacs for Beginners 2.1 What Makes Aquamacs Like Other Text Editors When you first launch Aquamacs, you will see that it is like many other text editors: you can type text, cut and paste text, and save and close a file using the menubar or standard OS X keyboard shortcuts (Command-S for save, Command-X for cut, Command-V for. Aquamacs 3.4 is based on Emacs 25.3 and the latest versions of many packages. It is compatible with macOS 10.12 Sierra and comes with some critical improvements. Aquamacs uses a mono-spaced font (Monaco) as a default, but uses the system’s variable-width font (Lucida Grande) for all text modes, including those derived from ‘text-mode’.
NCL Home>Application examples>Miscellaneous ||Data files for some examplesExample pages containing:tips |resources | functions/procedures
This page contains some handy scripts for customizing various editorsto do special highlighting of NCL syntax. They were documented andcontributed by other users.Note that the NCL developers have not tested every one of thesescripts, so use these at your own discretion.
These editor scripts are not necessarily supported by the NCL team,but we greatly appreciate and encourage these kind of contributions.
These are listed alphabetically:
In order to help create your own editor enhancements, you can use thefunctionsin gen_editor_utils.ncl tocreate lists of all the NCL functions/procedures, keywords, operators,and/or resource names. See the comments at the top.
If you have an editor enhancement contribution for NCL, sendemail to ncl-talk.
GNU EmacsFunctionality includes:
- Indents two spaces between 'begin' and 'end' statments
- Indents two spaces within 'do' loops and 'if' statments
- Comment handling (M-;)
- insert a comment at the end of the current line
- Alternatively comment/uncomment selected region
- Highlighting (chose your colors)
- NCL keywords
- All documented gsn plotting functions
- All documented NCL built-in functions
- All documented contributed functions
- All documented Shea_util functions
- Comments
- All documented graphics resources
Issues that remain
- Comment Handling does not work in xemacs
- Comments may not fontify on file open in xemacs
Controlling your emacs window:
Add and modify the following to your .Xdefaults if desired:
Add and modify the following to your .Xdefaults if desired:
Steps
- Download the ncl.el file and put it on your system.
- Put the following text in your .emacs file: (note, if you do not like the specified colors, you can change them here or not include this portion in your .emacs file)
- Change ~/bin/ncl.el to the location of YOUR ncl.el file
- Modify the ncl.el code as necessary to include functions or keywords not specifically listed
The Emacs NCL mode was first implemented by Sylvia Murphy at NCAR. Updates have been provided by Heiko Klein of Norway, Carl Schreck and Alan Srock of theUniversity at Albany (SUNY), and Thierry Corti of ETH in Zurich, Switzerland.
NEditVarious files for NEdit:
ncl.nedit /ncl2.nedit / ncl3.nedit Download google chrome for mac os 10.7.
The following scripts enable NCL syntax highlighting in NEdit versions5.1.0 and higher. The scripts range from a minimalistic approach withfew highlighting schemes and few colors, to a more thoroughhighlighting scheme with many colors. The scripts can be downloadedand, if desired, edited and tested. When ready you can import the file into NEdit by typing, for example:You will only have to import the file once. Go to 'Preferences'and click on 'Save Defaults'.
- ncl.nedit -a minimalistic approach,keywords and flow constructs are in bold-black, comments are plain-redand symbols are highlighted in bold-blue (courtesy of Dennis Shea)
- ncl2.nedit - a more moderatehighlighting scheme that highlights attributes, I/O functions (amongothers) (courtesy of Adam Phillips)
- ncl3.nedit - an intensive syntaxhighlighting approach that highlights most NCL functions (courtesy ofPaul Thomas Quelet). Updated periodically by volunteers to reflect newsyntax or functions.
vi/vim
Several people have included enhancements for the VI/VIM editor. We've triedto include as many as we can so you have a choice of which one to use.
Steps:
- Download the desired .vim file [naming it ncl.vim] and put it inyour .vim/syntax directory
- Put the following two lines in your .vimrc fileIf things do not appear to be working, then add a third line to the .vimrc file:
- ncl1.vim -a simple approach(courtesy of Kevin Mueller [UIUC])
- ncl2.vim - extensive highlighting offunctions through v5.0.0 with some v5.1.0 functionsincluded. (Courtesy of Arindam Chakraborty [Indian Institute ofScience].)
- ncl3.vim - includes highlighting ofresources and additional new functions. (Courtesy of Carl Schreck.)Carl wrotethis gen_vim_syntax.ncl scriptto make the ncl3.vim file. This loads a script namedgen_editor_utils.ncl
- https://github.com/xiexinyls/vim- includes indentation for 'do' and 'if' statements in NCL (Courtesyof Xin Xie [School of Marine and Atmospheric Sciencs, Stony BrookUniversity].Be sure to download the whole directory structure. If you have git,you can also go to your home directory and type:
- The following was donated by Prince K. Xavier [Laboratoire deMeteorologie Dynamique, France].I experimented a bit with the VIM to include an auto-completion option forNCL commands. I think I have some good news for those who do not want toremember all the commands or consult the website often while writing ascript! I find it particularly useful! Here is what you have to do.
- Save ncl.dic to ~/.vim/dictionary/(I took the commands from the ncl syntax file compiled by ArindamChakraborty. I am not sure how complete this list is, but one can alwaysadd entries to this file.)
- Make the following entries to your .gvimrc
- Open your .ncl file and start typing the first letter of thecommand/resource/function name and press 'control+n' and choose youroption.Here is a screenshot of my editorthat works great!
- Save ncl.dic to ~/.vim/dictionary/
- Aaron Spring [Max Planck Institute for Meteorology, Germany] has made his VIM editor enhancement available as an open-source project. Its features include:
- completion function with short description for all NCL resources and NCL functions
- snippets (predefined code) for recommended arguments, parenthesis, and loops
- syntax highlighting
Setup instructions and animated demos of the features in action are available atGitHub
The ncl.slscript was contributed by TJOlney of Western Washington University, for use with John EDavis's JED editor.
The latest version (June 1, 2011) has been updated to work with NCLV6.0.0, and should be used with version 99.19 of jed.
JED is a freely available text editor for Unix, VMS, MSDOS, OS/2,BeOS, QNX, and win9X/NT platforms. Although it is a powerful editordesigned for use by programmers, its drop-down menu facility make itone of the friendliest text editors around. Hence it is ideal forcomposing simple email messages as well as editing complex programs ina variety of computer languages.JED makes extensive use of the S-Lang library, which endows it with apowerful S-Lang macro language. This and other features of the libraryare discussed on the features page.
To incorporate this syntax in your JED environment, add the lines fromthe ncl.sl to your 'defaults.sl' or 'jed.rc'(.jedrc) file. The instructions are also in the file.
TextMateThe NCL.tmbundle.zip script wascontributed by Ryan Pavlick.
To install the file, unzip the 'NCL.tmbundle.zip' file, double click'NCL.tmbundle', and restart TextMate if it is open. If that doesn'twork, try opening a Terminal window and enter the following twocommands:then restart TextMate.
geditThis configuration was contributed by Chad Herman. The 'ncl.lang' filein the ncl_gedit_xml.tgz tarballwas updated September 2017 to recognize new functions/resources added through NCL V6.4.0.
To install, unwrapthe ncl_gedit_xml.tgz tarball insome convenient directory, cd into the
ncl_gedit_xml
directory and run the install.sh
bash script as follows:The tarball and
ncl_gedit_xml
directory can be deletedafter the installation.Chad writes:
Gedit should now recognise and highlight your *.ncl files. If youstart gedit in the terminal, you'll see a *warning*:This is nothing to worry about. This started showing up after I addedall ofthe 'resource' names (all 1,452 of them). NCL is a big language!
For MacOS X users with an official binary ofgedit, Rob Nicholas of the Dept. ofGeosciences at Penn State University advises:
..for those of you using the official Mac OS X binary for gedit,you'll need to change line 57 of the install script to:
Rob further notes that this does not apply to users who obtained geditthrough Fink or MacPorts.
AquamacsThe ncl.el editor enhancementfor Aquamacs was contributed byLuis C. Cana Cascallar of the Universidad de Las Palmas de GranCanaria.
Aquamacs (see http://aquamacs.org)is a free editor based on the GNU Emacs but with a deep integration inMac OSX. These are the steps following some recommendations of DavidReiter, the main developer and maintainer of Aquamacs:- Download ncl.el file (the same forEmacs) and put it on the system.David Reiter's suggestion: /YOUR-HOME-DIRECTORY/Library/ApplicationSupport/Aquamacs Emacs
- Add the following piece of code in/YOUR-HOME-DIRECTORY/Library/Preferences/Aquamacs Emacs/Preferences.el
And that's all! If there is any problem, one should check first which is the Major Mode:
Another possibility is just adding to the FIRST LINE of the ncl scriptthis single line:
This trick switches the mode to NCL.
NetBeansRobert Redl wrotea NetBeansplugin that supports NCL script development. It features:
- Syntax highlighting and checking.
- Code completion for all NCL procedures functions and resources: type the first few letters followed by CTRL-SPACE to get a list of all procedures/functions/resources that begin with those letters.
- Displays online documentation in conjunction with code completion.
- NCL project management: develop, manage and run ncl scripts from within the NetBeans IDE.
Netbeans is freely available for Unix/Linux, MacOS X, and Windowsmachines. See the NetBeans site for more information.
TextWrangler- a text editor for the Mac.(Click on image for a slightly larger view.)
The NCL.plist editor enhancementfor TextWranglerwas originally contributed by Emilie Vanvyve of NCAR and enhanced byCharles Bardeen of NCAR to support generating a pull down list offunctions and procedures.
Alan Brammer has continually updated and enhanced this module.Functions and procedures can now be 'folded' and the 'Reveal start'and 'Reveal end' menu items now work. Alan put some simple code togenerate this, as well as some documentation and examples up onbitbucket:
Move the NCL.plist to either:
or
If TextWrangler is open, quit and restart the application.
KateThe ncl_kate.xml.txt editor enhancementfor Kate was contributed by RaulValenzuela, a graduate student in the Atmospheric and Oceanic SciencesProgram at the University of Colorado. It highlights NCL keywords,functions, contributed functions, gsn_code functions,gsn_csm_functions, comments, strings, and metadata markers (@, !, &).
Rename the 'ncl_kate.xml.txt' file to 'ncl.xml', and put it in thesystem /usr/share/kde4/apps/katepart/syntax directory, or you can usethe following shell script that installs the file in the user's kde'data' directory. Thanks to Stephen Dowdy of NCAR/RAL for this script:
SublimeTextDr. Li Dong of the Institute of Atmospheric Physics at the ChineseAcademy of Sciences contributeda Sublime Text package foruse with NCL. Sublime Text is billed as 'a sophisticated texteditor for code, markup and prose'. Full instructions can befound here.
[Click on image for larger view.]
Notepad++Two users have contributed complementary enhancement files to workwith the Notepad++ editor.The first file provides auto-completioncapabilities, and the second file providessyntax highlighting with color.
Auto-completion
Dr. Ma Xinye and Ge Hui, from the School of Atmospherical Sciences,Nanjing University, China ([email protected]), contributedthe NCL_notepad.xml.txt file,which is based on the script supplied by Dr. Li Dong who is also thecontributor of Sublime Text's enhancementfor NCL.
This file has been updated for NCL version 6.3.0 and can work fornotepad++ v6.7.8. It provides auto-completion for NCL, includingfunctions/procedures, graphical resources, and resource codes.
Follow these steps to achieve the function of auto-completion for notepad++:
- Download the NCL_notepad.xml.txtfile, rename it to 'NCL.xml', and put it into the correct position, forexample 'D:Program FilesNotepad++pluginsAPIs', and you will alsofind there are many other '.xml' files there.
- From the menu bar, select Settings -> Preferences -> Auto-Completion
- Check the 'Enable auto-completion on each input', 'Function andword completion', 'Function parameters hint on input', '()','
- Restart notepad++
The contributors have stated you can contact them directly with questions,[email protected].
[Click on images for larger view.]
Syntax highlighting
Brian Vanderwende, a PhD student at the University of ColoradoBoulder, contributed syntax highlighting files for two of the includedcolor schemes (Default and Obsidian).
To add the schemes to Notepad++, the user simply needs to download thenpp_ncl_default.xml andnpp_ncl_obsidian.xml totheir hard drive, and then import them in N++. Be sure to save thefiles without the '.txt' extension.
Follow these steps to import these schemes in N++:
- From the menu bar select Language -> Define Your Language
- Click the Import.. button
- Select the XML file you'd like to use on the disk
- Restart Notepad++
From this point, any .ncl file you open should have the highlightingenabled. It recognizes NCL 6.2.0 keywords and all functions includedin the nclscripts folder. Note that the formatting uses UDL2, which isonly available in versions 6.2 and up of Notepad++.Below is a screenshot of the dark Obsidian theme.
[Click on image for larger view.]
R/BricsCAD: BricsCAD. I installed it on Fedora using the package on the downloads page, unfortunately it doesn't work on my system and I want to uninstall it however the Fedora package manager doesn't recognise the install. Bricscad reddit 2020.
AtomRyan Pavlick (Jet Propulsion Laboratory) and Ben Schroeter(University of Tasmania) have contributed different NCL packagesfor Atom.
Package #1 - Ryan Pavlick
This package is based on Li Dong's SublimeText's enhancement package and provides syntax highlighting,autocompletion, and some useful code snippets for NCL.
Installation is straightforward for Atom users, either:
Enter `apm install language-ncl` at the command line.
OR
Search for `language-ncl` in the Atom package manager and click theinstall button.
Package #2 - Ryan Pavlick
This package allows users to run an NCL script or a selectionfrom an NCL script directly from their Atom editor.
Instructions for installing and using the package are here:https://github.com/rgbkrk/atom-script
To use it with NCL scripts, you need to:
- make sure you have language-ncl package installed:https://github.com/rpavlick/language-ncl
- start atom from the terminal (mostly likely you will want to be inthe directory where your NCL script resides)
Emacs For Mac
Package #3 - Ben Schroeter
This package autocompletes NCL:
There are two ways to install the package:
- Via the Atom Editor itself
- Via the APM command line utilityCompletions are automatically generated from the NCL documentationwebsite, so as new major NCL releases come out, Ben said he wouldupdate the package.
Developer(s) | David Reitter |
---|---|
Stable release | 3.5[1] / August 18, 2019; 19 months ago |
Repository | |
Operating system | macOS |
Type | Text editor |
License | GPL |
Website | aquamacs.org |
Aquamacs is an Emacs text editor for macOS. It is based on GNU Emacs, currently tracking the GNU Emacs version 25.3 branch. Although GNU Emacs has had native UI support on macOS using the Cocoa API since version 23, Aquamacs modifies the user interface to conform with macOS standards in favor of Emacs standards.
Among the changes are that Aquamacs, by default, shows tabs to organize different file buffers in windows. A range of keybindings (keyboard shortcuts) that are standard on macOS, such as Command-W to close a window, or Command-S to save the file, are available. A standard printing dialog and functions to efficiently use the Option key on Mac keyboards as Emacs Meta key have been added. The styles of windows can be automatically changed to suit the major mode used in the buffer shown. Visually, Aquamacs has been adapted in its icons and fonts to look similar to other Mac applications.[2]
Aquamacs is a distribution that includes a number of extensions to GNU Emacs to provide an integrated development environment and to support, among many formalisms, LaTeX, Python, Java, Lisp and Objective C editing, as well as the Emacs Speaks Statistics system for R and S. These packages are installed without the need of further configuration by the end user.
Aquamacs is designed to be highly compatible with Emacs, so that extension packages for GNU Emacs can be installed. Users can configure Aquamacs with Emacs customization options. They can also choose to bring back GNU Emacs behaviors.[3]
The current version of Aquamacs includes a Wikipedia mode. This can be used to edit text for Wikipedia and any other wiki based on the MediaWiki software application.[4][5] The mediawiki package is available for GNU Emacs through the package system.
The editor is self-documenting and is supported by a community of users.[6]
See also[edit]
References[edit]
- ^'What's new in the latest release?'. 2019-08-18. Archived from the original on 2019-09-21. Retrieved 2019-08-20.CS1 maint: discouraged parameter (link)
- ^Reitter, David (24 June 2014). Aquamacs Emacs Manual(PDF). p. 4.
- ^'Aquamacs Emacs Compatibility Settings'.
- ^Reitter, David (18 August 2019). Aquamacs Emacs Manual(PDF). p. 40.
- ^'Features'. Aquamacs: Emacs for Mac OS X. Archived from the original on 20 March 2006. Retrieved 20 August 2019.CS1 maint: discouraged parameter (link)
- ^'Emacs on Mac OS X mailing list'.
Aquamacs For Windows
External links[edit]
- Official website
Retrieved from 'https://en.wikipedia.org/w/index.php?title=Aquamacs&oldid=963459855'