From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?Gerd_M=C3=B6llmann?= Newsgroups: gmane.emacs.devel Subject: Re: Question about =?utf-8?Q?=C3=BCarent-frame?= changes Date: Wed, 25 Sep 2024 12:17:14 +0200 Message-ID: References: <9bc2af0a-d3c1-4ba6-a350-af6e2b85695d@gmx.at> <87y13phwbk.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="19868"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: martin rudalics , Emacs Devel To: Robert Pluim Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Sep 25 12:18:14 2024 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 1stP66-00053q-3J for ged-emacs-devel@m.gmane-mx.org; Wed, 25 Sep 2024 12:18:14 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1stP5F-0006Nx-1u; Wed, 25 Sep 2024 06:17:21 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1stP5D-0006No-Vo for emacs-devel@gnu.org; Wed, 25 Sep 2024 06:17:20 -0400 Original-Received: from mail-ed1-x52b.google.com ([2a00:1450:4864:20::52b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1stP5C-0004SF-8x for emacs-devel@gnu.org; Wed, 25 Sep 2024 06:17:19 -0400 Original-Received: by mail-ed1-x52b.google.com with SMTP id 4fb4d7f45d1cf-5c43003a667so9113771a12.3 for ; Wed, 25 Sep 2024 03:17:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1727259436; x=1727864236; darn=gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=HTzIPCz5slnvXZyyN5meWrcH5JSUiXIpVKzMp6ew/WU=; b=USWWsDFb328X8+MnsgredbD5+0+qK+CIgA9Oq3fDyx62nPbqN4gVgcvbinQvDAY5E5 rn5U+xKlaLjbZH0Pvy/S/GXdpMv69ZiVe38lnsTdw04RcKDlCUnlFbgov9A3nuoCw1R9 X2SECxzTir7tEFQEvjQ8H4TXZRU8tTM/vYjP05nDD1dzzIuh0V7VS5+ghs+SnWRHy1ud 0V9NRGcvqTReQXr7JpaKjz+JJ+z8JGeV2KjPV4B+4u/dA+q+iIN5R4K0smZXY0ClMA5w pq/Ib04cyY+BWf30xe8YGiG5OCvpJgpkDNz5Lcj/zZGyPFiJ8gBGW0RD7cWOcqJCb+uK SYtw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1727259436; x=1727864236; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=HTzIPCz5slnvXZyyN5meWrcH5JSUiXIpVKzMp6ew/WU=; b=EORMgqz4w9DbTBZp+BujJ6fe6se4lnnFGvVozBukGUPR2g01/UY4ddQPrvsXJP9lu1 0ixIFgqKysQ/OdqQvNfu6sbljcCAgVCbgDiXpnoPdxl3HBgUkakBIDBS8toVXDjFUgke jv+zhHJF78uo+S9yMF5WX/i6YxfAX1wTVFW3z6XCywN47E5wXQj5F+zcAC0tOI+R4nq2 /7FOsE5zoO2NIcsGBcU0LNWaTBC5h8QANd5JoUbNfkcmAUo1C+22PHBkDoNWJw9W3vQK sDps9wRLQVE97IFd9oyQsNTH1q531JkGXRXTbdDNkEMsH/pXoGuy2qytsLUPG5UY/SDr KakA== X-Forwarded-Encrypted: i=1; AJvYcCXrzm1FpK2/eLrlziRiPMmpVi5wJHYeA7ho2BQVItMlFEU69lg3ko+R7LK0Z4FiIbZUDbW6Uv550a9I3A==@gnu.org X-Gm-Message-State: AOJu0Yy4I37GMdRT+Fkby9a/OG6lqBwdYKnh9H7G3gSW/ZYqsEzkPRBj KzTUKK4Si55A1+hP9Cbolcc0SB/60pumMmhMlIat7kj5db7gKMAD4F73Cg== X-Google-Smtp-Source: AGHT+IEVjsgGtIkvkSTQjYrFTcsGD4laKa3QnkqIaiLzv0/w2cDGyGK6QRkk3njpaqtGvMDciEhp8A== X-Received: by 2002:a17:907:6d21:b0:a8a:87d5:2f5e with SMTP id a640c23a62f3a-a93a03f7690mr170099166b.34.1727259435933; Wed, 25 Sep 2024 03:17:15 -0700 (PDT) Original-Received: from pro2.fritz.box (p4fe3a285.dip0.t-ipconnect.de. [79.227.162.133]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9392d67eeesm196234766b.0.2024.09.25.03.17.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Sep 2024 03:17:15 -0700 (PDT) In-Reply-To: ("Gerd =?utf-8?Q?M?= =?utf-8?Q?=C3=B6llmann=22's?= message of "Wed, 18 Sep 2024 17:22:37 +0200") Received-SPF: pass client-ip=2a00:1450:4864:20::52b; envelope-from=gerd.moellmann@gmail.com; helo=mail-ed1-x52b.google.com 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, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=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.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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:324056 Archived-At: Gerd M=C3=B6llmann writes: > Robert Pluim writes: > >> martin> Reparenting is useful because you can set up one child frame= for some >> martin> special purpose, make it invisible when you don't need it, a= nd move it >> martin> to another frame and make it visible there whenever you want= to. On >> martin> GUIs, this approach has the advantage that you can avoid the= (at least >> martin> here) costly process of setting up frame faces every time an= ew. Emacs >> martin> tooltips do that by default and I recall that showing a tool= tip every >> martin> time incurred two entire GC cycles here. >> >> Would setting up frame faces be that expensive on tty? I=CA=BCd really l= ove >> to have tty child frames, even if they were not blazingly fast. > >> From what I've seen so far, it's pretty fast, but OTOH my machine is > pretty fast (M1 pro). Let's see how it does when I'm a bit further. At > least hiding frames on ttys should be there before I can really try it > with posframe. Maybe also moving/resizing also. I think I can say now that it will probably be faster than on GUI, at least on macOS. Running (defun my-make-child () (interactive) (make-frame `((parent-frame . ,(selected-frame)) (background-color . "gray10") (foreground-color . "white") (top . 15) (left . 40) (width . 80) (height . 25)))) (defun my-time-child () (interactive) (dotimes (i 500) (let ((f (my-make-child))) (sit-for 0) (delete-frame f)))) (benchmark-run 1 (my-time-child)) shows 24s with GUI, and 8s on tty. I'm using Alacritty, in case that matters (for the KKP keyboard support, not for performance).