Subject: bug#1077: 23.0.60; x-create-frame: (wrong-type-argument number-or-marker-p nil)

From: Eli Zaretskii <[email-masked]>
Date: Tue, 30 Nov 2010 06:42:59 -0500

> Date: Tue, 30 Nov 2010 08:56:41 +0100
> From: martin rudalics <[email-masked]>
> CC: Drew Adams <[email-masked]>, [email-masked]
> 
> `menu-bar-lines'
>       The number of lines to allocate at the top of the frame for a menu
>       bar.  The default is 1.  A value of `nil' means don't display a
>       menu bar.  *Note Menu Bar::.  (The X toolkit and GTK allow at most
>       one menu bar line; they treat larger values as 1.)
> 
> so `nil' is a valid value and evaluating a menu bar item probably should
> know how to handle it.

Btw, the code which injects this nil into the frame parameters is no
other than oneonone.el itself.  It has this part:

    (defcustom 1on1-minibuffer-frame-alist
      (list
       (or (assq 'foreground-color minibuffer-frame-alist)
	   (cons 'foreground-color 1on1-minibuffer-frame-foreground))
       [...]
       (or (assq 'menu-bar-lines minibuffer-frame-alist)
	   (cons 'menu-bar-lines nil))
            ^^^^^^^^^^^^^^^^^^^^^^^^^

If I replace this with `(cons 'menu-bar-lines 0)', the original
problem goes away without any changes in menu-bar.el.

Drew, any reason not to make that change in your package?