From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?B?SmluZMWZaWNoIE1ha292acSNa2E=?= Newsgroups: gmane.emacs.devel Subject: [PATCH] src/pgtkfns.c: Do not show an empty frame prematurely Date: Sat, 29 May 2021 20:58:47 +0200 Message-ID: <20210529205847.1d128399@holly> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="MP_/azGpEQz.Jj/bXzChT_K+OAd" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27825"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 29 21:09:54 2021 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 1ln4LI-00077R-QV for ged-emacs-devel@m.gmane-mx.org; Sat, 29 May 2021 21:09:52 +0200 Original-Received: from localhost ([::1]:35054 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ln4LH-0003md-Tm for ged-emacs-devel@m.gmane-mx.org; Sat, 29 May 2021 15:09:51 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:40716) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ln4Af-0000AD-Jx for emacs-devel@gnu.org; Sat, 29 May 2021 14:58:53 -0400 Original-Received: from mail-ej1-x634.google.com ([2a00:1450:4864:20::634]:34363) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ln4Ad-0007hz-Ut for emacs-devel@gnu.org; Sat, 29 May 2021 14:58:53 -0400 Original-Received: by mail-ej1-x634.google.com with SMTP id g8so1802020ejx.1 for ; Sat, 29 May 2021 11:58:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version; bh=05y3kJf3YGwNtlLXFcSTamdgN2aTQPvw0d7ZU74TflQ=; b=CxrURAfW5oPOyAFRRYVOBsVe32SboPPmD1Kqk5czuqJRsy9gHSiZUEIpxPVBby8F47 cDwgQDSygj/YGzK7guLOCo335LLRgXuPZNMJQ3sjpc2Y1JULbJKVd2O6KPCLyRBNLeNP sFDXHWW9TXeNF4sT4fbr2E/DS0juFkIUF5orWI+HLq2qW5F6id/MAR89TapJHstnWlw5 bN2GBq5z3/SlG3mA5ggeGERbfCbi6ucHzgNa73wTw4CiqnTWFP5s/rIW2LbiS2ZLrs45 pGuBg07sKqepZl9rvhHsLcRJqjs13vtMwMNx6daIvW0K6/SVHF887jVyvDLNIH4yK0rQ 5VyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mime-version; bh=05y3kJf3YGwNtlLXFcSTamdgN2aTQPvw0d7ZU74TflQ=; b=RZaxiDfzAPRKzLkNoDqp87FvyegUEk2pb1fiT/cKkGr66BKBjQFT39O1wmnMLkNqOh lTbk+zFJWW4+p2woYuGHAyTFmVyTlDUyjaHdv549A22w+bDa4tr4G9rpwb9vTbPC7hku cCGKWW9LB+u6moVMnwZS8oYbybDVCaKzfc5PVDNd8YkFUK0+tfzvoaBoEyAypYNCOOTh nvsx8rR9/Oiv9+N/bT5WaRgbEiMTZT05dQCRD4eTD+YFmk8cevoiymSpL7vqOxUx6bCS IUTWtxuwzgd8sp9WZA+zQiApLN7uoGu+nCZCZOCKfRbzkaCiKwpn7Rk+sFn6jp6h49dJ 9BiQ== X-Gm-Message-State: AOAM532MfR//fJE/6QTe8u4ZN3HSdavE6KkK9+5I7Oiio5F03JiyajWo DlnBb9kf1CBmNz6lVDGxgtiSQyjRLS/g5A== X-Google-Smtp-Source: ABdhPJwLHa1yoz4RLmxaN0AxPlZcv8Vbm7SKD24MBXSbwnv3jLXoXebmuJBlbgFAtnGYhfO01gRE3A== X-Received: by 2002:a17:906:3785:: with SMTP id n5mr15262379ejc.127.1622314729990; Sat, 29 May 2021 11:58:49 -0700 (PDT) Original-Received: from holly (ip-89-177-165-220.net.upcbroadband.cz. [89.177.165.220]) by smtp.gmail.com with ESMTPSA id hb14sm3851488ejb.118.2021.05.29.11.58.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 May 2021 11:58:49 -0700 (PDT) X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Received-SPF: pass client-ip=2a00:1450:4864:20::634; envelope-from=makovick@gmail.com; helo=mail-ej1-x634.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-Mailman-Approved-At: Sat, 29 May 2021 15:08:52 -0400 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:270094 Archived-At: --MP_/azGpEQz.Jj/bXzChT_K+OAd Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi, currently, PGTK Emacs shows an empty 200x200 px GTK window immediately when x-create-frame is called, and it takes some time until the "real" Emacs frame is shown. Changing this function to set the visibility flag only on the child widgets of the GTK window and leaving the parent window hidden until pgtk_make_frame_visible is called gives a much better impression when starting Emacs. -- Jindrich Makovicka --MP_/azGpEQz.Jj/bXzChT_K+OAd Content-Type: text/x-patch Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=0001-src-pgtkfns.c-Do-not-show-an-empty-frame-prematurely.patch >From 668bbba248de2b5eba346499b3f0a9d3de18ebc4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jind=C5=99ich=20Makovi=C4=8Dka?= Date: Sat, 29 May 2021 14:53:20 +0200 Subject: [PATCH] * src/pgtkfns.c: Do not show an empty frame prematurely Set only the child widgets visible, leave the outer window to pgtk_make_frame_visible . --- src/pgtkfns.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/pgtkfns.c b/src/pgtkfns.c index 5f114515c9..689a104d33 100644 --- a/src/pgtkfns.c +++ b/src/pgtkfns.c @@ -1693,8 +1693,13 @@ #define INSTALL_CURSOR(FIELD, NAME) \ unblock_input (); } - if (FRAME_GTK_OUTER_WIDGET (f)) - gtk_widget_show_all (FRAME_GTK_OUTER_WIDGET (f)); + if (FRAME_GTK_OUTER_WIDGET (f)) { + GList *w = gtk_container_get_children(GTK_CONTAINER(FRAME_GTK_OUTER_WIDGET (f))); + for (; w != NULL; w = w->next) + { + gtk_widget_show_all (GTK_WIDGET(w->data)); + } + } gui_default_parameter (f, parms, Qno_focus_on_map, Qnil, NULL, NULL, RES_TYPE_BOOLEAN); -- 2.32.0.rc0 --MP_/azGpEQz.Jj/bXzChT_K+OAd--