From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ipmail04.adl6.internode.on.net (ipmail04.adl6.internode.on.net [150.101.137.141]) by speech.braille.uwo.ca (Postfix) with ESMTP id 9F609C1A406 for ; Thu, 18 Nov 2010 20:52:41 -0500 (EST) Message-Id: <98hbe0$4qqnq3@ipmail04.adl6.internode.on.net> X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AuQHAGVm5Ux20N26/2dsb2JhbACDRZESjTNNcq0WkhyDNnME Received: from ppp118-208-221-186.lns20.hba1.internode.on.net (HELO localhost) ([118.208.221.186]) by ipmail04.adl6.internode.on.net with SMTP; 19 Nov 2010 12:22:38 +1030 Date: Fri, 19 Nov 2010 12:52:38 +1000 From: pj@pjb.com.au To: speakup@braille.uwo.ca X-Mailer: mail.pl Subject: Re: If bash can, why not Speakup? Content-Type: text/plain; charset="utf-8" X-BeenThere: speakup@braille.uwo.ca X-Mailman-Version: 2.1.13 Precedence: list Reply-To: pj@pjb.com.au, "Speakup is a screen review system for Linux." List-Id: "Speakup is a screen review system for Linux." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Nov 2010 01:52:42 -0000 Janina Sajka wrote: > to track whether I'm in insert or command mode, i.e. it would > sure help if Speakup could give me a differently pitched voice Misunderstanding this to be about vim itself :-( , I wrote: > Presumably by writing something to somewhere in > /sys/accessibility/speakup/ (or /proc/speakup ?) > ... It might be possible to do it with a vim script And it is possible :-) if you copy spokenmode.vim (after the .sig) into your ~/.vim/plugin/ dir (you might have to mkdir it first) then you should see the contents of /tmp/t change according to the editing mode. It just remains to find something in /sys/accessibility/speakup/ which switches between two suitable voices... Regards, Peter Billam http://www.pjb.com.au pj@pjb.com.au (03) 6278 9410 "Was der Meister nicht kann, vermöcht es der Knabe, hätt er ihm immer gehorcht?" Siegfried to Mime, from Act 1 Scene 2 -------------------------------------- " spokenmode.vim: cause Speakup to use a different tone of voice " according to whether Vim is in insert mode or command mode " 1.0, 2010.10.18 " inherits much from obviousmode.vim, by Brian Lewis and Sergey Vlasov " 1. Put spokenmode.vim in ~/.vim/plugins/ if &cp || exists('g:loaded_spokenmode') finish endif let s:isInsertMode = 0 function! s:InsertEnter() let s:isInsertMode = 1 call writefile(['low'], "/tmp/t") endfunction function! s:InsertLeave() let s:isInsertMode = 0 call writefile(['high'], "/tmp/t") endfunction au InsertEnter * call s:InsertEnter() au InsertLeave * call s:InsertLeave() let g:loaded_spokenmode = 1