From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: pietru@caramail.com Newsgroups: gmane.emacs.help Subject: Toggle appointment notification Date: Tue, 1 Dec 2020 04:47:55 +0100 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="31664"; mail-complaints-to="usenet@ciao.gmane.io" To: Help Gnu Emacs Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Tue Dec 01 04:50:22 2020 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kjwgH-0008A6-QT for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 01 Dec 2020 04:50:21 +0100 Original-Received: from localhost ([::1]:60664 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kjwgG-0004QR-95 for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 30 Nov 2020 22:50:20 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48812) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kjwe1-0004QL-UL for help-gnu-emacs@gnu.org; Mon, 30 Nov 2020 22:48:01 -0500 Original-Received: from mout.gmx.net ([212.227.15.18]:46333) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kjwdz-0005u7-Sv for help-gnu-emacs@gnu.org; Mon, 30 Nov 2020 22:48:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1606794475; bh=Z/4dCSrnTmEwYpojyVfqTesBJx1UjXRN24hltPRhZws=; h=X-UI-Sender-Class:From:To:Subject:Date; b=PoXUCH311gL0KjixjmuabQzprO7zD+HLFx6PXbLRMWhw96E9alpX4+GdVXSymow+d pK1FWgvpb8xpgfjJgkNfHU4wpoPG06X24Q9D2iwpfAAmcBM5cGISmq8VDxu8ltHuJE W39MBl1guv4k1H7kL39v1IR7/4zFlMIGZNBzfngk= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [213.165.168.94] ([213.165.168.94]) by web-mail.gmx.net (3c-app-mailcom-bs05.server.lan [172.19.170.173]) (via HTTP); Tue, 1 Dec 2020 04:47:55 +0100 Importance: normal Sensitivity: Normal X-Priority: 3 X-Provags-ID: V03:K1:Bwele4m6PDnPEoGDOFdZhD8dbOGJmksUg49GyzS/FXdVT9ybTi9p4dtQz9QBIg7uKWnni We2hChPxpVe9HymeM/tg74xhErrkpDa9GpTYOl8yX2CTLS+OEIqDsK/J00wgvW/yk/K5iFxUXlQX QJA8uJg7QxqsCP1edD3o2wzBlyzozKEiyQ68BFlST32F0rud14YbUjxRni0bO0UznO9orIUeAtqp 0O+/u/vjuesFYpDrfdvDljGe+0u7Z3blPzeM0G9RqDlyMfulO6b3yjwIsbvA2qnhMPki2/NYpMFV Cc= X-UI-Out-Filterresults: notjunk:1;V03:K0:gNb7/S34Dfg=:Kg028ZQ+WkKAnZl6OgmRb3 0fW6HmhPbnAPs6IczNMhmdh7EWA1uy0LxG//nm0i5fBLm1N9/Z3nTWmYYW1Otb7c9KD4cbX51 3292gNodbSicT8myZ2cYAf1lGDj4PgwF2ByXpFI7+FQnYz6oyz4DE5f7UhtbYqpTf1EgtUwCo d9Ag0d9CgsbBKbbd4OSJp7fVErsTPxhnB8TNzoY4XVwfQymNrnOzinfHVN2LQJf3xjJRl1WE2 +F4wX9PY9R8EXmpSINHl69PD950DvTelQS99SPb5Pg7/H2HysxlSmzwqHlN91CZTPnBPIF4KO hfF7lU0+sDxxr+lGispEZV3l+aqNEY0tMvdU2WqPzR7l7nEN2z5wwX1kFs/yTFZNFcdImgf/U eU8VFC6u88A2u8xi6k3s7YFdOHBouCmup84yQzRk7wYTjirSFpFOfVkB/007Z9zmnAzUv1c0Y h78JBe3tymAilRCrYrEyki5AAC7L8ooRY6KAXZqK3IUKZW+CY87dN1syPqITaWkjnYGhiSqXN pUYIng4WZXdSzRE/5Z4LtZS2RQbrMt5s2cBS41WGnbsGwOCi/GKJSraP0JS3c9g22Tyrfcgf6 Dmo84WEnULB7g= Received-SPF: pass client-ip=212.227.15.18; envelope-from=pietru@caramail.com; helo=mout.gmx.net X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:125784 Archived-At: Want to toggle between enable and disable appointment notification and have put a defun as so below. I reckon that both appt-activate and appt-check are needed but not absolutely aware of what and how they activate things for appointments. What would be a right approach to toggle between enable and disable using a single key-sequence for my case here? (defun diary-appt-ntf (n) "Switches diary appointment notification." (appt-activate n) ; Activates diary appointment notification (if (< n 1) (appt-check 1) ; Checks appointments and updates reminders. (appt-check nil)) ; Disables appt-check )