all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Change the default behaviour when 2 files are open
@ 2008-03-06 14:43 Francis Moreau
  2008-03-06 15:07 ` Joel J. Adamson
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Francis Moreau @ 2008-03-06 14:43 UTC (permalink / raw)
  To: gnu-emacs-help

Hello,

When I do:

$ emacs file1 file2

my display is splitted  into 2 horizontal windows.

I'd like it to be splitted intto 2 vertical windows instead.

Coud anybody give me a hint ?

thanks
-- 
Francis




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 14:43 Change the default behaviour when 2 files are open Francis Moreau
@ 2008-03-06 15:07 ` Joel J. Adamson
  2008-03-06 21:07   ` Francis Moreau
  2008-03-06 15:33 ` Bastien
  2008-03-06 19:24 ` Peter Dyballa
  2 siblings, 1 reply; 13+ messages in thread
From: Joel J. Adamson @ 2008-03-06 15:07 UTC (permalink / raw)
  To: Francis Moreau; +Cc: gnu-emacs-help

"Francis Moreau" <francis.moro@gmail.com> writes:

> Hello,
>
> When I do:
>
> $ emacs file1 file2
>
> my display is splitted  into 2 horizontal windows.
>
> I'd like it to be splitted intto 2 vertical windows instead.
>
> Coud anybody give me a hint ?

"C-x 1 C-x 3 C-x o C-x b <buffer-name>"

Try it.

Also try "M-x customize-group RET windows RET"

Joel

-- 
Joel J. Adamson
Biostatistician
Pediatric Psychopharmacology Research Unit
Massachusetts General Hospital
Boston, MA  02114
(617) 643-1432
(303) 880-3109

The information transmitted in this electronic communication is intended only
for the person or entity to whom it is addressed and may contain confidential
and/or privileged material. Any review, retransmission, dissemination or other
use of or taking of any action in reliance upon this information by persons or
entities other than the intended recipient is prohibited. If you received this
information in error, please contact the Compliance HelpLine at 800-856-1983 and
properly dispose of this information.







^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 14:43 Change the default behaviour when 2 files are open Francis Moreau
  2008-03-06 15:07 ` Joel J. Adamson
@ 2008-03-06 15:33 ` Bastien
  2008-03-06 16:13   ` Francis Moreau
  2008-03-06 19:24 ` Peter Dyballa
  2 siblings, 1 reply; 13+ messages in thread
From: Bastien @ 2008-03-06 15:33 UTC (permalink / raw)
  To: Francis Moreau; +Cc: gnu-emacs-help

"Francis Moreau" <francis.moro@gmail.com> writes:

> I'd like it to be splitted intto 2 vertical windows instead.
>
> Coud anybody give me a hint ?

M-x customize-variable RET split-window-preferred-function RET

Quoting the docstring: 

  This variable was introduced, or its default value was changed, in
  version 23.1 of Emacs.

-- 
Bastien




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 15:33 ` Bastien
@ 2008-03-06 16:13   ` Francis Moreau
  0 siblings, 0 replies; 13+ messages in thread
From: Francis Moreau @ 2008-03-06 16:13 UTC (permalink / raw)
  To: Bastien; +Cc: gnu-emacs-help

On Thu, Mar 6, 2008 at 4:33 PM, Bastien <bzg@altern.org> wrote:
> "Francis Moreau" <francis.moro@gmail.com> writes:
>
>  > I'd like it to be splitted intto 2 vertical windows instead.
>  >
>  > Coud anybody give me a hint ?
>
>  M-x customize-variable RET split-window-preferred-function RET
>
>  Quoting the docstring:
>
>   This variable was introduced, or its default value was changed, in
>   version 23.1 of Emacs.
>

thanks for the hint !

-- 
Francis




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 14:43 Change the default behaviour when 2 files are open Francis Moreau
  2008-03-06 15:07 ` Joel J. Adamson
  2008-03-06 15:33 ` Bastien
@ 2008-03-06 19:24 ` Peter Dyballa
  2008-03-06 21:04   ` Francis Moreau
       [not found]   ` <mailman.8460.1204837472.18990.help-gnu-emacs@gnu.org>
  2 siblings, 2 replies; 13+ messages in thread
From: Peter Dyballa @ 2008-03-06 19:24 UTC (permalink / raw)
  To: Francis Moreau; +Cc: gnu-emacs-help


Am 06.03.2008 um 15:43 schrieb Francis Moreau:

> I'd like it to be splitted intto 2 vertical windows instead.
>
> Coud anybody give me a hint ?


If you can't find anything in the Emacs info node, then send a bug  
report (from Help menu) in which you ask to add customisation to set  
a preference for vertical or horizontal splitting.

The "recent" preference to split the frame into an upper and a lower  
window comes from GNU Emacs's past on hardware terminals with 25  
lines and 80 columns. Creating here two windows side by side was not  
a clever thought. Since GNU Emacs can be more wide than high on 16:10  
displays this side by side layout can be more natural. And natural  
things should be supported by GNU Emacs.

--
Greetings
                                  <]
    Pete      o        __o         |__    o           recumbo
     ___o    /I       -\<,         |o \  -\),-%       ergo sum!
___/\ /\___./ \___...O/ O____.....`-O-'-()--o_________________






^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 19:24 ` Peter Dyballa
@ 2008-03-06 21:04   ` Francis Moreau
  2008-03-06 21:42     ` Nick Roberts
       [not found]   ` <mailman.8460.1204837472.18990.help-gnu-emacs@gnu.org>
  1 sibling, 1 reply; 13+ messages in thread
From: Francis Moreau @ 2008-03-06 21:04 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: gnu-emacs-help

On Thu, Mar 6, 2008 at 8:24 PM, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>  If you can't find anything in the Emacs info node, then send a bug
>  report (from Help menu) in which you ask to add customisation to set
>  a preference for vertical or horizontal splitting.
>

I couldn't have found anything revelant.

I'll send a bug report if nothing interesting can come up from this thread.

>  The "recent" preference to split the frame into an upper and a lower
>  window comes from GNU Emacs's past on hardware terminals with 25
>  lines and 80 columns. Creating here two windows side by side was not
>  a clever thought. Since GNU Emacs can be more wide than high on 16:10
>  displays this side by side layout can be more natural. And natural
>  things should be supported by GNU Emacs.
>

I agree.

thanks
-- 
Francis




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 15:07 ` Joel J. Adamson
@ 2008-03-06 21:07   ` Francis Moreau
  0 siblings, 0 replies; 13+ messages in thread
From: Francis Moreau @ 2008-03-06 21:07 UTC (permalink / raw)
  To: Joel J. Adamson; +Cc: gnu-emacs-help

On Thu, Mar 6, 2008 at 4:07 PM, Joel J. Adamson <jadamson@partners.org> wrote:
> "Francis Moreau" <francis.moro@gmail.com> writes:
>  "C-x 1 C-x 3 C-x o C-x b <buffer-name>"
>

No, the whole point of my question is to avoid such combo...

I find more natural that emacs use vertical splitting when it wants
to open a new window. Of course it applies only when only 2 windows
are displayed. For more than 2 windows, it's another story.

-- 
Francis




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 21:04   ` Francis Moreau
@ 2008-03-06 21:42     ` Nick Roberts
  2008-03-07  8:17       ` Francis Moreau
  2008-04-02  8:56       ` getting gdb init work on emacs Sanjeev Kumar.S
  0 siblings, 2 replies; 13+ messages in thread
From: Nick Roberts @ 2008-03-06 21:42 UTC (permalink / raw)
  To: Francis Moreau; +Cc: gnu-emacs-help

Francis Moreau writes:
 > On Thu, Mar 6, 2008 at 8:24 PM, Peter Dyballa <Peter_Dyballa@web.de> wrote:
 > >  If you can't find anything in the Emacs info node, then send a bug
 > >  report (from Help menu) in which you ask to add customisation to set
 > >  a preference for vertical or horizontal splitting.
 > >
 > 
 > I couldn't have found anything revelant.
 > 
 > I'll send a bug report if nothing interesting can come up from this thread.

Bastien has already answered your question:

M-x customize-variable RET split-window-preferred-function RET

and select the value "horizontally".

I don't know where the docstring he quoted is from because this option seems to
only be in Emacs 23.0.60 in the CVS repository and will not be part of the next
release (22.2).

-- 
Nick                                           http://www.inet.net.nz/~nickrob




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
       [not found]   ` <mailman.8460.1204837472.18990.help-gnu-emacs@gnu.org>
@ 2008-03-06 21:48     ` Sven Joachim
  0 siblings, 0 replies; 13+ messages in thread
From: Sven Joachim @ 2008-03-06 21:48 UTC (permalink / raw)
  To: help-gnu-emacs

On 2008-03-06 22:04 +0100, Francis Moreau wrote:

> On Thu, Mar 6, 2008 at 8:24 PM, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>>  If you can't find anything in the Emacs info node, then send a bug
>>  report (from Help menu) in which you ask to add customisation to set
>>  a preference for vertical or horizontal splitting.
>>
>
> I couldn't have found anything revelant.
>
> I'll send a bug report if nothing interesting can come up from this thread.

In the development version of Emacs there is the user option
split-window-preferred-function which you can customize.  However, this
option does not exist in Emacs 22 or earlier.

Sven


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-06 21:42     ` Nick Roberts
@ 2008-03-07  8:17       ` Francis Moreau
  2008-03-07  9:57         ` Thierry Volpiatto
  2008-04-02  8:56       ` getting gdb init work on emacs Sanjeev Kumar.S
  1 sibling, 1 reply; 13+ messages in thread
From: Francis Moreau @ 2008-03-07  8:17 UTC (permalink / raw)
  To: Nick Roberts; +Cc: gnu-emacs-help

On Thu, Mar 6, 2008 at 10:42 PM, Nick Roberts <nickrob@snap.net.nz> wrote:
> Francis Moreau writes:
>   > On Thu, Mar 6, 2008 at 8:24 PM, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>   > >  If you can't find anything in the Emacs info node, then send a bug
>   > >  report (from Help menu) in which you ask to add customisation to set
>   > >  a preference for vertical or horizontal splitting.
>   > >
>   >
>   > I couldn't have found anything revelant.
>   >
>   > I'll send a bug report if nothing interesting can come up from this thread.
>
>  Bastien has already answered your question:
>
>
>  M-x customize-variable RET split-window-preferred-function RET
>
>  and select the value "horizontally".

Ah yes but I tried it and it fails because I'm using emacs 22.1 and
I'm not able to upgrade emacs on this machine.

>
>  I don't know where the docstring he quoted is from because this option seems to
>  only be in Emacs 23.0.60 in the CVS repository and will not be part of the next
>  release (22.2).
>

So I guess there's no way to do so in my case.

thanks
-- 
Francis




^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Change the default behaviour when 2 files are open
  2008-03-07  8:17       ` Francis Moreau
@ 2008-03-07  9:57         ` Thierry Volpiatto
  0 siblings, 0 replies; 13+ messages in thread
From: Thierry Volpiatto @ 2008-03-07  9:57 UTC (permalink / raw)
  To: Francis Moreau; +Cc: gnu-emacs-help

"Francis Moreau" <francis.moro@gmail.com> writes:

> On Thu, Mar 6, 2008 at 10:42 PM, Nick Roberts <nickrob@snap.net.nz> wrote:
>> Francis Moreau writes:
>>   > On Thu, Mar 6, 2008 at 8:24 PM, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>>   > >  If you can't find anything in the Emacs info node, then send a bug
>>   > >  report (from Help menu) in which you ask to add customisation to set
>>   > >  a preference for vertical or horizontal splitting.
>>   > >
>>   >
>>   > I couldn't have found anything revelant.
>>   >
>>   > I'll send a bug report if nothing interesting can come up from this thread.
>>
>>  Bastien has already answered your question:
>>
>>
>>  M-x customize-variable RET split-window-preferred-function RET
>>
>>  and select the value "horizontally".
>
> Ah yes but I tried it and it fails because I'm using emacs 22.1 and
> I'm not able to upgrade emacs on this machine.
>
>>
>>  I don't know where the docstring he quoted is from because this option seems to
>>  only be in Emacs 23.0.60 in the CVS repository and will not be part of the next
>>  release (22.2).
>>
>
> So I guess there's no way to do so in my case.
>
> thanks

You can, alternatively, write in your .emacs something like:

--8<---------------cut here---------------start------------->8---
(find-file file1)
(split-window-horizontally)
(find-file-other-window file2)
--8<---------------cut here---------------end--------------->8---

and you can save this config with:

(window-configuration-to-register 119 nil) ;;119 == w

But you can choose something else:

save your config with C-x r w ==> choose a letter ==> RET

Then hit C-x esc esc and copy the line in minibuffer in your .emacs

-- 
A + Thierry
Pub key: http://pgp.mit.edu




^ permalink raw reply	[flat|nested] 13+ messages in thread

* getting gdb init work on emacs
  2008-03-06 21:42     ` Nick Roberts
  2008-03-07  8:17       ` Francis Moreau
@ 2008-04-02  8:56       ` Sanjeev Kumar.S
  2008-04-03  3:01         ` Nick Roberts
  1 sibling, 1 reply; 13+ messages in thread
From: Sanjeev Kumar.S @ 2008-04-02  8:56 UTC (permalink / raw)
  To: Nick Roberts, Francis Moreau; +Cc: gnu-emacs-help

[-- Attachment #1: Type: text/plain, Size: 839 bytes --]

Hi,
     I am trying to setup gdb init so that I don't 
have to lookup add and load the module everytime
so I am trying to automate it. I'm new to this
and i am facing this problem can anyone suggest
a solution ?

define lwlan
   set $kld = linker_files.tqh_first
   while ($kld != 0)
       if [$kld->filename=="wlan.ko"] \
     printf "0x%08x %s\n", $kld->address, $kld->filename
       end
       set $kld = $kld->link.tqe_next
   end
 end

running it gives me this :

(kgdb) lwlan
A syntax error in expression, near `[$kld->filename=="wlan.ko"]      printf "0x%08x %s\n", $kld->address, $kld->filename'.

by the way does it follow the shell syntax or
is there any other syntax ?

thanks,
sanjeev.

       
---------------------------------
You rock. That's why Blockbuster's offering you one month of Blockbuster Total Access, No Cost.

[-- Attachment #2: Type: text/html, Size: 1214 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: getting gdb init work on emacs
  2008-04-02  8:56       ` getting gdb init work on emacs Sanjeev Kumar.S
@ 2008-04-03  3:01         ` Nick Roberts
  0 siblings, 0 replies; 13+ messages in thread
From: Nick Roberts @ 2008-04-03  3:01 UTC (permalink / raw)
  To: Sanjeev Kumar.S; +Cc: gnu-emacs-help

 > define lwlan
 >    set $kld = linker_files.tqh_first
 >    while ($kld != 0)
 >        if [$kld->filename=="wlan.ko"] \
 >      printf "0x%08x %s\n", $kld->address, $kld->filename
 >        end
 >        set $kld = $kld->link.tqe_next
 >    end
 >  end
 > 
 > running it gives me this :
 > 
 > (kgdb) lwlan
 > A syntax error in expression, near `[$kld->filename=="wlan.ko"]      printf "0x%08x %s\n", $kld->address, $kld->filename'.
 > 
 > by the way does it follow the shell syntax or

No.  Which is why square brackets don't work.

 > is there any other syntax ?

See the Sequences node of the Gdb manual.  The syntax is quite restricted and
expressions like $kld->filename won't work.

There is currently work being done on Python scripting.  This is being reported
on the gdb mailing list (gdb@sourceware.org) which is where this question should
really go as it's about Gdb.

-- 
Nick                                           http://www.inet.net.nz/~nickrob




^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2008-04-03  3:01 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-06 14:43 Change the default behaviour when 2 files are open Francis Moreau
2008-03-06 15:07 ` Joel J. Adamson
2008-03-06 21:07   ` Francis Moreau
2008-03-06 15:33 ` Bastien
2008-03-06 16:13   ` Francis Moreau
2008-03-06 19:24 ` Peter Dyballa
2008-03-06 21:04   ` Francis Moreau
2008-03-06 21:42     ` Nick Roberts
2008-03-07  8:17       ` Francis Moreau
2008-03-07  9:57         ` Thierry Volpiatto
2008-04-02  8:56       ` getting gdb init work on emacs Sanjeev Kumar.S
2008-04-03  3:01         ` Nick Roberts
     [not found]   ` <mailman.8460.1204837472.18990.help-gnu-emacs@gnu.org>
2008-03-06 21:48     ` Change the default behaviour when 2 files are open Sven Joachim

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.