From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Jason Rumney Newsgroups: gmane.emacs.devel Subject: Re: Tooltips on w32 slow and strange Date: Tue, 15 Feb 2005 14:19:17 +0000 Message-ID: <421204E5.4070503@gnu.org> References: <016b01c51163$45e1d630$0200a8c0@sedrcw11488> <16186.217.194.34.123.1108368907.squirrel@wwws.franken.de> <4210762C.9030203@gnu.org> <003a01c5129c$c2c55e80$0200a8c0@sedrcw11488> <01c512d3$Blat.v2.4$ddc805c0@zahav.net.il> <01c51319$Blat.v2.4$54fb6980@zahav.net.il> <34459.217.194.34.123.1108457620.squirrel@wwws.franken.de> <4211C8BD.2000206@gnu.org> <4051.217.194.34.123.1108462308.squirrel@wwws.franken.de> <01d301c51364$92cddef0$0200a8c0@sedrcw11488> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2013788204==" X-Trace: sea.gmane.org 1108478280 21192 80.91.229.2 (15 Feb 2005 14:38:00 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 15 Feb 2005 14:38:00 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Feb 15 15:37:59 2005 Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1D13pP-00037p-4m for ged-emacs-devel@m.gmane.org; Tue, 15 Feb 2005 15:37:29 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D1452-0004kF-T1 for ged-emacs-devel@m.gmane.org; Tue, 15 Feb 2005 09:53:36 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1D143E-0004MB-IG for emacs-devel@gnu.org; Tue, 15 Feb 2005 09:51:44 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1D1433-0004Hd-Vq for emacs-devel@gnu.org; Tue, 15 Feb 2005 09:51:38 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D1430-00049V-8Z for emacs-devel@gnu.org; Tue, 15 Feb 2005 09:51:30 -0500 Original-Received: from [217.207.198.106] (helo=exchange.integrasp.com) by monty-python.gnu.org with esmtp (Exim 4.34) id 1D13XY-0000Q5-VG for emacs-devel@gnu.org; Tue, 15 Feb 2005 09:19:01 -0500 Original-Received: from ASSP-nospam (localhost [127.0.0.1]) by exchange.integrasp.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id 18LH0MN6; Tue, 15 Feb 2005 14:18:58 -0000 Original-Received: from 192.168.111.196 ([192.168.111.196] helo=[192.168.111.196]) by ASSP-nospam ; 15 Feb 05 14:18:58 -0000 User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en Original-To: Lennart Borgman In-Reply-To: <01d301c51364$92cddef0$0200a8c0@sedrcw11488> X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org X-MailScanner-To: ged-emacs-devel@m.gmane.org Xref: main.gmane.org gmane.emacs.devel:33477 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:33477 This is a multi-part message in MIME format. --===============2013788204== Content-Type: multipart/alternative; boundary="------------000009080007050308010408" This is a multi-part message in MIME format. --------------000009080007050308010408 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Lennart Borgman wrote: >I think this helped me to realize what is happening. I am not quite sure but >I believe this is a good guess: > >*** This is where the tooltip window gets created (I did not check further >to see if it where reused, but the timings suggests to me it is not): > > > >>>>>w32fns.c >>>> >>>>> >>>>> >void >my_create_tip_window (f) > struct frame *f; >{ >... > tip_window = FRAME_W32_WINDOW (f) > = CreateWindow (EMACS_CLASS, >... > FRAME_W32_WINDOW (SELECTED_FRAME ()), /* owner */ >... > NULL); >... >} > > >*** There is a SELECTED_FRAME above. As far as I understands it >SELECTED_FRAME is set by operations that Emacs recognize. > > It is probably a bug if focus gained messages from the OS do not set the selected frame, but no new Lisp hooks should be needed. It does seem that any input prevents these focus problems, so it is possibly a case of a message being sent between the UI and Lisp threads, but not getting processed until input arrives. --------------000009080007050308010408 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Lennart Borgman wrote:
I think this helped me to realize what is happening. I am not quite sure but
I believe this is a good guess:

*** This is where the tooltip window gets created (I did not check further
to see if it where reused, but the timings suggests to me it is not):

  
w32fns.c >>>>
          
void
my_create_tip_window (f)
     struct frame *f;
{
...
  tip_window = FRAME_W32_WINDOW (f)
    = CreateWindow (EMACS_CLASS,
...
      FRAME_W32_WINDOW (SELECTED_FRAME ()), /* owner */
...
      NULL);
...
}


*** There is a SELECTED_FRAME above. As far as I understands it
SELECTED_FRAME is set by operations that Emacs recognize.
  
It is probably a bug if focus gained messages from the OS do not set the selected frame, but no new Lisp hooks should be needed.

It does seem that any input prevents these focus problems, so it is possibly a case of a message being sent between the UI and Lisp threads, but not getting processed until input arrives.


--------------000009080007050308010408-- --===============2013788204== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --===============2013788204==--