From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.bugs Subject: bug#51490: Show an indicator when Emacs is busy somewhere in the Emacs window Date: Thu, 22 Sep 2022 15:57:04 +0000 Message-ID: References: <87pmrtz1y7.fsf@gnus.org> <83pmrt1bsa.fsf@gnu.org> <87y26hxm8a.fsf@gnus.org> <87k0hvviiu.fsf@gnus.org> <87a6iqr8il.fsf@gnus.org> <87r107nmq7.fsf@gnus.org> <83y1uewa55.fsf@gnu.org> <87fsgl7zri.fsf@gnus.org> <83illhueuo.fsf@gnu.org> <87wn9x543a.fsf@gnus.org> <83bkr8vpwy.fsf@gnu.org> <87bkr8am4o.fsf@gnus.org> <834jx0vnam.fsf@gnu.org> <2d1b683c22a3585f038d@heytings.org> <83sfkku29t.fsf@gnu.org> <2d1b683c22d98c9cabd3@heytings.org> <83edw3udmh.fsf@gnu.org> <87pmfn7k7i.fsf@gnus.org> <83fsgjsi55.fsf@gnu.org> <831qs3sdz6.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3537"; mail-complaints-to="usenet@ciao.gmane.io" Cc: larsi@gnus.org, stefan@marxist.se, 51490@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Sep 22 19:37:28 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1obQ8d-0000fg-Oc for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 22 Sep 2022 19:37:27 +0200 Original-Received: from localhost ([::1]:42674 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1obQ8c-00055C-NS for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 22 Sep 2022 13:37:26 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41586) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1obOaR-00067G-QF for bug-gnu-emacs@gnu.org; Thu, 22 Sep 2022 11:58:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:39187) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1obOaQ-0004lg-Fr for bug-gnu-emacs@gnu.org; Thu, 22 Sep 2022 11:58:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1obOaQ-0002Aa-Am for bug-gnu-emacs@gnu.org; Thu, 22 Sep 2022 11:58:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gregory Heytings Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 22 Sep 2022 15:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51490 X-GNU-PR-Package: emacs Original-Received: via spool by 51490-submit@debbugs.gnu.org id=B51490.16638622298266 (code B ref 51490); Thu, 22 Sep 2022 15:58:02 +0000 Original-Received: (at 51490) by debbugs.gnu.org; 22 Sep 2022 15:57:09 +0000 Original-Received: from localhost ([127.0.0.1]:38263 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1obOZY-00029G-OW for submit@debbugs.gnu.org; Thu, 22 Sep 2022 11:57:09 -0400 Original-Received: from heytings.org ([95.142.160.155]:54222) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1obOZV-000294-Gq for 51490@debbugs.gnu.org; Thu, 22 Sep 2022 11:57:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20220101; t=1663862224; bh=gLAkwq6FbgWyeiupNWf8wrl0kYdC2dVyIe4NwWtCUIM=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=r0jXLThOv55wtVG9it88T1v9hWx/CrofUSn15aEvRL7xrMUDJGyicUsQIfM8uEStp o8szNC1gvTtDLJi1l/FJnM965G8Dc1hA1kfgqdiZqQprFGvnzY7VYOrDHbY+cpaiEv 0BPDyAg6JBTnUs5IYWqXm9eO3+xepov2KqWgA6NTD+CM5eg45+YheAhiGMRjhPzLu1 2asy5ygjs03BlvDmzVFadR2ZCF4ORUq4pLbQECRQMdiOX7Aaq3/I//uVVSvfFVYdsj 2TBIDWDzBmGdwX1JT7WNr+rhrgONcRzyMwALuRO88Ewpb92T95amgf3wN+aY0ETlda Xmr2IXHyvyQ9g== In-Reply-To: <831qs3sdz6.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:243429 Archived-At: >> I'm thinking aloud here, sorry if it isn't useful. But I think we have >> at least one similar occurrence: XTflash. > > Which part of it seemed similar to what is being discussed here? > The fact that a portion of the frame is modified without a complete redisplay of the frame, through primitive drawing functions? Am I missing something? Would it not be possible to draw a busy indicator at a fixed position of the frame with XDrawRectangle for the background, followed by XDrawPoints for the foreground? >> But would it be really necessary to access these faces each time the >> indicator would be drawn? We could for example cache the values of >> these two colors somewhere > > Faces are already cached. But for each cache there comes a time when it > must be flushed and/or refreshed, and during those times you cannot > safely use the cache. > What I had in mind is a more primitive cache mechanism: two C variables. >> or decide to do something different and use a specific function to set >> these two colors without going through the whole face machinery, >> something like (set-busy-indicator-colors FOREGROUND BACKGROUND). > > As soon as we allow set-busy-indicator-colors or somesuch, we have a > problem with Lisp programs doing that exactly when there's time to > redraw the indicator. > We could specify that set-busy-indicator-colors is only meant to be used in init files, for example.