From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Phil Sainty Newsgroups: gmane.emacs.devel Subject: Re: Help using the right hook for loading theme on emacs daemon GUI Date: Thu, 24 Jan 2019 16:47:59 +1300 Message-ID: <6c1611672809c8d7b5011edf0d2dd831@webmail.orcon.net.nz> References: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="31972"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Orcon Webmail Cc: Emacs developers To: Kaushal Modi Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jan 24 05:05:00 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gmWGB-0008Cj-PJ for ged-emacs-devel@m.gmane.org; Thu, 24 Jan 2019 05:04:59 +0100 Original-Received: from localhost ([127.0.0.1]:46001 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gmWGA-000757-OT for ged-emacs-devel@m.gmane.org; Wed, 23 Jan 2019 23:04:58 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:58035) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gmWDX-0005PL-N6 for emacs-devel@gnu.org; Wed, 23 Jan 2019 23:02:16 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gmVzn-0001lI-B8 for emacs-devel@gnu.org; Wed, 23 Jan 2019 22:48:03 -0500 Original-Received: from smtp-4.orcon.net.nz ([60.234.4.59]:37611) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gmVzn-0001fl-0g for emacs-devel@gnu.org; Wed, 23 Jan 2019 22:48:03 -0500 Original-Received: from [10.253.37.70] (port=40973 helo=webmail.orcon.net.nz) by smtp-4.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1gmVzk-0005Jk-1G; Thu, 24 Jan 2019 16:48:00 +1300 Original-Received: from wlgwil-nat-office.catalyst.net.nz ([202.78.240.7]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Thu, 24 Jan 2019 16:47:59 +1300 In-Reply-To: X-Sender: psainty@orcon.net.nz X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 60.234.4.59 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:232666 Archived-At: On 2019-01-23 09:27, Kaushal Modi wrote: > For the reason in that comment, after-make-frame-functions did not > work for me, so I had stopped using it. Where the comment in question was: ;; `after-make-frame-functions' hook is not run in no-window mode Which is a bit confusing to me. If you are creating a new frame with the -nw option for an existing Emacs instance then `after-make-frame-functions' definitely runs. (Certainly in 26.1, where I just tested it.) It's true that just running 'emacs -nw' does not run that hook for the initial frame -- but then neither does it run for the initial frame when you start 'emacs' in GUI mode, so the "no-window mode" part does not seem relevant. It's quite common to add a function to `after-make-frame-functions' and to also call that function directly during init (or in `after-init-hook' or some such) to process the initial frame. -Phil