[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Search]

Mac specific trick for working with chromevox and emacs



:-) glad you discovered edit-with-emacs it's been a life-saver
for me the last few years.
>>>>> "Bart" == Bart Bunting <bart@xxxxxxxxxxx> writes:
    Bart> Hi,
    Bart> 
    Bart> Here is a little trick I'm finding useful when working
    Bart> with edit fields in chrome.
    Bart> 
    Bart> The EditWithEmacs chrome extension allows you to edit
    Bart> textareas in emacs. Just install it from the chrome
    Bart> store.
    Bart> 
    Bart> Once you follow the instructions you will get something
    Bart> called "gumdrop" after text areas. Click on this and
    Bart> the text area content pops up in emacs for editing and
    Bart> c-c c-c closes the buffer.
    Bart> 
    Bart> The trick is that when this happens I was having to
    Bart> manually switch focus between chrome and emacs. Not all
    Bart> that cumbersome but annoying
    Bart> 
    Bart> With the addition of two tiny defuns and the hooks
    Bart> provided by edit-server I have been able to automate
    Bart> that process.
    Bart> 
    Bart> So now when I click the gumdrop I'm in the focused
    Bart> emacs buffer and when I hit c-c c-c when finished I'm
    Bart> back in chrome.
    Bart> 
    Bart> I thought this may be helpful to anyone else out there
    Bart> using mac with emacspeak.
    Bart> 
    Bart> Here is the trivial code.
    Bart> 
    Bart> (defun bb-focus-chrome () (interactive)
    Bart> (ns-do-applescript "tell application \"Google Chrome\"
    Bart> activate end tell"))
    Bart> 
    Bart> (add-hook 'edit-server-done-hook 'bb-focus-chrome)
    Bart> 
    Bart> (defun bb-focus-emacs () (interactive)
    Bart> (ns-do-applescript "tell application \"Emacs\" activate
    Bart> end tell"))
    Bart> 
    Bart> (add-hook 'edit-server-start-hook 'bb-focus-emacs)
    Bart>    
    Bart> Kind regards
    Bart> 
    Bart> Bart
    Bart> 
    Bart> -----------------------------------------------------------------------------
    Bart> To unsubscribe from the emacspeak list or change your
    Bart> address on the emacspeak list send mail to
    Bart> "emacspeak-request@xxxxxxxxxxx" with a subject of
    Bart> "unsubscribe" or "help".

-- 
Best Regards,
--raman

-----------------------------------------------------------------------------
To unsubscribe from the emacspeak list or change your address on the
emacspeak list send mail to "emacspeak-request@xxxxxxxxxxx" with a
subject of "unsubscribe" or "help".



If you have questions about this archive or had problems using it, please send mail to:

priestdo@xxxxxxxxxxx No Soliciting!

Emacspeak List Archive | 2010 | 2009 | 2008 | 2007 | 2006 | 2005 | 2004 | 2003 | 2002 | 2001 | 2000 | 1999 | 1998 | Pre 1998

Emacspeak Files | Emacspeak Blog