From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "T.V Raman" Newsgroups: gmane.emacs.devel Subject: Re: Need help with eldoc: Date: Thu, 24 Mar 2022 19:21:32 -0700 Message-ID: <25149.10028.97873.940861@google.com> References: <25149.276.56904.499053@retriever.mtv.corp.google.com> <87ee2qevjs.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40366"; mail-complaints-to="usenet@ciao.gmane.io" Cc: raman@google.com, emacs-devel@gnu.org To: joaotavora@gmail.com Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Mar 25 03:22:35 2022 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 1nXZb0-000AHQ-4A for ged-emacs-devel@m.gmane-mx.org; Fri, 25 Mar 2022 03:22:34 +0100 Original-Received: from localhost ([::1]:54870 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nXZay-0000uh-HO for ged-emacs-devel@m.gmane-mx.org; Thu, 24 Mar 2022 22:22:32 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:44628) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nXZa7-0000FD-5C for emacs-devel@gnu.org; Thu, 24 Mar 2022 22:21:39 -0400 Original-Received: from [2607:f8b0:4864:20::531] (port=34495 helo=mail-pg1-x531.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nXZa5-0002Tq-F6 for emacs-devel@gnu.org; Thu, 24 Mar 2022 22:21:38 -0400 Original-Received: by mail-pg1-x531.google.com with SMTP id t4so2247910pgc.1 for ; Thu, 24 Mar 2022 19:21:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=from:mime-version:content-transfer-encoding:message-id:date:to:cc :subject:in-reply-to:references; bh=etj7fGXB9bAlV8hE8EmNeJVA75Tnxs1oW6SuZ/MwSOI=; b=jxL4Vv9FCPlYzmz1aIyAwR+VO39e2AMOboX92iY5WZ7pD8sKH83fUpB7a2uhbtgkyP 17TrmDPpxh7Jem/4k5iGlzgJDJ3z8VCQosQYBTiYxuSkZWshQOzL494rjOkUAYW0+GI6 Sm8QFemRuJTI41mJdpxHNX8ncNIdxhLP2DJC3yCAfvNOlhVdvqUwZr6NtEqhLD7nKHRq I1vCqNaH8gdFZ0s/puaMi30ES1J5/q9hFuT3QqOsax09acwawOxE7qwrdVejtSQ72WF+ sYXPWH52DoL2O3+Ti2x5iQK3bHSzt4iEnnmyMj5E+DbiKSkCejpA/quW+HcBjUmbBXXq Il6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:mime-version:content-transfer-encoding :message-id:date:to:cc:subject:in-reply-to:references; bh=etj7fGXB9bAlV8hE8EmNeJVA75Tnxs1oW6SuZ/MwSOI=; b=ju8rOLNTo0xywjk8N6SvCPLegJjggfLzQEQE2Mutv6j7UqEy/ZmjZcT4U5v1dMqpmH rRriGLWkSmHOD9lkiqOev1WL0mhjrNBAT2VdPCmCDp9rUbweaoao6hagNABU8GJp04oo 7gMXPVK6AJ1+9lib3xhAJTpshgkb2GaA4Vv6K9AKyc8Mcb31h8tiL8OdHYtBr2a/5G2Q TxzUyyVWFjDlU8o44rIB5ZbK9dQ5aEs2WCv+qQO3aHaf5UrtfqdDWXsmO7/724yuWp5y sk0t3cE5uIbQt3f1DWG1X8TN9a/+4Pqt6uUIDaYPSjuUHK+TDMb17uAuffIEZOQw8z9P UBHg== X-Gm-Message-State: AOAM532s4Sf6chsSHVxcFIgTapv0upnbilJxKZmm8xg120sZg0unzmec wxWKpzI5HDMAYMcpA+zMvcz9EnlTfj+K6Q== X-Google-Smtp-Source: ABdhPJxp8PRCZQaDz83BaL6UxmB/OOeq/FzD8k0v+gEDjwQv1JZG2T2ufS4BdWJKnE51YwEuP/+XQQ== X-Received: by 2002:a63:9b1a:0:b0:386:25a7:a377 with SMTP id r26-20020a639b1a000000b0038625a7a377mr6316420pgd.514.1648174895530; Thu, 24 Mar 2022 19:21:35 -0700 (PDT) Original-Received: from raman-glaptop (c-24-4-174-65.hsd1.ca.comcast.net. [24.4.174.65]) by smtp.gmail.com with ESMTPSA id p3-20020a056a000b4300b004faee36ea56sm3734048pfo.155.2022.03.24.19.21.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Mar 2022 19:21:34 -0700 (PDT) In-Reply-To: <87ee2qevjs.fsf@gmail.com> X-Mailer: VM 8.2.0b under 29.0.50 (x86_64-pc-linux-gnu) X-Host-Lookup-Failed: Reverse DNS lookup failed for 2607:f8b0:4864:20::531 (failed) Received-SPF: pass client-ip=2607:f8b0:4864:20::531; envelope-from=raman@google.com; helo=mail-pg1-x531.google.com X-Spam_score_int: -161 X-Spam_score: -16.2 X-Spam_bar: ---------------- X-Spam_report: (-16.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, ENV_AND_HDR_SPF_MATCH=-0.5, NICE_REPLY_A=-0.001, PDS_HP_HELO_NORDNS=0.659, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, USER_IN_DEF_DKIM_WL=-7.5, USER_IN_DEF_SPF_WL=-7.5 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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:287428 Archived-At: So this was very easy to get working, I'd like you to take a look. I discovered custom option=20 '(eldoc-echo-area-prefer-doc-buffer t) --- this i good for the emacspeak user who can see a little since they can look at the buffer -- and it doesn't disturb or distract the totally blind user. I then went ahead and implemented the function as you suggested -- see https://github.com/tvraman/emacspeak/blob/master/lisp/emacspeak-advice.= el -- search for "eldoc" to jump to the relevant portion.=20 I'd like some feedback for the following: 0. I cloned your display in a buffer function 1. changed it to use with-temp-buffer=20 3. rendered the doc there and asked it to speak it. 4. if called non-interactively I just play a short sound to say something is available=20 5. And then bound eldoc to a key=20 This all works, but it could well be simpler now that the above works. If I could be ensured of the eldoc always being in a buffer I could eliminate most of the above, but I am also afraid that that will recreate the earlier async problem which is why I didn't go there. So modulo not yet having figured out the empty doc-string case, this works well for me for now. --=20 Thanks, --Raman(I Search, I Find, I Misplace, I Research) =E2=99=89 Id: kg:/m/0285kf1 =F0=9F=A6=AE -- Thanks, --Raman(I Search, I Find, I Misplace, I Research) ♉ Id: kg:/m/0285kf1 🦮