X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com X-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=BMglmHxilGSX4mfDX0RPKXWzHm9GGqGnoRcP0uo63gI=; b=rTWnV/G4WKbchiDmEVS4NboYMHH7dEb7DJfSyN+bM/tX3NHA1r5adNgwmov3lNK6Db 1OH13vVd9UMSQPMo6QEEOkDdGlRtghJZEd9yBLuKxa3HHzNCaAba5lAtnRQyRJZmJI9c N0KWge34zlDZWLZT7tB1vGEcD/mJ/xgM6wfWMjWFRofxAm37NIJmFxBkCfDpAlFt53gn QwMn3RsI8/GrphoA9NhHqBQNSDWNgI+d8doXLfaSldctciD6j1E8t2Ql6sVGNmbPAZMD 00WCdhUcZgG7gS4C0y0aoHrU11vCveZNAmKLhYeTk43pgAU8KriTBIN0eQ3b6A3g/QLR +M3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=BMglmHxilGSX4mfDX0RPKXWzHm9GGqGnoRcP0uo63gI=; b=hs16uZk1oFbpsxDZY0TfkjvZrCfF2RqmtVG5KfrgwdlQKQnJCHcp1GIIGRnHbmd/Bs kTFLA4YwswpViGzsKLTMyprAAYO1SGNC5O4nH1ipIUw69jam4K1LoxEdJiqbHe0fRha4 KuizcSTEevn6Uir68P+GYbhMhsKbtRRfrttnljyrZCGWvr0alwBp3C4YkzImKC3nasHy TSAlmO7LmCDxvEJkEA46C+ptEksEHgNsl498D9PO/XcFh5RgPkb6N7iUutAvgH3mRwoc 1NKm4q0SjkbGDrfNpcRCA9BCnCU9imRf7P1M6IcgDD6Gsz+FEqNVVn94zGkWsB5F/Ksj ouLw== X-Gm-Message-State: ALyK8tL6+bZrOoIBtha+/sgc03xhjOr5MDAiJfLK6/12KU/etXn/3MJ4OaI1G2GLBL5y6y725qMNjMW5yA6yRA== X-Received: by 10.157.40.2 with SMTP id m2mr9086221otb.99.1465911918969; Tue, 14 Jun 2016 06:45:18 -0700 (PDT) MIME-Version: 1.0 References: <20160614133519 DOT 584949a5 AT wind DOT levalinux DOT org> In-Reply-To: <20160614133519.584949a5@wind.levalinux.org> From: "Damian (damianzrb AT gmail DOT com) [via geda-user AT delorie DOT com]" Date: Tue, 14 Jun 2016 13:45:09 +0000 Message-ID: Subject: Re: [geda-user] RFC: gtk-hid window size save/restore To: geda-user AT delorie DOT com Content-Type: multipart/alternative; boundary=001a113d0c8633ceb705353d3772 Reply-To: geda-user AT delorie DOT com --001a113d0c8633ceb705353d3772 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable It's not better to save window geometry scale (0-100% on width and 0-100% on height)instead of px x px? Easier to resizing a window on different screen sizes. wt., 14 cze 2016, 13:44 u=C5=BCytkownik Kovacs Levente (leventelist AT gmail DOT c= om) [via geda-user AT delorie DOT com] napisa=C5=82: > On Tue, 14 Jun 2016 07:58:14 +0200 (CEST) > gedau AT igor2 DOT repo DOT hu wrote: > > > Hi all! > > > > I've arrived at the gtk hid's "window width/height save/restore" code > > in my conf-rewrite in pcb-rnd. Long story short: the gtk hid tries to > > remember window geometry and tries to restore it to the last known > > state (?) when pcb is started. > > > > Thinking it over, I am not sure this is a good idea (while I totally > > see why many users probably want it). > > > > I am interested in your input, as an user of GUI apps in general (I > > don't think this is pcb-specific) about how this is best done. > > Conceptually the question is, assuming pcb-rnd needs to save/restore > > window sizes, whose property window sizes is? The program's? The > > user's? The desing's? The session's? This gets tricky especially in > > corner cases like laptops with variable screen sizes (large external > > screen when docked and small screen on the road). > > > > Please comment on the following options, or add extra options if you > > see any: > > > > 1. Do not try to save window geometry, let the window manager do its > > job. This is how I do it: my wm runs an awk script that regex-matches > > pcb windows and arranges the on the fly, overriding whatever pcb > > says. PCB windows are automatically arranged in the way I like them, > > no matter how big my screen is. This probably won't work for most > > users because they use less capable window managers and/or spend less > > time configuring it. > > This is a way too complex. > > > 2. Save it as an user configuration (~/.pcb-rnd/); > > this is good as long as you are running only one instance of pcb. > > When you start running two in parallel, and chose different window > > sizes, they will overwrite eachother's settings so it's random which > > one wins (e.g. the one you closed last will overwrite window geometry > > last). I think this is how the gtk hid does it these days, but I am > > not 100% sure. > > I think this is the one I prefer. I work on one layout at a time, but yes= , > sometimes I open two pcbs. I'd make some sort of locking mechanism; the > first instance had the ability to write window geometry to a file. > > > 3. Save it as a per-design configuration; it's much less likely that > > the same user on the same system opens the same design twice and if > > he does, his save operations will fight anyway; however, editing the > > same design on multiple screens (or multiple systems, by multiple > > users!) makes it pretty wrong to save this setting in the design. > > Having some local settings stored in an unversioned config file next > > to the .pcb file solves some of the problems, but not all (e.g. same > > user, same system, screen size changes) > > Makes no sense to me. Per-design stuff must be under revision control. If > it > is it would turn out hard to fight it when I check out my design on my > laptop, which has different screen size. > > > 4. make it an "explicit save" thing so it doesn't try to save it > > automatically, it makes a snapshot only when you explicitly click a > > button. Window geometry is saved in ~/.pcb-rnd/ (user config). So if > > you know you are going to use a given screen size for the next period > > of time, you rearrange your windows, save the arrangement then if you > > start new pcb instances they start with this saved setting. > > Think about the lazy guys... I'd never push that button. > > > NOTE: I am not proposing any change to pcb or gschem or geda/gaf. > > > > Regards, > > > > Igor2 > > > -- > 73 de HA5OGL > Op.: Levente > --001a113d0c8633ceb705353d3772 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

It's not better to save window geometry scale (0-100% on= width and 0-100% on height)instead of px x px? Easier to resizing a window= on different screen sizes.


wt., 14 cze 2016, 13:44 u= =C5=BCytkownik Kovacs Levente (lev= entelist AT gmail DOT com) [via geda-= user AT delorie DOT com] <geda-use= r AT delorie DOT com> napisa=C5=82:
On Tue, 14 Jun 2016 07:58:14 +0200 (CEST)
gedau AT igor2 DOT repo DOT h= u wrote:

> Hi all!
>
> I've arrived at the gtk hid's "window width/height save/r= estore" code
> in my conf-rewrite in pcb-rnd. Long story short: the gtk hid tries to<= br> > remember window geometry and tries to restore it to the last known
> state (?) when pcb is started.
>
> Thinking it over, I am not sure this is a good idea (while I totally > see why many users probably want it).
>
> I am interested in your input, as an user of GUI apps in general (I > don't think this is pcb-specific) about how this is best done.
> Conceptually the question is, assuming pcb-rnd needs to save/restore > window sizes, whose property window sizes is? The program's? The > user's? The desing's? The session's? This gets tricky espe= cially in
> corner cases like laptops with variable screen sizes (large external > screen when docked and small screen on the road).
>
> Please comment on the following options, or add extra options if you > see any:
>
> 1. Do not try to save window geometry, let the window manager do its > job. This is how I do it: my wm runs an awk script that regex-matches<= br> > pcb windows and arranges the on the fly, overriding whatever pcb
> says. PCB windows are automatically arranged in the way I like them, > no matter how big my screen is. This probably won't work for most<= br> > users because they use less capable window managers and/or spend less<= br> > time configuring it.

This is a way too complex.

> 2. Save it as an user configuration (~/.pcb-rnd/);
> this is good as long as you are running only one instance of pcb.
> When you start running two in parallel, and chose different window
> sizes, they will overwrite eachother's settings so it's random= which
> one wins (e.g. the one you closed last will overwrite window geometry<= br> > last). I think this is how the gtk hid does it these days, but I am > not 100% sure.

I think this is the one I prefer. I work on one layout at a time, but yes,<= br> sometimes I open two pcbs. I'd make some sort of locking mechanism; the=
first instance had the ability to write window geometry to a file.

> 3. Save it as a per-design configuration; it's much less likely th= at
> the same user on the same system opens the same design twice and if > he does, his save operations will fight anyway; however, editing the > same design on multiple screens (or multiple systems, by multiple
> users!) makes it pretty wrong to save this setting in the design.
> Having some local settings stored in an unversioned config file next > to the .pcb file solves some of the problems, but not all (e.g. same > user, same system, screen size changes)

Makes no sense to me. Per-design stuff must be under revision control. If i= t
is it would turn out hard to fight it when I check out my design on my
laptop, which has different screen size.

> 4. make it an "explicit save" thing so it doesn't try to= save it
> automatically, it makes a snapshot only when you explicitly click a > button. Window geometry is saved in ~/.pcb-rnd/ (user config). So if > you know you are going to use a given screen size for the next period<= br> > of time, you rearrange your windows, save the arrangement then if you<= br> > start new pcb instances they start with this saved setting.

Think about the lazy guys... I'd never push that button.

> NOTE: I am not proposing any change to pcb or gschem or geda/gaf.
>
> Regards,
>
> Igor2


--
73 de HA5OGL
Op.: Levente
--001a113d0c8633ceb705353d3772--