From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Arthur Miller Newsgroups: gmane.emacs.devel Subject: Re: Sv: Sticky tooltips Date: Mon, 05 Oct 2020 11:27:15 +0200 Message-ID: References: <83blhpl2xl.fsf@gnu.org> <834kngllb1.fsf@gnu.org> <83pn63iajn.fsf@gnu.org> <83v9fugl22.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39024"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Oct 05 11:28:01 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 1kPMml-0009wH-KX for ged-emacs-devel@m.gmane-mx.org; Mon, 05 Oct 2020 11:27:59 +0200 Original-Received: from localhost ([::1]:40828 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kPMmk-0001fO-LD for ged-emacs-devel@m.gmane-mx.org; Mon, 05 Oct 2020 05:27:58 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50902) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kPMmC-0001FN-M4 for emacs-devel@gnu.org; Mon, 05 Oct 2020 05:27:24 -0400 Original-Received: from mail-am6eur05olkn2084.outbound.protection.outlook.com ([40.92.91.84]:54593 helo=EUR05-AM6-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kPMm8-0007Oh-K1; Mon, 05 Oct 2020 05:27:24 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iIhWudO0ybOek0TRtrxbpsLLV8zfqKKJeebgIIfX0pdUL/on8vlVc7FF8Eb5VdXD5I+vPCpj+tX69GQ6En7YNFslK6KruBGzjGsnFze6fEA+9AvTH9hVnLQ30VsnmLwVEIcsGbP3Ji0jMN/V/8fqysvXFR74C7kVXf2XDQeL/JuQqHytc+1uZQhE8BakheGFQlYT7Nk39jVb9qeaVMpNMJDh/OuCTp/jqysVUkCOAtOJbKFmrGrfe/6Gl6aTlB4K3JuQ0RDFvh9JaIRYDZLi6Xciv5FXcXv5hmHOXR3EfuzlBTsTY2WPnZsE6GZBr/Q1rl0jBmjHCVX9+dOodefUqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=QSFORbQRlbih0M+8as95+jEDaWVVg1qeGLlHHnkoh5Q=; b=GV44HnERa3BzbvYtICfzcv5f0VQksKy705TEyNCKRLVd6GmlTjtiRUglXLWzb4QrQIarLdH76okxvTWMHIJGYPkLjEyX3MTKNx168t5yiQ1GkRY5WmwyohnnYzKGEZWt09Iu1oXdHbaepfn1/XI+aBz5A0uNfZjkTvqcNJ18PIt6+e1fFkd4ERpgIO6gP2VfR5Hg4HtP8JRZk1CLr+/K5Iov8Tiw+pAP1OohKibjpM2m1s10ZwyWuOdlJ1y07SksquF8/sBZZ2OsEMZ/vA8xhKYhJbptoTfqQlvKU6+9HvjL8D2QHdv9qUI/R7pi/uic84SHEe4VDi1sIupd/vpX6w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=live.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=QSFORbQRlbih0M+8as95+jEDaWVVg1qeGLlHHnkoh5Q=; b=JLT663tIlp3FaSJaKqGuHaxUM0oalT1c/yT07U1paYGuARh/toFkfuxaNJ8PzMbsUuktBEgswxKXuMVZgYnpisP039F3dcP/5FBKeltt/9Qouz9bpglfkq4eXBUPMI892mVu0mqqWWymMIcQEHwttH7dfT0nWANBWoAs0rwSF6T/hkxIMfaCmmmIfSD5iNGgOIE2sCe7dZNLlA8uXZ0foN4/HfoLCGRnB68rdQkJAf4EJ4BM/6N2AcVH8vNMHF1Uodh8swAMKIDlOJAiB9z/lW8YvbcRCOGgDD41M66x8FrJzN3bH5ETKZrU4AX+qW9j/IzLKiYRwMuHw4qVoZRnEA== Original-Received: from AM6EUR05FT020.eop-eur05.prod.protection.outlook.com (2a01:111:e400:fc11::49) by AM6EUR05HT011.eop-eur05.prod.protection.outlook.com (2a01:111:e400:fc11::432) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3433.34; Mon, 5 Oct 2020 09:27:16 +0000 Original-Received: from VI1PR06MB4526.eurprd06.prod.outlook.com (2a01:111:e400:fc11::49) by AM6EUR05FT020.mail.protection.outlook.com (2a01:111:e400:fc11::361) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3433.34 via Frontend Transport; Mon, 5 Oct 2020 09:27:16 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:7198C469DC7EC16F7E6FEAF120BD341BBC3A05AC6EFD6967461D78856D26D127; UpperCasedChecksum:C07138D55036D4921DA4BBD3EB1096460FF3ABE2E5A0F398462A6C913B494F2A; SizeAsReceived:7750; Count:46 Original-Received: from VI1PR06MB4526.eurprd06.prod.outlook.com ([fe80::b547:51cd:16c5:4487]) by VI1PR06MB4526.eurprd06.prod.outlook.com ([fe80::b547:51cd:16c5:4487%7]) with mapi id 15.20.3433.044; Mon, 5 Oct 2020 09:27:16 +0000 In-Reply-To: <83v9fugl22.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 01 Oct 2020 15:58:13 +0300") X-TMN: [BslCXyUfKViTWn2loX9cB1Evg9zb/3n6] X-ClientProxiedBy: BE0P281CA0021.DEUP281.PROD.OUTLOOK.COM (2603:10a6:b10:14::8) To VI1PR06MB4526.eurprd06.prod.outlook.com (2603:10a6:803:ac::17) X-Microsoft-Original-Message-ID: <87v9fpuioc.fsf@live.com> X-MS-Exchange-MessageSentRepresentingType: 1 Original-Received: from pascal.homepc (90.230.29.56) by BE0P281CA0021.DEUP281.PROD.OUTLOOK.COM (2603:10a6:b10:14::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3455.15 via Frontend Transport; Mon, 5 Oct 2020 09:27:16 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 46 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: 54838f94-44cf-4fb1-7551-08d86910d99c X-MS-TrafficTypeDiagnostic: AM6EUR05HT011: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: HfJ/nZpcuxju+wh0pKiA/akTF4GixSzJ/3F7iywnC1vctwD/G/cQK/pp+VepNcb1G/xchxyJAYVpGjFw7ytOiEhv0InTquy4m8WqkUBVWIatktZXyL7k/Rs6f27sZO5SP7dEBLuSbn2Ao0JpJWn2EecYu5mdaMz4etyzArFSZVGDFJ4WhYQpro5Cycwvt1581pfFKXi92AaVK0WXuXbMow== X-MS-Exchange-AntiSpam-MessageData: T9TQVFG2GS2LrQbQR+7exJR9jri+3ofkTRKORPvW1SUyGhRZZxxviqqmdCx/s4yQZeiGNLgTOh764d+6hsyOM842K9OuX2Tk+QNDk9qEfO9l7ri4WXTMZHCNBoknio/HjVWUixrg/V90D4ZbFxRG1w== X-OriginatorOrg: live.com X-MS-Exchange-CrossTenant-Network-Message-Id: 54838f94-44cf-4fb1-7551-08d86910d99c X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Oct 2020 09:27:16.8315 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: AM6EUR05FT020.eop-eur05.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6EUR05HT011 Received-SPF: pass client-ip=40.92.91.84; envelope-from=arthur.miller@live.com; helo=EUR05-AM6-obe.outbound.protection.outlook.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/10/05 05:27:17 X-ACL-Warn: Detected OS = Windows NT kernel [generic] [fuzzy] X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no 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:257092 Archived-At: Eli Zaretskii writes: >> From: arthur miller >> CC: "emacs-devel@gnu.org" >> Date: Thu, 1 Oct 2020 02:28:25 +0000 >> >> I am not sure how to get buffer out of x-show-tip, > > ??? The name of the buffer is fixed: " *tip*" (with the leading > space). You can even switch to it interactively, and see the text > there (it would be the text of the last tootlip displayed), provided > that your build is not GTK, or if it is GTK, you've turned off GTK > tooltips and switched to the native ones. > >> I don't know how the function would deal with Gtk tooltips; if they can also take a buffer >> and display it, that is why I mean the function to take string-or-buffer. > > We'd need to modify the code to stash the tooltip text in some buffer > or variable. It was actually even easier; C code can just get ready-made-buffer on it's own, does not even need it passed in as argument; and for Gtk, nothing changes, a string can be send and it does not need to be propertized. I've sent yesterday patch in another thread; I can resend in this one if it is preferable. Where do I find the mouse motion callback for tooltips? The idea is to not dismiss the tooltip frame during the timer period so that user have time to tick the checkbox. When timer times out then the tooltip frame can be dismissed. And if checkbox was ticked, the frame will be dismissed when user uncheck the box. This also leaves question how it will behave if a tooltip frame is live on the screen and another tooltip frame is "requested". I haven't looked into C code to see if multiple tooltip frames can be live or not; can take a look after the mouse motion callback is fixed. Today I have also removed some unnecessary 'propertize' call, but it is not essential so I can send it in later.