From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.devel Subject: Re: scratch/tzz/auth-source-reveal-mode 4a7c98d 3/3: Create and document auth-source-reveal-mode Date: Mon, 22 Jun 2020 20:39:47 +0000 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: References: <20200622191653.26453.39420@vcs0.savannah.gnu.org> <20200622191656.2D20920A26@vcs0.savannah.gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="96405"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) To: emacs-devel@gnu.org Cancel-Lock: sha1:R9+rSWmJmuxfJeroZ6KXFUt+PwM= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Jun 22 22:41:12 2020 Return-path: Envelope-to: ged-emacs-devel@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 1jnTFg-000OLY-P0 for ged-emacs-devel@m.gmane-mx.org; Mon, 22 Jun 2020 22:41:12 +0200 Original-Received: from localhost ([::1]:48530 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jnTF1-0004FP-2R for ged-emacs-devel@m.gmane-mx.org; Mon, 22 Jun 2020 16:40:31 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47752) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jnTEU-0003kx-Lb for emacs-devel@gnu.org; Mon, 22 Jun 2020 16:39:58 -0400 Original-Received: from ciao.gmane.io ([159.69.161.202]:42984) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jnTET-00064r-1k for emacs-devel@gnu.org; Mon, 22 Jun 2020 16:39:58 -0400 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1jnTEP-000Naa-F3 for emacs-devel@gnu.org; Mon, 22 Jun 2020 22:39:53 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6; d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" Mail-Copies-To: never Received-SPF: pass client-ip=159.69.161.202; envelope-from=ged-emacs-devel@m.gmane-mx.org; helo=ciao.gmane.io X-detected-operating-system: by eggs.gnu.org: First seen = 2020/06/22 15:50:04 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -8 X-Spam_score: -0.9 X-Spam_bar: / X-Spam_report: (-0.9 / 5.0 requ) BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:252519 Archived-At: On Mon, 22 Jun 2020 16:03:31 -0400 Stefan Monnier wrote: >> + (setq-local >> + prettify-symbols-compose-predicate #'auth-source-reveal-compose-p) SM> This erases any prior configuration of that variable, so it won't "play SM> ball" with other users. Is it better do what tex-mode.el does? (add-function :override (local 'prettify-symbols-compose-predicate) #'tex--prettify-symbols-compose-p) >> + (prettify-symbols-mode (if auth-source-reveal-mode 1 -1))) SM> And here we forcefully enable/disable `prettify-symbols-mode` even if SM> all the user wanted if to hide the passwords. SM> I think we need to decouple the two user-level features. The plan was to make `prettify-symbols-mode' a library that other modes like `auth-source-reveal-mode' can use. I went halfway, creating some API-like functions. Are you suggesting that library is needed now to avoid the tight coupling? Or something else? Thanks Ted