From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#36232: 26.2; (elisp) `Click Events': OBJECT "string-type text property" etc. Date: Sun, 16 Jun 2019 11:32:24 -0700 (PDT) Message-ID: <94ee0170-93a4-425c-a8c2-2608296860ed@default> References: <> <<83fto9v989.fsf@gnu.org>> <83a7ehv3dv.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="20331"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 36232@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jun 16 20:47:58 2019 Return-path: Envelope-to: geb-bug-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 1hcaC5-0005AO-Rz for geb-bug-gnu-emacs@m.gmane.org; Sun, 16 Jun 2019 20:47:57 +0200 Original-Received: from localhost ([::1]:42118 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hcaC4-00086P-Tz for geb-bug-gnu-emacs@m.gmane.org; Sun, 16 Jun 2019 14:47:56 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59168) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hcaBZ-0007WV-MZ for bug-gnu-emacs@gnu.org; Sun, 16 Jun 2019 14:47:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hcZxe-00035a-BQ for bug-gnu-emacs@gnu.org; Sun, 16 Jun 2019 14:33:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56111) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hcZxe-00035I-8Q for bug-gnu-emacs@gnu.org; Sun, 16 Jun 2019 14:33:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hcZxe-0007A7-54 for bug-gnu-emacs@gnu.org; Sun, 16 Jun 2019 14:33:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 16 Jun 2019 18:33:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 36232 X-GNU-PR-Package: emacs Original-Received: via spool by 36232-submit@debbugs.gnu.org id=B36232.156070995727496 (code B ref 36232); Sun, 16 Jun 2019 18:33:02 +0000 Original-Received: (at 36232) by debbugs.gnu.org; 16 Jun 2019 18:32:37 +0000 Original-Received: from localhost ([127.0.0.1]:41422 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hcZxF-00079P-50 for submit@debbugs.gnu.org; Sun, 16 Jun 2019 14:32:37 -0400 Original-Received: from userp2130.oracle.com ([156.151.31.86]:37324) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hcZxC-000795-IV for 36232@debbugs.gnu.org; Sun, 16 Jun 2019 14:32:35 -0400 Original-Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5GISxF5099156; Sun, 16 Jun 2019 18:32:27 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=0p+mEmKKnEh1UB7tqVnnHLQiR5s3r9cUMdL6CI1VDMQ=; b=vcjbYzn6r0gMcqos7knb1VspJVwn9acQB9AYYnR8WU754x/ekpd6URgHUGN3RrE2KqDn NE+Lno4VkrashrkHsLjTvR/PsFqVH1Ii9T0B9YjEt5YQbgRh6NJeabA9OK4CsGchdK7O moESPkg+z4+uglU91BIZkTuSVhQADxlnKSJbR/YKx6ae2yCjSEB6f+FYXgKPSQcJuwCA DzECH/V4kbshVjYl7dkSgoyEVHauOBZDK1YSVlEIrHRn3IN/x/Qe/Sk7LUnU3ZQIYhUM /Yx+W3akAitf8b/YfDXp/oyDrTl9BWXRiiNkC8VbKQ5RGoCIPDZVaIBXk62n4kVQeykm rA== Original-Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by userp2130.oracle.com with ESMTP id 2t4r3tbcnf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 16 Jun 2019 18:32:27 +0000 Original-Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5GIVGpW169157; Sun, 16 Jun 2019 18:32:26 GMT Original-Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by aserp3030.oracle.com with ESMTP id 2t5cpd555u-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 16 Jun 2019 18:32:26 +0000 Original-Received: from abhmp0002.oracle.com (abhmp0002.oracle.com [141.146.116.8]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x5GIWP1J026306; Sun, 16 Jun 2019 18:32:25 GMT In-Reply-To: <83a7ehv3dv.fsf@gnu.org> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4861.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9290 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906160178 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9290 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1011 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906160179 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:160683 Archived-At: > > > > Which text properties are string-type text properties? > > > > > > It's a string that comes from a text property or from an overlay. > > > > "At the click position" there is no string (AFAIK). > > There is only buffer text with text properties or > > an overlay with text properties. > > > > And there is no "string which was clicked on". >=20 > When the text or overlay properties specify a string to display, that > string is displayed instead of, or in addition to, buffer text. And > then you definitely CAN click on some character from such a string on > display. Is that really what this is all about? I guess you're talking about a "replacement" `display' property value that's a string. (You're still not clicking a string. You're clicking the displayed text of the string. This is not to be pedantic; it's to say that the text quoted is unclear to confusing.) > > And in any case, there is no such thing (is > > there?) as a "string-type text property". >=20 > There is such a thing, but since you were confused, I replaced that > text with something more specific. Thanks. I'd still like to know what you are calling a "string-type property". From above, are you talking about property `display'? > > If there is, then which text properties are > > "string-type" properties? >=20 > What I said above. It isn't very clear/explicit. Are you just talking about property `display'? If not, what? > > > > 1. Why call that OBJECT instead of, say, > > > > STRING-INFO? What kind of object is it? > > > > If the value is nil doesn't it just mean > > > > that a string was not clicked on? > > > > > > Because nil stands for a buffer, not just for the lack of a string. > > > > So what? If it stands for a buffer then say so. >=20 > The new text does. Good; thanks. > > Still, doesn't nil just mean that something besides > > buffer text (e.g. an image?) - and certainly not a > > string (IIUC) was what was clicked? >=20 > No, it means buffer text. Not if it means clicking what property `display' shows. That's not buffer text (chars in the buffer). > > Do you really think that introducing (and without > > explaining/describing) "OBJECT" here helps? I > > don't see how it does. It didn't help me, in any > > case, as one user trying to understand - quite the > > contrary: it left me scratching my head, rereading, > > scratching, and filing this enhancement request. >=20 > I'm sorry it didn't help you, but I want at least to make sure it > doesn't get in your way. I can certainly envision readers who would > be helped by that (I'm one of them, btw). It might really help, including me, but only, I think, if it says what it means by "object". > > Which text properties (and apparently overlay > > properties as well) are "string-type" - and as > > opposed to what other property "types"? Do you > > mean text properties whose _values_ are strings? >=20 > Among others, yes. One example is the 'display' property whose value > is a string, a.k.a. "display string". Another example is the > 'before-string' overlay property. OK, now it's becoming more clear. I don't think you should assume that that will be understood by just referring to "string-type" properties. Overlay properties are not text properties. The same property can sometimes be used for either, but here we're talking about what is the "OBJECT". If it can be (or contain) an overlay property, OR a text property, whose value is a string, then I'd suggest that be said, and not suppose that will be understood by "string-type text property". > > > > `posn-object-x-y' is described as coordinates > > > > relative to a corner of "the object in POSITION" > > > > - what kind of cornered object is this, and > > > > what/where are its "corners"? > > > > > > Every object on display, be it a character glyph, a display string, > > > an image, or anything else, has 2 dimensions, which means it has 4 > > > corners. > > > > So OBJECT means an "object on display"? >=20 > No, it means an object that caused something to be displayed. That > something then has corners. Then the object itself (e.g. string, nil, cons) does not have corners. The text should talk about the displayed thing that the Lisp object caused to be displayed. Too many shortcuts, too many assumptions that a reader will figure out what invisible jumps you're intending. > > > > And "if the POSITION is on buffer text" (huh? > > > > a position on text?) > > > > > > POSITION describes a click, remember? > > > > Yes, I know. The wording is weird. Why not say > > "if POSITION comes from clicking buffer text" or > > similar? >=20 > See the new text, you might even like it. As I said, I'm sure it will be an improvement. Your taking a closer look at the existing text and trying to make it clearer is all I can or would ask for. > > POSITION is a Lisp value. It's not "on buffer > > text", IIUC. >=20 > That's why the new text says something more clearly and less vaguely. Got it; thanks. > > > > then it returns "the relative position of the > > > > ... character closest to that position." > > > > Unintelligible to me. There must be a clear > > > > way of saying what this is trying to say, > > > > whatever that is. > > > > > > I hope the modified text is more clear. > > > > Oh, did you modify the text? Thank you for doing > > that. What is the new text? >=20 > See here: >=20 > http://git.savannah.gnu.org/cgit/emacs.git/commit/?h=3Demacs-26&id=3D47= 01e0663ee53f1c4b1e1e4c5fee9e597671800b That's a zillion times clearer. Good. > (Is it possible to agree with you that you look in the repository > before following up to your reports?) I wouldn't know where to look. And I didn't know that you had already made the corrections. And it's not very easy to reconstruct the text from the diff, mentally. Trying to make you aware of what I found unclear or confusing is the purpose of the bug report. If/when you can understand my description of what I find unclear then that's really enough, generally. I have confidence that you will DTRT. Of course, sometimes there can be disagreement, but generally not when it comes to doc clarity and purpose. > > "Either of the formats" does mean that (two). >=20 > Not to me, but that's a moot point, because that text is now gone. OK. Just FYI: https://www.dictionary.com/browse/either https://www.google.com/search?q=3Deither+definition > In the repository, as usual; see above. I suggest to bookmark the > cgit URL, because these questions pop up all the time, and the answer > is always the same. See above. I don't use GIT so I can only see the individual changes, which are out of context. Anyway, thanks; I've bookmarked this now:. http://git.savannah.gnu.org/cgit/emacs.git/commit/?h=3Demacs-26