Subject: Re: bug#13469: 24.2; emacs has a tiny frame, when I embed it in a kmail text field via xembed (--parent-id %w)

From: Eli Zaretskii <[email-masked]>
Date: Wed, 20 Mar 2013 21:26:56 +0200

[Please keep the bug address on the CC list.]

> Date: Wed, 20 Mar 2013 10:00:00 +0100
> From: "Arne Babenhauserheide (IMK)" <[email-masked]>
> 
> > Is there any evidence that this is an Emacs bug, and not a bug in
> > qxembed-emacs.py?  Can you reproduce something similar with just
> > Emacs?
> 
> The cue for that is that the same happens with kmail, which I did not
> write, and that qxembed-emacs.py is just a 47 lines script, which can be
> reduced to the following by removing emacs version checks and
> commandline argument parsing:
> 
>     from PyQt4.QtGui import QX11EmbedContainer, QApplication
>     from PyQt4.QtCore import QProcess, SIGNAL, SLOT
>     from sys import argv
> 
>     app = QApplication(argv)
> 
>     container = QX11EmbedContainer()
>     container.resize(670, 630)
>     container.show()
> 
>     process = QProcess(container)
>     process.start("emacs", ["--parent-id", str(container.winId())])
> 
>     container.connect(container, SIGNAL("clientClosed()"), app.quit)
> 
>     container.connect(container,
> SIGNAL("error(QX11EmbedContainer::Error)"), app.quit)
> 
>     status = app.exec_()
>     process.close()
> 
> 
> There might also be a bug in Qt, which triggers this behavior.
> 
> Especially strange is that it works with emacs -Q --basic-display.

The --basic-display disables menu bar and tool bar, and also disables
blinking cursor.  Maybe the absent menu and tool bar somehow affect
this, when you resize the qxembed-window?

I suggest to put a breakpoint in change_frame_size, and see who calls
it with such a small frame size.