emacs-devel
[Top][All Lists]
Advanced

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

Re: Emacs's set-frame-size can not work well with gnome-shell?


From: martin rudalics
Subject: Re: Emacs's set-frame-size can not work well with gnome-shell?
Date: Sat, 11 Jan 2020 08:50:19 +0100

>   > (defun open-test (buffer)
>   >    (display-buffer-in-child-frame
>   >     buffer '((child-frame-parameters
>   >               . ((width . 40)
>   >                  (height . 10)
>   >                  (top . 50)
>   >                  (left . 50)
>   >                  )))))
>   >
>   > (defun resize-test (frame)
>   >    (set-frame-height frame 20))
>   >
>   > (setq-local test-buffer (get-buffer-create "test child-frame"))
>   > (setq-local test-frame (window-frame (open-test test-buffer)))
>   >
>   > (resize-test test-frame)
[...]
> Both, 'display-buffer-in-child-frame' and 'set-frame-height', should
> be written in a way that the child frame surely fits into its parent.
> If you don't, the window manager might do strange things.
>
> Sorry, i do not understand this, more detail or an example?

I meant that resizing the child frame from 10 to 20 lines with the
given (50, 50) position might make edges of the child frame exceed the
edges of its parent and the window manager might not like that.  In
particular, a program like GNOME-shell that, as we've seen in
Bug#38452, seems to have its own interpretation of coordinates (I have
no idea what GNOME-shell is and does).

> Also, I would disable all decorations that are not strictly needed.
> For example, with a GTK build using your parameters I get a tool bar
> on the child frame as soon as I type some character into it (which
> might be an Emacs bug in one or the other way).  That tool bar is
> truncated and GTK may not behave well with truncated tool bars.  See
> section 29.14 of the Elisp manual for what better not to do on child
> frames.
>
> i think it is not toolbar's problem,posframe use childframe without toolbar, 
has resize problem too,

Is it resizing only or moving the frame too?

> i think it may be gnome-shell problem, for other wm has no this problem

Maybe we should contact their developers.  Here, moving and sizing
child frames seems noticeably smoother with my Windows builds than
with my Debian builds.

martin




reply via email to

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