Geometry creep

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Geometry creep

Peter Bloomfield
Dear List,

On my cramped laptop, I usually maximize Balsa, and recently I've noticed "geometry creep": the mailbox list on the left and the message list above the message preview grow by a few pixels from time to time. Balsa saves the geometry at the end of each session, and restores it at the start of a new one, but then Gtk sometimes changes it a couple of times at startup--I can't figure out why or how, nor when it started.

Waiting for a second before restoring the geometry seems to avoid the problem, but of course leads to a visible adjustment immediately after the main window appears. To my mind it's a reasonable price to pay for a stable geometry, but that's a personal evaluation.

The fix has been pushed to the master branch, so as always all feedback is welcome!

Best regards,

Peter
_______________________________________________
balsa-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/balsa-list

attachment0 (188 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Geometry creep

Albrecht Dreß
Hi Peter:

Am 24.05.17 03:12 schrieb(en) Peter Bloomfield:
> On my cramped laptop, I usually maximize Balsa, and recently I've noticed "geometry creep": the mailbox list on the left and the message list above the message preview grow by a few pixels from time to time.

Ha!  On 22 June 2016, I submitted a patch for the opposite effect, i.e. these two areas were /shrinking/ after each re-start of Balsa.  The patch (using an idle callback) fixed the issue for me.  However, I do not use Balsa in maximised window mode.  Or the idle callback kicks in too fast.

> Balsa saves the geometry at the end of each session, and restores it at the start of a new one, but then Gtk sometimes changes it a couple of times at startup--I can't figure out why or how, nor when it started.

I also never found out why this behaviour occurs...

> Waiting for a second before restoring the geometry seems to avoid the problem, but of course leads to a visible adjustment immediately after the main window appears. To my mind it's a reasonable price to pay for a stable geometry, but that's a personal evaluation.
>
> The fix has been pushed to the master branch, so as always all feedback is welcome!

I closed and re-opened Balsa several times using the latest git version, and the geometry is kept as it should be...  So your patch works for me!

Cheers,
Albrecht.
_______________________________________________
balsa-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/balsa-list

attachment0 (484 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Geometry creep

Peter Bloomfield
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Albrecht:

On 05/24/2017 01:40:28 PM Wed, Albrecht Dreß wrote:
> Hi Peter:
>
> Am 24.05.17 03:12 schrieb(en) Peter Bloomfield:
>> On my cramped laptop, I usually maximize Balsa, and recently I've noticed "geometry creep": the mailbox list on the left and the message list above the message preview grow by a few pixels from time to time.
>
> Ha!  On 22 June 2016, I submitted a patch for the opposite effect, i.e. these two areas were /shrinking/ after each re-start of Balsa.  The patch (using an idle callback) fixed the issue for me.  However, I do not use Balsa in maximised window mode.  Or the idle callback kicks in too fast.

Thanks for the reminder! I revisited that patch, and found a far less intrusive fix: yes, when Balsa is maximized the idle callback comes too soon, and I had previously made it a half-second timeout when maximized. I upped it to 0.6 seconds, and the geometry now seems to be stabilized. The code path when not maximized should now be back to what it was before my recent commit.

I don't know why the half-second is no longer enough; perhaps this laptop is slower than the old one (sad!), or perhaps rendering is now taking longer. Others may need it even longer--please report any creep issues!

I'll recommit part of the now reverted patch: connecting to the "notify::is-maximized" signal generates less noise than "window-state-event".

Best,

Peter
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAlkm8PAACgkQH1/UtbkqdPX4wgCfeBak6oPIOqVr22n1N3BkT6lE
SUkAoJe3jcsViza7CwzQODqTC5H2yTPi
=gBgM
-----END PGP SIGNATURE-----
_______________________________________________
balsa-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/balsa-list
Loading...