unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
@ 2016-11-18 12:10 Stephen Berman
  2016-11-18 14:01 ` Óscar Fuentes
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Stephen Berman @ 2016-11-18 12:10 UTC (permalink / raw)
  To: 24963

0. emacs -Q
1. M-x toggle-frame-maximized
   => frame is maximized
2. M-x toggle-frame-maximized
   => frame remains maximized, echo area displays "You can run the
   command ‘toggle-frame-maximized’ with <M-f10>"
3. M-x toggle-frame-maximized
   => now frame is restored to its prior size

Git bisect says

c29071587c64efb30792bd72248d3c791abd9337 is the first bad commit
commit c29071587c64efb30792bd72248d3c791abd9337
Author: Daniel Colascione <dancol@dancol.org>
Date:   Thu Oct 20 20:34:36 2016 -0700

    Add double-buffering support to reduce flicker

Something in this patch seems to have affected modify-frame-parameters:
in step 1 of the above recipe, the following code is executed (via
set-frame-parameter): 

(modify-frame-parameters nil (list (cons 'fullscreen 'maximized)))

However, subsequently evaluating (frame-parameter nil 'fullscreen)
returns nil, so that in step 2, the frame-parameter is (again) modified,
though the frame is already maximized.  Now, however,  evaluating
(frame-parameter nil 'fullscreen) returns `maximized', so in step 3, the
frame is now demaximized.

I executed modify-frame-parameters with a couple of other frame
parameters, but didn't observe a similar problem.

In GNU Emacs 26.0.50.5 (x86_64-suse-linux-gnu, GTK+ Version 3.14.15)
 of 2016-11-16 built on rosalinde
Repository revision: f63976857b4458bc7712e91d95c04fe2e2ca0106
Windowing system distributor 'The X.Org Foundation', version 11.0.11601000
System Description:	openSUSE 13.2 (Harlequin) (x86_64)





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

* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
  2016-11-18 12:10 bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch Stephen Berman
@ 2016-11-18 14:01 ` Óscar Fuentes
  2016-11-18 18:43   ` Stephen Berman
  2016-11-25 23:29 ` Stephen Berman
  2017-03-02 11:01 ` martin rudalics
  2 siblings, 1 reply; 7+ messages in thread
From: Óscar Fuentes @ 2016-11-18 14:01 UTC (permalink / raw)
  To: Stephen Berman; +Cc: 24963

Stephen Berman <stephen.berman@gmx.net> writes:

> 0. emacs -Q
> 1. M-x toggle-frame-maximized
>    => frame is maximized
> 2. M-x toggle-frame-maximized
>    => frame remains maximized,

Cannot reproduce, either with latest master
(e8efa66e01933b8ae7ac9abf530a3818551c1343) nor with a build made just
after the double-buffering feature was committed:

In GNU Emacs 26.0.50.1 (x86_64-pc-linux-gnu, X toolkit)
 of 2016-10-21 built on qcore
Repository revision: 0929e061fb544c0f4c10ff0412a41cf7e8148270
Windowing system distributor 'The X.Org Foundation', version 11.0.11804000
System Description:	Ubuntu 16.10

(Note that I use Lucid.)

[snip]





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

* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
  2016-11-18 14:01 ` Óscar Fuentes
@ 2016-11-18 18:43   ` Stephen Berman
  2016-11-18 19:52     ` Óscar Fuentes
  0 siblings, 1 reply; 7+ messages in thread
From: Stephen Berman @ 2016-11-18 18:43 UTC (permalink / raw)
  To: Óscar Fuentes; +Cc: 24963

On Fri, 18 Nov 2016 15:01:10 +0100 Óscar Fuentes <ofv@wanadoo.es> wrote:

> Stephen Berman <stephen.berman@gmx.net> writes:
>
>> 0. emacs -Q
>> 1. M-x toggle-frame-maximized
>>    => frame is maximized
>> 2. M-x toggle-frame-maximized
>>    => frame remains maximized,
>
> Cannot reproduce, either with latest master
> (e8efa66e01933b8ae7ac9abf530a3818551c1343) nor with a build made just
> after the double-buffering feature was committed:
>
> In GNU Emacs 26.0.50.1 (x86_64-pc-linux-gnu, X toolkit)
>  of 2016-10-21 built on qcore
> Repository revision: 0929e061fb544c0f4c10ff0412a41cf7e8148270
> Windowing system distributor 'The X.Org Foundation', version 11.0.11804000
> System Description:	Ubuntu 16.10
>
> (Note that I use Lucid.)

I guess this is a toolkit-specific bug, then, perhaps GTK+ only.

(Unfortunately, I cannot build with lucid or even with no toolkit: both
fail with this error:

/usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: image.o: undefined reference to symbol 'png_set_longjmp_fn@@PNG16_0'
/usr/lib64/libpng16.so.16: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
Makefile:611: recipe for target 'temacs' failed
)

Steve Berman





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

* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
  2016-11-18 18:43   ` Stephen Berman
@ 2016-11-18 19:52     ` Óscar Fuentes
  2016-11-18 20:36       ` Stephen Berman
  0 siblings, 1 reply; 7+ messages in thread
From: Óscar Fuentes @ 2016-11-18 19:52 UTC (permalink / raw)
  To: Stephen Berman; +Cc: 24963

Stephen Berman <stephen.berman@gmx.net> writes:

> I guess this is a toolkit-specific bug, then, perhaps GTK+ only.
>
> (Unfortunately, I cannot build with lucid or even with no toolkit: both
> fail with this error:
>
> /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld: image.o: undefined reference to symbol 'png_set_longjmp_fn@@PNG16_0'
> /usr/lib64/libpng16.so.16: error adding symbols: DSO missing from command line
> collect2: error: ld returned 1 exit status
> Makefile:611: recipe for target 'temacs' failed
> )
>
> Steve Berman

Try installing the build dependencies. I don't know the respective
package names on SUSE. IIRC, on Ubuntu/Debian they are:

autoconf automake libpoppler-dev texinfo libjpeg-dev libncurses5-dev
libgif-dev libtiff-dev libpng-dev librsvg2-dev libotf-dev libxml2-dev
xaw3dg-dev libgnutls28-dev

I guess there is a command for installing the build dependencies of a
given binary package too.

Make sure that you start from a clean source directory:

$ cd emacs_source
$ git clean -f -d -x
$ ./autogen.sh

Now create a new build directory

$ mkgir build && cd build

This is what I use for Lucid:

$ path/to/emacs/source/configure --without-toolkit-scroll-bars --with-x-toolkit=lucid

If the error about png persists, add --without-png to the configure
command.

HTH.





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

* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
  2016-11-18 19:52     ` Óscar Fuentes
@ 2016-11-18 20:36       ` Stephen Berman
  0 siblings, 0 replies; 7+ messages in thread
From: Stephen Berman @ 2016-11-18 20:36 UTC (permalink / raw)
  To: Óscar Fuentes; +Cc: 24963

On Fri, 18 Nov 2016 20:52:15 +0100 Óscar Fuentes <ofv@wanadoo.es> wrote:

> Stephen Berman <stephen.berman@gmx.net> writes:
>
>> I guess this is a toolkit-specific bug, then, perhaps GTK+ only.
>>
>> (Unfortunately, I cannot build with lucid or even with no toolkit: both
>> fail with this error:
>>
>> /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld:
>> image.o: undefined reference to symbol 'png_set_longjmp_fn@@PNG16_0'
>> /usr/lib64/libpng16.so.16: error adding symbols: DSO missing from command line
>> collect2: error: ld returned 1 exit status
>> Makefile:611: recipe for target 'temacs' failed
>> )
>>
>> Steve Berman
>
> Try installing the build dependencies. [...]

I have all necessary dependencies.  This is a longstanding issue for me,
see https://debbugs.gnu.org/cgi/bugreport.cgi?bug=17771#95

> If the error about png persists, add --without-png to the configure
> command.

Oh, yes, I forgot about that, thanks.  With that flag I can build with
lucid and indeed, toggle-frame-maximized works fine with that build
(from latest master).  So that seems to confirm this bug is GTK+-specific.

Steve Berman





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

* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
  2016-11-18 12:10 bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch Stephen Berman
  2016-11-18 14:01 ` Óscar Fuentes
@ 2016-11-25 23:29 ` Stephen Berman
  2017-03-02 11:01 ` martin rudalics
  2 siblings, 0 replies; 7+ messages in thread
From: Stephen Berman @ 2016-11-25 23:29 UTC (permalink / raw)
  To: 24963

On Fri, 18 Nov 2016 13:10:30 +0100 Stephen Berman <stephen.berman@gmx.net> wrote:

> 0. emacs -Q
> 1. M-x toggle-frame-maximized
>    => frame is maximized
> 2. M-x toggle-frame-maximized
>    => frame remains maximized, echo area displays "You can run the
>    command ‘toggle-frame-maximized’ with <M-f10>"
> 3. M-x toggle-frame-maximized
>    => now frame is restored to its prior size
>
> Git bisect says
>
> c29071587c64efb30792bd72248d3c791abd9337 is the first bad commit
> commit c29071587c64efb30792bd72248d3c791abd9337
> Author: Daniel Colascione <dancol@dancol.org>
> Date:   Thu Oct 20 20:34:36 2016 -0700
>
>     Add double-buffering support to reduce flicker
>
> Something in this patch seems to have affected modify-frame-parameters:
> in step 1 of the above recipe, the following code is executed (via
> set-frame-parameter): 
>
> (modify-frame-parameters nil (list (cons 'fullscreen 'maximized)))
>
> However, subsequently evaluating (frame-parameter nil 'fullscreen)
> returns nil, so that in step 2, the frame-parameter is (again) modified,
> though the frame is already maximized.  Now, however,  evaluating
> (frame-parameter nil 'fullscreen) returns `maximized', so in step 3, the
> frame is now demaximized.
>
> I executed modify-frame-parameters with a couple of other frame
> parameters, but didn't observe a similar problem.
>
> In GNU Emacs 26.0.50.5 (x86_64-suse-linux-gnu, GTK+ Version 3.14.15)
>  of 2016-11-16 built on rosalinde
> Repository revision: f63976857b4458bc7712e91d95c04fe2e2ca0106
> Windowing system distributor 'The X.Org Foundation', version 11.0.11601000
> System Description:	openSUSE 13.2 (Harlequin) (x86_64)

I just determined that the failure to demaximize in step 2 above only
happens when scroll-bar-mode is enabled.  I guess this is related to the
code added to src/gtkutil.c by the above patch to "[f]orce [GTK+] scroll
bars to be real X11 windows".

Steve Berman





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

* bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch
  2016-11-18 12:10 bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch Stephen Berman
  2016-11-18 14:01 ` Óscar Fuentes
  2016-11-25 23:29 ` Stephen Berman
@ 2017-03-02 11:01 ` martin rudalics
  2 siblings, 0 replies; 7+ messages in thread
From: martin rudalics @ 2017-03-02 11:01 UTC (permalink / raw)
  To: Stephen Berman, 24963-done

 > 0. emacs -Q
 > 1. M-x toggle-frame-maximized
 >     => frame is maximized
 > 2. M-x toggle-frame-maximized
 >     => frame remains maximized, echo area displays "You can run the
 >     command ‘toggle-frame-maximized’ with <M-f10>"
 > 3. M-x toggle-frame-maximized
 >     => now frame is restored to its prior size

Fixed by commit ae8835619655a0e28c4d84bbd8c46cc29aac6ad3.  Bug closed.

Thanks, martin






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

end of thread, other threads:[~2017-03-02 11:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-18 12:10 bug#24963: 26.0.50; toggle-frame-maximized broken by double-buffering patch Stephen Berman
2016-11-18 14:01 ` Óscar Fuentes
2016-11-18 18:43   ` Stephen Berman
2016-11-18 19:52     ` Óscar Fuentes
2016-11-18 20:36       ` Stephen Berman
2016-11-25 23:29 ` Stephen Berman
2017-03-02 11:01 ` martin rudalics

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).