Mailing list archives : pcb-rnd

ID:5659
From:rn...@igor2.repo.hu
Date:Wed, 18 May 2022 05:26:12 +0200 (CEST)
Subject:[pcb-rnd] new: window placement code also remembers paned positions
replies: 5660 from rn...@igor2.repo.hu , 5667 from Wojciech Krutnik <wo...@gmail.com>
Hi all,
 
Wojciech, please test and ACK, it was your feature request.
 
 
1. what it is
 
We have code in librnd for saving and restoring window geometry (window 
position and window size). This is generally a bad idea, because the 
window manager should do such things, but it turns out majority of our 
users, even UNIX hacker pcb-rnd users, are using window managers that are 
too lame to do this. So we have this _option_, off-by-default, that you 
can get librnd apps do this, sort of overriding the window manager.
 
This option got upgraded now so that it also remembers paned widget 
positions inside windows. (A paned widget is when you have the dialog box 
split with a horizontal or vertical sweeper and you can grab and move it 
to decide how much screen estate you want to allocate to each side; e.g. 
in library window, if you resize the window larger, you can change the 
left/right splitup).
 
This is something window managers can not do, as it's a window-internal 
widget allocation question.
 
 
2. where is it implemented, how does it work
 
It is implemented in librnd svn HEAD, will be part of the upcoming 
librnd 3.2.0 release. Since it is in librnd, it will affect all ringdove 
apps, at different times (this requires ringdove apps to raise minimum 
required librnd version to 3.2.0, which means we first need to release 
librnd 3.2.0, so some apps will get it later, some sooner, depending on 
release cycles, see below.)
 
If you save window position and enable window position reload (preferences 
dialog, window tab), it now also saves paned widget positions in subtrees 
under each window affected. This doesn't happen automatically on any paned 
widget, only named paned widgets, so it requires the app to name them, 
which is a new feature in 3.2.0, that's why all the version dependency 
delays.
 
 
3. in librnd dialogs
 
The original feature request was that the file selection dialog should 
have this; now it does. Furhtermore it's done for the script dialog and 
preferences dialog conf tree tab. (These dialogs/tabs are all implemented 
in librnd.)
 
Since librnd 3.2.0 is backward compatible down to librnd 3.0.0, you can 
enjoy this feauture even with older versions of the apps (pcb-rnd, 
sch-rnd) for the above dialog boxes and tabs. This is also how you can 
easiest test it now.
 
 
4. in pcb-rnd's own dialogs
 
Not yet available. The next release will not yet depend on librnd 
3.2.0, only the release after. So for pcb-rnd's own dialog boxes, this 
feature will arrive around late summer in svn and then in the release 
following that. 
 
(Note: as described in point 3, the file selection dialog, scripting 
dialog and one of the preferences tabs are exceptions, they should work 
already, or even with older versions of pcb-rnd, if you try with svn HEAD 
librnd, because these are implemented in librnd.)
 
 
5. in sch-rnd
 
Since sch-rnd in its current state always depends on svn HEAD librnd, I 
have more freedom there, so I went and named all paned widgets. So all 
dialog boxes you see in sch-rnd can save paned positions.
 
 
6. camv-rnd
 
Easiest one: at the moment it doesn't have any own dialog box with paned 
view.
 
 
7. the big exception
 
Top window paned position (between the left side "layer selector" and the 
right side "drawing area") is NOT remembered. This is because the top 
window is not a DAD dialog.
 
I am not going to add a special case for this one, because longer term I 
want to convert the top window into a DAD dialog. So we will need to live 
with this for now.
 
 
Best regards,
 
Igor2
 
 
 
 
 

Reply subtree:
5659 [pcb-rnd] new: window placement code also remembers paned positions from rn...@igor2.repo.hu
  5660 [pcb-rnd] lesstif: no paned widgets (+ phasing out); was: window placement code also remembers paned positions from rn...@igor2.repo.hu
  5667 Re: [pcb-rnd] new: window placement code also remembers paned from Wojciech Krutnik <wo...@gmail.com>