From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.devel Subject: Re: split-window-preferred-function Date: Fri, 21 Mar 2008 10:18:20 +0100 Message-ID: <47E37D5C.7040201@gmx.at> References: <47E188D5.5030502@gmx.at> <87hcf1rrdj.fsf@jurta.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1206091237 24987 80.91.229.12 (21 Mar 2008 09:20:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 21 Mar 2008 09:20:37 +0000 (UTC) Cc: emacs-devel To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Mar 21 10:21:07 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JcdQw-0000Bs-K0 for ged-emacs-devel@m.gmane.org; Fri, 21 Mar 2008 10:21:07 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JcdQJ-0000xC-V1 for ged-emacs-devel@m.gmane.org; Fri, 21 Mar 2008 05:20:28 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JcdNp-0000D4-Ub for emacs-devel@gnu.org; Fri, 21 Mar 2008 05:17:54 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JcdNk-0000Ap-N4 for emacs-devel@gnu.org; Fri, 21 Mar 2008 05:17:49 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JcdNj-0000AF-Am for emacs-devel@gnu.org; Fri, 21 Mar 2008 05:17:47 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1JcdNi-0001YU-RY for emacs-devel@gnu.org; Fri, 21 Mar 2008 05:17:47 -0400 Original-Received: (qmail invoked by alias); 21 Mar 2008 09:17:43 -0000 Original-Received: from M3077P014.adsl.highway.telekom.at (EHLO [88.117.32.142]) [88.117.32.142] by mail.gmx.net (mp057) with SMTP; 21 Mar 2008 10:17:43 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1+rLtE4whOrLkC3rgUogNvLR82bzBzirWaaH7vQR0 EiGugYWMrQi0V7 User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: de-DE, de, en-us, en In-Reply-To: <87hcf1rrdj.fsf@jurta.org> X-Y-GMX-Trusted: 0 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 1) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:93104 Archived-At: > Maybe a function in `split-window-preferred-function' should take care > of all these conditions to decide how to split within a given > window configuration? Writing such a function is not entirely trivial. Who's supposed to write `split-window-preferred-function' in the first place? Wasn't the original motivation of this to simply allow horizontal splitting? > The following patch implements this (note that checking for non-nil > Vsplit_window_preferred_function is not necessary in the else-branch > because when Vsplit_window_preferred_function is called unconditionally > it never reaches this else-branch with the second place where > Fsplit_window is called). Looks good. But as Stefan remarked the function should return nil and have `disply-buffer' continue the standard processing of this when it was not able to split the window for whatever reason.