From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Andy Moreton Newsgroups: gmane.emacs.devel Subject: Re: The netsec thread Date: Mon, 23 Jul 2018 14:31:32 +0100 Message-ID: References: <83bmb214ez.fsf@gnu.org> <837elq13me.fsf@gnu.org> <83h8kqwukq.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1532352620 7214 195.159.176.226 (23 Jul 2018 13:30:20 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 23 Jul 2018 13:30:20 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (windows-nt) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jul 23 15:30:16 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fhauk-0001me-Nk for ged-emacs-devel@m.gmane.org; Mon, 23 Jul 2018 15:30:14 +0200 Original-Received: from localhost ([::1]:34679 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fhawr-00027q-Gg for ged-emacs-devel@m.gmane.org; Mon, 23 Jul 2018 09:32:25 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53619) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fhawD-00027j-Ji for emacs-devel@gnu.org; Mon, 23 Jul 2018 09:31:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fhaw9-0004iM-KH for emacs-devel@gnu.org; Mon, 23 Jul 2018 09:31:45 -0400 Original-Received: from [195.159.176.226] (port=43094 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fhaw9-0004hu-C9 for emacs-devel@gnu.org; Mon, 23 Jul 2018 09:31:41 -0400 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1fhaty-0000uM-Pj for emacs-devel@gnu.org; Mon, 23 Jul 2018 15:29:26 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 30 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:FlXmbE1uR6lEP4sPWeFe7uNr/MY= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 195.159.176.226 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:227709 Archived-At: On Mon 23 Jul 2018, Lars Ingebrigtsen wrote: > Eli Zaretskii writes: > >>> From: Jimmy Yuen Ho Wong >>> Date: Mon, 23 Jul 2018 02:52:23 +0100 >>> Cc: Eli Zaretskii , Emacs-Devel devel >>> >>> That sound great, but what is this select-safe-coding-system and how >>> do I look at its UI? >> >> lisp/international/mule-cmds.el, look at >> select-safe-coding-system-interactively, a subroutine of >> select-safe-coding-system. In a nutshell, it prepares and pops up a >> buffer with special content, then prompts the user to select one of >> several alternatives. > > Hm... I ran: > > (select-safe-coding-system-interactively 1 3 (find-coding-systems-region 1 3) nil) > > and it just popped up a buffer with some text and then called > `read-coding-system', which is kinda close to what the NSM prompt is > doing already. Only the NSM prompt calls a y-or-n-p-equivalent, so that > you can't enter any other keys then the required ones ... except if you do press a different key, NSM gets stuck and does not accept new valid keys (other than ^G to quit). AndyM