<div dir="ltr">Yes, I do need to use a solution other than just lisp. I asked an AppleScript-specific question because the specific task I have in mind involves some other applications on Mac that need to be part of the workflow. For instance, the ability to "drag and drop" an image from a browser (say Chrome or Safari) to LaTeX code in the emacs buffer (which results in the insertion of a code block at the insertion point to include the image). Lisp cannot do that. It takes an OS and app aware script.<div>
<br></div><div>So, my original question was posed after dismissing lisp as a potential solution, and I would appreciate returning to it if you do not mind?<br><div><br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Wed, Jul 9, 2014 at 11:09 PM, David Reitter <span dir="ltr"><<a href="mailto:david.reitter@gmail.com" target="_blank">david.reitter@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
Aquamacs is very scriptable, although AppleScript would not be powerful enough.  The syntax is a bit different.<br>
<br>
Try this<br>
<br>
(insert “Hello World”)<br>
<br>
place the cursor at the end of the line, then press C-x C-e.  This executes the last bracketed expression as code, and it will insert this into the current buffer.<br>
<br>
Aquamacs comes with the Emacs Reference Manual, which documents scripting.<br>
<br>
(Do you have a particular need to talk to Aquamacs via an AppleScript interface?)<br>
<br>
- David<br>
<br>
<br>
<br>
--<br>
<a href="http://aquamacs.org" target="_blank">http://aquamacs.org</a> -- Aquamacs: Emacs on Mac OS X<br>
<a href="http://aquamacs.org/donate" target="_blank">http://aquamacs.org/donate</a> -- Could we help you? Return the favor and support the Aquamacs Project!<br>
<div><div class="h5"><br>
<br>
<br>
<br>
<br>
On Jul 9, 2014, at 1:10 PM, Madhusudan Singh <<a href="mailto:singh.madhusudan@gmail.com">singh.madhusudan@gmail.com</a>> wrote:<br>
<br>
> Hello:<br>
><br>
> I am a long term emacs user (mostly on Linux) but am looking at Aquamacs.<br>
><br>
> Are there any docs for how to script Aquamacs? Say I wish to insert a certain text in the current emacs buffer programatically. How do I do that?<br>
><br>
> Thanks.<br>
><br>
</div></div>> _____________________________________________________________<br>
> MacOSX-Emacs mailing list<br>
> <a href="mailto:MacOSX-Emacs@email.esm.psu.edu">MacOSX-Emacs@email.esm.psu.edu</a><br>
> <a href="https://email.esm.psu.edu/mailman/listinfo/macosx-emacs" target="_blank">https://email.esm.psu.edu/mailman/listinfo/macosx-emacs</a><br>
> List Archives: <a href="http://dir.gmane.org/gmane.emacs.macintosh.osx" target="_blank">http://dir.gmane.org/gmane.emacs.macintosh.osx</a><br>
<br>
<br>
_____________________________________________________________<br>
MacOSX-Emacs mailing list<br>
<a href="mailto:MacOSX-Emacs@email.esm.psu.edu">MacOSX-Emacs@email.esm.psu.edu</a><br>
<a href="https://email.esm.psu.edu/mailman/listinfo/macosx-emacs" target="_blank">https://email.esm.psu.edu/mailman/listinfo/macosx-emacs</a><br>
List Archives: <a href="http://dir.gmane.org/gmane.emacs.macintosh.osx" target="_blank">http://dir.gmane.org/gmane.emacs.macintosh.osx</a><br>
</blockquote></div><br></div>