From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: joakim@verona.se Newsgroups: gmane.emacs.devel Subject: Re: Subwindow xwidget Date: Mon, 29 Apr 2019 23:41:14 +0200 Message-ID: <874l6gbibp.fsf@chopper> References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="46417"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: emacs-devel To: Evgeny Zajcev Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Apr 29 23:41:35 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 1hLE1n-000BxN-MR for ged-emacs-devel@m.gmane.org; Mon, 29 Apr 2019 23:41:35 +0200 Original-Received: from localhost ([127.0.0.1]:35701 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hLE1m-0006h1-Cq for ged-emacs-devel@m.gmane.org; Mon, 29 Apr 2019 17:41:34 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:33873) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hLE1a-0006Vc-6W for emacs-devel@gnu.org; Mon, 29 Apr 2019 17:41:23 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hLE1Z-00024O-5X for emacs-devel@gnu.org; Mon, 29 Apr 2019 17:41:22 -0400 Original-Received: from smtp.outgoing.loopia.se ([194.9.95.112]:59433) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hLE1Y-00020y-VO for emacs-devel@gnu.org; Mon, 29 Apr 2019 17:41:21 -0400 Original-Received: from s554.loopia.se (localhost [127.0.0.1]) by s554.loopia.se (Postfix) with ESMTP id 7DB771F16ADE for ; Mon, 29 Apr 2019 23:41:16 +0200 (CEST) Original-Received: from s498.loopia.se (unknown [172.21.200.96]) by s554.loopia.se (Postfix) with ESMTP id 5F828795BAC; Mon, 29 Apr 2019 23:41:16 +0200 (CEST) Original-Received: from s471.loopia.se (unknown [172.21.200.35]) by s498.loopia.se (Postfix) with ESMTP id 5C46544940F; Mon, 29 Apr 2019 23:41:16 +0200 (CEST) X-Virus-Scanned: amavisd-new at amavis.loopia.se Original-Received: from s499.loopia.se ([172.22.191.6]) by s471.loopia.se (s471.loopia.se [172.22.190.11]) (amavisd-new, port 10024) with LMTP id loe6npBcnyFn; Mon, 29 Apr 2019 23:41:15 +0200 (CEST) X-Loopia-Auth: user X-Loopia-User: joakim.verona@chimeslab.se X-Loopia-Originating-IP: 81.170.223.63 Original-Received: from ubermaschine (h-223-63.A149.priv.bahnhof.se [81.170.223.63]) (Authenticated sender: joakim.verona@chimeslab.se) by s499.loopia.se (Postfix) with ESMTPSA id 3785E1349A37; Mon, 29 Apr 2019 23:41:15 +0200 (CEST) In-Reply-To: (Evgeny Zajcev's message of "Mon, 29 Apr 2019 23:10:51 +0300") X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x [fuzzy] X-Received-From: 194.9.95.112 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:236040 Archived-At: Evgeny Zajcev writes: > In XEmacs there is nice "subwindow" glyph type, which could be used to display contents of foreign application (such as video player). Internally it is just ordinary > subwindow of fixed geometry with API to get its XID, which you specify to foreign application to render to. > > Is it possible to do the same in GNU Emacs or would it be hard to implement? > > Unfortunately xwidget functionality is limited to "webkit" type of widget, and it does not provide API to get XID of the widget's window. > > Thanks I'm not really sure if its possible to do what you ask out of the box, but I can explain a little bit about the xwidget implementation. xwidgets are supposed to follow the emacs windowing paradigm so you can split an emacs window with a xwidget, and then you get for instance two copies of the same xwidget on screen. This is done by off-screen copying of window bitmaps from the off screen widget. The original branch of xwidget also allowed for different types of widgets apart from the webkit one. One of those widgets was a generic container widget, such that you could embed emacs inside emacs for instance. Some screenshots: https://www.emacswiki.org/emacs/EmacsXWidgets That branch is bitrotted, but resides both on savannah and github https://github.com/jave/xwidget-emacs But you only need the xwidget complexity if you actually need the of-screen copying which you only need if you care about your widget to follow the emacs paradigm of window splitting and so on. If you just want your video window to appear at a fixed position inside emacs, that is doable by other means, and I think there are a couple of projects that do that. Regards, -- Joakim Verona joakim@verona.se