From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: storm@cua.dk (Kim F. Storm) Newsgroups: gmane.emacs.devel Subject: Re: Status of MAC/W32/X consolidation and some questions. Date: 11 Mar 2003 02:01:01 +0100 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <5xfzpuemya.fsf@kfs2.cua.dk> References: <5xadg38lnj.fsf@kfs2.cua.dk> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1047341019 14505 80.91.224.249 (11 Mar 2003 00:03:39 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 11 Mar 2003 00:03:39 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Tue Mar 11 01:03:38 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18sXF4-0003lo-00 for ; Tue, 11 Mar 2003 01:03:38 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 18sXbY-0000Wl-00 for ; Tue, 11 Mar 2003 01:26:52 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18sXER-0004MY-09 for emacs-devel@quimby.gnus.org; Mon, 10 Mar 2003 19:02:59 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 18sXE8-0004IQ-00 for emacs-devel@gnu.org; Mon, 10 Mar 2003 19:02:40 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 18sXE0-0004EF-00 for emacs-devel@gnu.org; Mon, 10 Mar 2003 19:02:33 -0500 Original-Received: from mail.filanet.dk ([195.215.206.179]) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18sXDb-00044g-00 for emacs-devel@gnu.org; Mon, 10 Mar 2003 19:02:07 -0500 Original-Received: from kfs2.cua.dk.cua.dk (unknown [10.1.82.3]) by mail.filanet.dk (Postfix) with SMTP id A8EF17C012; Tue, 11 Mar 2003 01:02:04 +0100 (CET) Original-To: Benjamin Riefenstahl In-Reply-To: Original-Lines: 75 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Emacs development discussions. List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:12252 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:12252 Benjamin Riefenstahl writes: > > Now, what I'm currently working on is to replace all mac* and w32* > > specific names with the corresponding x* names, > > e.g. FRAME_MAC_WINDOW is replaced by FRAME_X_WINDOW, > > I guess this is probably the fastest path and would mostly leave alone > the X11 code. But wouldn't it in theory better to rename those items > to a neutral FRAME_GUI_ANYTHING instead? When I look at code I find > the tendency to re-use X11 names outside of X11 rather irritating. I have been thinking about the same issue, and I am not very satisfied with the overloading of the X names, either. However, as the X version is really the "reference GUI platform", a lot of the code which really isn't X-specific still use the x_ prefix (or some other X-related name), so from that point of view, it does make sense that the "reference gui" continues to use the X names, and let the other (non-free) platforms overload the X-specific "reference platform" functions. > > > * Does the W32 version support -nw? > > Yes. > > > If so, is FRAME_W32_P still true when specified? > > No. If I read the code right, FRAME_W32_P is based on output_method, > and output_method can be interrogated as the result of the (framep) > function. "(framep (selected-frame))" returns t (for "character-only > terminal") in this situation. Ok, thanks. So output_method is output_termcap for -nw on windows. Then some of the emacs code really make no sense to me. What does (assoc 'font (frame-parameters nil)) return when you try it on W32 emacs -nw ? If your assumption is correct is will return (font . "tty"), but the code seems to be supposed to return (font . "w32term"). Also, in xdisp.c, the following test is used to check whether emacs is running as a GUI or TTY program on W32, X, or MAC: /* Don't do all this for graphical frames. */ #ifdef HAVE_NTGUI if (!NILP (Vwindow_system)) return; #endif #if defined (USE_X_TOOLKIT) || defined (USE_GTK) if (FRAME_X_P (f)) return; #endif #ifdef MAC_OS if (FRAME_MAC_P (f)) return; #endif If your assumption is correct, the first test could be replaced by if (FRAME_W32_P (f)) > > which I hope some of you will assist me in solving (I hope/expect it > > is just a matter of fixing some trivial compilation errors). > > I can probably help with that. Thanks. -- Kim F. Storm http://www.cua.dk