all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Error displaying a frame modified with (tool-bar-lines . 0)
@ 2014-03-25 12:45 Juanma Barranquero
  2014-03-25 15:45 ` Eli Zaretskii
  2014-03-27 15:28 ` bug#17120: Fwd: " Juanma Barranquero
  0 siblings, 2 replies; 8+ messages in thread
From: Juanma Barranquero @ 2014-03-25 12:45 UTC (permalink / raw
  To: Emacs developers

After much back and forth, bug#17046 has been determined to be that running

  emacs -Q -l bug.el

with bug.el:

;;; bug.el
(let* ((default-frame-alist nil)
       (frame (make-frame '((width . 80) (height . 20))))
       (lines (frame-parameter frame 'tool-bar-lines)))
  (discard-input)
  (read-event nil nil 2)
  (modify-frame-parameters frame '((tool-bar-lines . 0)
                                   (width . 60) (height . 25)))
  (modify-frame-parameters frame `((tool-bar-lines . ,lines))))
;;, end

causes the frame to be redisplayed incorrectly (the trigger being the
(tool-bar-lines .0) parameter:

http://debbugs.gnu.org/cgi/bugreport.cgi?msg=26;filename=emacs-sshot.png;att=1;bug=17046

This happens on a Ubuntu 13.10:

GNU Emacs 24.3.50.2 (i686-pc-linux-gnu, GTK+ Version 3.8.6)
 of 2014-03-14 on poulenc
Repository revision: 116756 rudalics <at> gmx.at-20140314103846-ytcz7b30ocmzo8jh
Windowing system distributor `The X.Org Foundation', version 11.0.11405000
System Description: Ubuntu 13.10

Important settings:
  value of $LANG: en_GB.UTF-8
  locale-coding-system: utf-8-unix

Anyone knowledgeable about this kind of issue is welcome to drop by bug#17046.

TIA,

   J



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

* Re: Error displaying a frame modified with (tool-bar-lines . 0)
  2014-03-25 12:45 Error displaying a frame modified with (tool-bar-lines . 0) Juanma Barranquero
@ 2014-03-25 15:45 ` Eli Zaretskii
  2014-03-25 15:53   ` Juanma Barranquero
  2014-03-27 15:28 ` bug#17120: Fwd: " Juanma Barranquero
  1 sibling, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2014-03-25 15:45 UTC (permalink / raw
  To: Juanma Barranquero; +Cc: emacs-devel

> From: Juanma Barranquero <lekktu@gmail.com>
> Date: Tue, 25 Mar 2014 13:45:00 +0100
> 
> After much back and forth, bug#17046 has been determined to be that running
> 
>   emacs -Q -l bug.el
> 
> with bug.el:
> 
> ;;; bug.el
> (let* ((default-frame-alist nil)
>        (frame (make-frame '((width . 80) (height . 20))))
>        (lines (frame-parameter frame 'tool-bar-lines)))
>   (discard-input)
>   (read-event nil nil 2)
>   (modify-frame-parameters frame '((tool-bar-lines . 0)
>                                    (width . 60) (height . 25)))
>   (modify-frame-parameters frame `((tool-bar-lines . ,lines))))
> ;;, end
> 
> causes the frame to be redisplayed incorrectly (the trigger being the
> (tool-bar-lines .0) parameter:
> 
> http://debbugs.gnu.org/cgi/bugreport.cgi?msg=26;filename=emacs-sshot.png;att=1;bug=17046

Is this GTK-specific?  (I don't see the problem on Windows.)  Did
someone try this with Lucid, or without any toolkits?



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

* Re: Error displaying a frame modified with (tool-bar-lines . 0)
  2014-03-25 15:45 ` Eli Zaretskii
@ 2014-03-25 15:53   ` Juanma Barranquero
  0 siblings, 0 replies; 8+ messages in thread
From: Juanma Barranquero @ 2014-03-25 15:53 UTC (permalink / raw
  To: Eli Zaretskii; +Cc: Emacs developers

On Tue, Mar 25, 2014 at 4:45 PM, Eli Zaretskii <eliz@gnu.org> wrote:

> Is this GTK-specific?

It's quite possible.

>  (I don't see the problem on Windows.)

bug#14795 is a (mostly, but perhaps not uniquely) Windows problem
where (height . X) produces frames of different heights when used in
make-frame and modify-frame-parameters. The workaround is to modify
the frame height with (tool-bar-lines . 0) and then reset the
tool-bar-lines to its original value. And that workaround in
frameset.el is what triggers bug#17046.

> Did someone try this with Lucid, or without any toolkits?

Don't know, but any Lucid or non-tookit users who run trunk and
desktop.el are already implicitly testing it. This is the first report we
get for this specific problem.

    J



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

* bug#17120: Fwd: Error displaying a frame modified with (tool-bar-lines . 0)
  2014-03-25 12:45 Error displaying a frame modified with (tool-bar-lines . 0) Juanma Barranquero
  2014-03-25 15:45 ` Eli Zaretskii
@ 2014-03-27 15:28 ` Juanma Barranquero
       [not found]   ` <5336BC84.5050306@swipnet.se>
  2021-05-02  8:47   ` martin rudalics
  1 sibling, 2 replies; 8+ messages in thread
From: Juanma Barranquero @ 2014-03-27 15:28 UTC (permalink / raw
  To: 17120; +Cc: robert

Package: emacs
Severity: minor
X-Debbugs-CC: robert@capuchin.co.uk


This is the underlying bug with GTK and Emacs that caused bug#17046.

It's minor because it's unlikely that modifying frames' heights with
tool-bar-lines = 0 be a common operation.


  emacs -Q -l bug.el

with bug.el:

;;; bug.el
(let* ((default-frame-alist nil)
       (frame (make-frame '((width . 80) (height . 20))))
       (lines (frame-parameter frame 'tool-bar-lines)))
  (discard-input)
  (read-event nil nil 2)
  (modify-frame-parameters frame '((tool-bar-lines . 0)
                                   (width . 60) (height . 25)))
  (modify-frame-parameters frame `((tool-bar-lines . ,lines))))
;;, end

causes the frame to be redisplayed incorrectly (the trigger being the
(tool-bar-lines . 0) parameter:

http://debbugs.gnu.org/cgi/bugreport.cgi?msg=26;filename=emacs-sshot.png;att=1;bug=17046

This happens on a Ubuntu 13.10:

GNU Emacs 24.3.50.2 (i686-pc-linux-gnu, GTK+ Version 3.8.6)
 of 2014-03-14 on poulenc
Repository revision: 116756 rudalics <at> gmx.at-20140314103846-ytcz7b30ocmzo8jh
Windowing system distributor `The X.Org Foundation', version 11.0.11405000
System Description: Ubuntu 13.10

Important settings:
  value of $LANG: en_GB.UTF-8
  locale-coding-system: utf-8-unix





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

* bug#17120: Fwd: Error displaying a frame modified with (tool-bar-lines . 0)
       [not found]   ` <5336BC84.5050306@swipnet.se>
@ 2014-03-29 13:25     ` Robert Marshall
  2014-03-31 12:48     ` Robert Marshall
  1 sibling, 0 replies; 8+ messages in thread
From: Robert Marshall @ 2014-03-29 13:25 UTC (permalink / raw
  To: Jan Djärv; +Cc: 17120, Juanma Barranquero

Jan Djärv writes:
 > Hello.
 > 
 > Is this still an issue?  I can't reproduce it on Mint 16, Gtk+ 3.8.7.
 > It could be window manager related.  Are you running Unity?
 > I'll see if I have some Ubuntu lying around.
 >
 
Yes it's still replicable - I'm running kde/plasma

I've just tried running the test in an Xnest session with
fluxbox/windowMaker/sawfish and in all cases the session crashes with

X Error of failed request:  BadDrawable (invalid Pixmap or Window parameter)
  Major opcode of failed request:  70 (X_PolyFillRectangle)
  Resource id in failed request:  0x0
  Serial number of failed request:  30246
  Current serial number in output stream:  30246

at the point where the second emacs frame appears. Maybe they (or Xnest)
can't cope with the weird window.

With unity there doesn't seem to be a --display option and running it
from a normal session the bug doesn't appear - the 2nd frame is drawn
normally so the bug looks very window manager related.

Robert






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

* bug#17120: Fwd: Error displaying a frame modified with (tool-bar-lines . 0)
       [not found]   ` <5336BC84.5050306@swipnet.se>
  2014-03-29 13:25     ` Robert Marshall
@ 2014-03-31 12:48     ` Robert Marshall
  1 sibling, 0 replies; 8+ messages in thread
From: Robert Marshall @ 2014-03-31 12:48 UTC (permalink / raw
  To: Jan Djärv; +Cc: 17120, Juanma Barranquero

Jan Djärv writes:
 > Hello.
 > 
 > Is this still an issue?  I can't reproduce it on Mint 16, Gtk+ 3.8.7.
 > It could be window manager related.  Are you running Unity?
 > I'll see if I have some Ubuntu lying around.
 > 

One point I should add to that last comment (of mine)- it was buried
somewhere in the original 17046 bug thread - I only see the problem if
the emacs frames doesn't get keyboard focus until after the startup
has completed - I assume that's also why eval'ing that expression in
*scratch* doesn't show the problem. So you may need to reconfigure
your X session if it is set up so that new windows get focus automatically.

The frames look ok until the moment I give them focus when the minibuffer
and the X decorations then disappear.

Robert
-- 
Robert Marshall





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

* bug#17120: Fwd: Error displaying a frame modified with (tool-bar-lines . 0)
  2014-03-27 15:28 ` bug#17120: Fwd: " Juanma Barranquero
       [not found]   ` <5336BC84.5050306@swipnet.se>
@ 2021-05-02  8:47   ` martin rudalics
  2021-05-19  8:13     ` martin rudalics
  1 sibling, 1 reply; 8+ messages in thread
From: martin rudalics @ 2021-05-02  8:47 UTC (permalink / raw
  To: Juanma Barranquero, 17120; +Cc: robert

 > This is the underlying bug with GTK and Emacs that caused bug#17046.
 >
 > It's minor because it's unlikely that modifying frames' heights with
 > tool-bar-lines = 0 be a common operation.
 >
 >
 >    emacs -Q -l bug.el
 >
 > with bug.el:
 >
 > ;;; bug.el
 > (let* ((default-frame-alist nil)
 >         (frame (make-frame '((width . 80) (height . 20))))
 >         (lines (frame-parameter frame 'tool-bar-lines)))
 >    (discard-input)
 >    (read-event nil nil 2)
 >    (modify-frame-parameters frame '((tool-bar-lines . 0)
 >                                     (width . 60) (height . 25)))
 >    (modify-frame-parameters frame `((tool-bar-lines . ,lines))))
 > ;;, end
 >
 > causes the frame to be redisplayed incorrectly (the trigger being the
 > (tool-bar-lines . 0) parameter:
 >
 > http://debbugs.gnu.org/cgi/bugreport.cgi?msg=26;filename=emacs-sshot.png;att=1;bug=17046
 >
 > This happens on a Ubuntu 13.10:
 >
 > GNU Emacs 24.3.50.2 (i686-pc-linux-gnu, GTK+ Version 3.8.6)
 >   of 2014-03-14 on poulenc
 > Repository revision: 116756 rudalics <at> gmx.at-20140314103846-ytcz7b30ocmzo8jh
 > Windowing system distributor `The X.Org Foundation', version 11.0.11405000
 > System Description: Ubuntu 13.10

I now checked in a fix.  Please have a look.

On builds with an internal tool bar you have to, for example,

(setq frame-inhibit-implied-resize nil)

to get the desired 25 lines.  Otherwise, the

(tool-bar-lines . ,lines)

will steal the necessary lines from the frame's text area.

Thanks, martin





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

* bug#17120: Fwd: Error displaying a frame modified with (tool-bar-lines . 0)
  2021-05-02  8:47   ` martin rudalics
@ 2021-05-19  8:13     ` martin rudalics
  0 siblings, 0 replies; 8+ messages in thread
From: martin rudalics @ 2021-05-19  8:13 UTC (permalink / raw
  To: Juanma Barranquero, 17120; +Cc: robert

tags 17120 fixed
close 17120 28.1
quit

 > I now checked in a fix.  Please have a look.
 >
 > On builds with an internal tool bar you have to, for example,
 >
 > (setq frame-inhibit-implied-resize nil)
 >
 > to get the desired 25 lines.  Otherwise, the
 >
 > (tool-bar-lines . ,lines)
 >
 > will steal the necessary lines from the frame's text area.

Bug marked as done now.

martin





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

end of thread, other threads:[~2021-05-19  8:13 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-25 12:45 Error displaying a frame modified with (tool-bar-lines . 0) Juanma Barranquero
2014-03-25 15:45 ` Eli Zaretskii
2014-03-25 15:53   ` Juanma Barranquero
2014-03-27 15:28 ` bug#17120: Fwd: " Juanma Barranquero
     [not found]   ` <5336BC84.5050306@swipnet.se>
2014-03-29 13:25     ` Robert Marshall
2014-03-31 12:48     ` Robert Marshall
2021-05-02  8:47   ` martin rudalics
2021-05-19  8:13     ` martin rudalics

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.