From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Andrea Greselin Newsgroups: gmane.emacs.help Subject: Re: How to control pairing of quotes in text-mode with electric-pair-mode? Date: Fri, 12 Jul 2019 18:35:40 +0200 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="8770"; mail-complaints-to="usenet@blaine.gmane.org" Cc: Help Gnu Emacs mailing list To: Noam Postavsky Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jul 12 18:36:27 2019 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hlyX3-000222-Kt for geh-help-gnu-emacs@m.gmane.org; Fri, 12 Jul 2019 18:36:25 +0200 Original-Received: from localhost ([::1]:51140 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hlyX2-0005kO-BJ for geh-help-gnu-emacs@m.gmane.org; Fri, 12 Jul 2019 12:36:24 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51312) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hlyWy-0005k4-4w for help-gnu-emacs@gnu.org; Fri, 12 Jul 2019 12:36:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hlyWx-0005Mw-2t for help-gnu-emacs@gnu.org; Fri, 12 Jul 2019 12:36:20 -0400 Original-Received: from mail-pg1-x533.google.com ([2607:f8b0:4864:20::533]:40293) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hlyWw-0005Lo-SW for help-gnu-emacs@gnu.org; Fri, 12 Jul 2019 12:36:19 -0400 Original-Received: by mail-pg1-x533.google.com with SMTP id w10so4766898pgj.7 for ; Fri, 12 Jul 2019 09:36:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=OnikkWn7dAJgBBFT3uJGq/ObvBh018znGY5q/qffksI=; b=pFYCZwYi/aU+LaHt+lNXfnbZJM+rXInkN9//svyoA4hTdAv+SFSXz2WbHePd9ulLTB A94HrZi149A7Zzg4CiA/L5vtfFiS1TPKhFglU2LjFTs9dd6ogJSnEbQb3Pinrh5Be6XW s+f1D5cUiQvFqnMMfGiEOClK6cxuuWySp/KMWNLR5Jm4C9P4/vDAFuEzM1Krec3BCQny mnUb+SVh1oPgTbycVge1vwclJ6N/OF0k+Qd1rXrdBlL5pblnX0mSbVjdwxk4s8wJ27Mb /G7PzDXklsvkDpXmu3uwcbGryeNF0ONus7JOwunCWnxGWztpoUE0FiePtAIEM1wB5B4F HhCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=OnikkWn7dAJgBBFT3uJGq/ObvBh018znGY5q/qffksI=; b=l7lzUPPPUSlt9LBy8pUs6WKvSMHmk1EzEXeo+b4vp7utaZDhSV6wM/Wi4wPazBpjqV /YXw4UWKTau9jhWIPi6vSaIpB6QCngFoxEVz+z4ryI3T92nyi7fFjSDdWQSvGS+e/iVa SuMTocAVj/oXbaWmwroINd1r/w2/nt2bGoT18z1Ng0lc2R1xMSSIhoQboPoptxaocUYe uJE+tYA+sF47qIKtWCYpoxArYNf3kaJNheHXS/8FtUFq5DXjOANvu5pmUXy+2frtEjCm +LcvPrnvgits4nqdPNBURoUZ+Cs1pZOqVe82OhDZoM31yrUU/+VSIlrGT1cSlw20kYIl x1ww== X-Gm-Message-State: APjAAAU5X+nCUmo3EskHM0FyNuJ3QX7yvzJZmDkVVwE8Co3Uh9w3J8Al lU//NbSxh9fTKMGya1f8EftEhxULO2RKUQajMwM= X-Google-Smtp-Source: APXvYqy+gdOR7Wfgwsq/v1oQE0ERsmvxvaKk9Rs4gk6svdxCYdrD8h3gyEXI98dA8iQo+cg0E6VWtKxrI6+Zltb7wLw= X-Received: by 2002:a17:90a:fa18:: with SMTP id cm24mr12512724pjb.120.1562949376805; Fri, 12 Jul 2019 09:36:16 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::533 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 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.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:121164 Archived-At: Well, so be it. Thanks. On Thu, 11 Jul 2019 at 13:22, Noam Postavsky wrote: > On Fri, 5 Jul 2019 at 08:43, Andrea Greselin > wrote: > > > It works fine in 'emacs-lisp-mode' but it doesn't in 'text-mode': quotes > > are still paired around words. I've noticed that it's the same with > > 'electric-pair-inhibit-predicate' set to > > 'electric-pair-conservative-inhibit', which should suppress pairing at > the > > beginning of words: in 'emacs-lisp-mode' both parentheses and quotes are > > not paired at the beginning of words, but in 'text-mode' only parentheses > > pairing is suppressed. > > Looks like the predicate is not considered when the character comes > from electric-pair-pairs. In that case electric-pair-syntax-info > returns t for UNCONDITIONAL, and > electric-pair-post-self-insert-function doesn't call > electric-pair-inhibit-predicate. > > So I guess this is not possible right now. >