Nextstep applications receive a number of special events which have no X equivalent. These are sent as specially defined key events, which do not correspond to any sequence of keystrokes. Under Emacs, these key events can be bound to functions just like ordinary keystrokes. Here is a list of these events.
ns-find-file). As an exception, if the selected buffer is the *scratch* buffer, Emacs visits the file in the selected frame.
You can change how Emacs responds to a
ns-open-file event by
changing the variable
ns-pop-up-frames. Its default value,
‘fresh’, is what we have just described. A value of
means to always visit the file in a new frame. A value of
means to always visit the file in an existing frame.
ns-open-fileevent, the results of which are described above.
ns-insert-files). The list of dragged files is stored in the variable
ns-set-foreground-at-mouse). If this event is issued with a <Shift> modifier, Emacs changes the background color instead (
ns-set-background-at-mouse). The name of the dragged color is stored in the variable
ns-respond-to-changefont). The name and size of the selected font are stored in the variables
Emacs also allows users to make use of Nextstep services, via a set
of commands whose names begin with ‘ns-service-’ and end with the
name of the service. Type M-x ns-service-<TAB> to
see a list of these commands. These functions either operate on
marked text (replacing it with the result) or take a string argument
and return the result as a string. You can also use the Lisp function
ns-perform-service to pass arbitrary strings to arbitrary
services and receive the results back. Note that you may need to
restart Emacs to access newly-available services.