From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: AW Newsgroups: gmane.emacs.help Subject: Re: How to switch off the touchpad when Emacs window is active under Linux? Date: Mon, 24 Aug 2015 21:51:26 +0200 Message-ID: <2247067.SQ4RZKcTZX@linux-k2bd.site> References: <18033119.faXLECKoLl@linux-k2bd.site> <20150824190903.3079.0B60605E@ahiker.mooo.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit X-Trace: ger.gmane.org 1440446000 3768 80.91.229.3 (24 Aug 2015 19:53:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 24 Aug 2015 19:53:20 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Aug 24 21:53:11 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZTxnr-0000Hb-87 for geh-help-gnu-emacs@m.gmane.org; Mon, 24 Aug 2015 21:53:11 +0200 Original-Received: from localhost ([::1]:56458 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZTxnq-0005R4-Rj for geh-help-gnu-emacs@m.gmane.org; Mon, 24 Aug 2015 15:53:10 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53941) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZTxmO-00041f-F4 for help-gnu-emacs@gnu.org; Mon, 24 Aug 2015 15:51:41 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZTxmJ-0002Ze-Al for help-gnu-emacs@gnu.org; Mon, 24 Aug 2015 15:51:40 -0400 Original-Received: from mailout01.t-online.de ([194.25.134.80]:37308) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZTxmJ-0002ZG-4h for help-gnu-emacs@gnu.org; Mon, 24 Aug 2015 15:51:35 -0400 Original-Received: from fwd08.aul.t-online.de (fwd08.aul.t-online.de [172.20.26.151]) by mailout01.t-online.de (Postfix) with SMTP id EFFB244A6E3; Mon, 24 Aug 2015 21:51:33 +0200 (CEST) Original-Received: from linux-k2bd.site (Ek+SJMZHwhSvC2zTcwR4azISgZ1y9GBnAxfQntYrtYBp-yRHu-66H9erUUW+NKCZfb@[81.62.204.224]) by fwd08.t-online.de with (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384 encrypted) esmtp id 1ZTxmB-0O9YLg0; Mon, 24 Aug 2015 21:51:27 +0200 User-Agent: KMail/4.14.10 (Linux/4.1.4-1-desktop; KDE/4.14.10; x86_64; ; ) In-Reply-To: <20150824190903.3079.0B60605E@ahiker.mooo.com> X-ID: Ek+SJMZHwhSvC2zTcwR4azISgZ1y9GBnAxfQntYrtYBp-yRHu-66H9erUUW+NKCZfb X-TOI-MSGID: 623daf10-4e9f-4e96-ba45-4a8260d1a9e1 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 194.25.134.80 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:106810 Archived-At: Am Montag, 24. August 2015, 12:14:51 schrieb Ian Zimmerman: > On 2015-08-24 21:02 +0200, AW wrote: > > Synclient on this notebook works, but this function doesn't: > > > > (defun turn-off-mouse (&optional frame) > > > > (interactive) > > (let ((inhibit-message t) (default-directory "~")) > > > > (shell-command "synclient TouchpadOff=1"))) > > > > (defun turn-on-mouse (&optional frame) > > > > (interactive) > > (let ((inhibit-message t) (default-directory "~")) > > > > (shell-command "synclient TouchpadOff=0"))) > > > > (add-hook 'focus-in-hook #'turn-off-mouse) > > (add-hook 'focus-out-hook #'turn-on-mouse) > > (add-hook 'delete-frame-functions #'turn-on-mouse) > > The variable inhibit-message doesn't exist in my emacs (probably a > recent addition), but I'm guessing that it discards any output from the > subprocess. I would leave it out so you see what prevents synclient > from working. > > Also, I don't see why changing default-directory should be necessary, > either. Trouble is, I don't speak Lisp. I'm just a user who gets lots of typos because of a touchpad which is too large. I found this code and more, tested it, but without any success....