bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#37415: Asserting failure setting frame parameters to non-fixnum valu


From: martin rudalics
Subject: bug#37415: Asserting failure setting frame parameters to non-fixnum values in early-init.el
Date: Sun, 22 Sep 2019 19:54:00 +0200

> No, I don't think using x_get_arg is wrong, because we still want to
> determine whether to use CW_USEDEFAULT.

Hmm ...

> We cannot do this unless f->size_hint_flags are set so as to tell
> w32_createwindow to use f->top_pos and/or f->left_pos.  Otherwise, we
> should put CW_USEDEFAULT in coords[].  IOW, how about the below?
[...]
> +  if (!(f->size_hint_flags & USPosition || f->size_hint_flags & PPosition))
> +    {
> +      /* When called with RES_TYPE_NUMBER, and there's no 'top' or
> +   'left' parameters in the frame's parameter alist,
> +   gui_display_get_arg will return zero for anything that is
> +   neither a number nor Qunbound.  If frame parameter alist does
> +   have 'left' or 'top', they are interpreted by
> +   gui_figure_window_size, which was already called, and which
> +   sets f->size_hint_flags.  */

So you mean when size hints are not set, we are sure that
gui_display_get_arg does not find anything in 'default-frame-alist'
(ignoring, BTW 'initial-frame-alist') and finds a number here.  This
looks a bit fragile to me.  Isn't the fact that left/top are unbound
sufficient that we should use CW_USEDEFAULT and f->left_pos/f->top_pos
otherwise.  Or don't you want to call gui_display_get_arg twice?

martin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]