SetLayout() giving static values
SetLayout() giving static values
In the last time there were some changes regarding XY's reaction on screen changes. But my problem still exists:
I use SetLayout() to get info, especially for Pane1Width and Pane2Width. Basically it works well.
But: if I change the width of XY's screen, be it by draging the right edge to the left or right, or by moving XY to another -bigger- screen to fullscreen mode, so that the width of pane2 changes, the value of especially Pane2Width doesn't change at all!
I think/hope this can be called a
Oh - just found some more info: if I drag the splitter right or left, the values of Pane1/2Width do change.
And: if I first change the width of XY, and then once drag the splitter, both pane widths change to the corrected sizes
I use SetLayout() to get info, especially for Pane1Width and Pane2Width. Basically it works well.
But: if I change the width of XY's screen, be it by draging the right edge to the left or right, or by moving XY to another -bigger- screen to fullscreen mode, so that the width of pane2 changes, the value of especially Pane2Width doesn't change at all!
I think/hope this can be called a
Oh - just found some more info: if I drag the splitter right or left, the values of Pane1/2Width do change.
And: if I first change the width of XY, and then once drag the splitter, both pane widths change to the corrected sizes
Win11 Pro 223H2 Gerrman
-
- Site Admin
- Posts: 60595
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: SetLayout() giving static values
Well, these are internally used values that get updated when needed. I'm not sure why I exposed them. I think I should remove them from this command.
FAQ | XY News RSS | XY Twitter
Re: SetLayout() giving static values
Hm - I had expected that this command serves to expose the values it returns.
But OK: I need these values to "swap" (i.e.exchange) the sizes - be it horizontal or vertical - between pane1 and pane2. (So in the moment I read and then set them by SetLayout() ). Is there any other chance to do so? (With real/updated values, of course.)
But OK: I need these values to "swap" (i.e.exchange) the sizes - be it horizontal or vertical - between pane1 and pane2. (So in the moment I read and then set them by SetLayout() ). Is there any other chance to do so? (With real/updated values, of course.)
Win11 Pro 223H2 Gerrman
-
- Site Admin
- Posts: 60595
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: SetLayout() giving static values
Not at the moment, sorry. When I find the time I will remove these values from SetLayout. They don't belong there.
Well, that said, I tried something anyway. No mention in change log. Next beta... (v19.60.0008)
Well, that said, I tried something anyway. No mention in change log. Next beta... (v19.60.0008)
FAQ | XY News RSS | XY Twitter
Re: SetLayout() giving static values
Hey - at least for the situations I need & have tested it works now!
...but only, if you will not delete it
...but only, if you will not delete it
Win11 Pro 223H2 Gerrman
Re: SetLayout() giving static values
Thanks a lot!
By the way: still no idea how to get, (modify and then) set width and/or hight of panes by other means...
By the way: still no idea how to get, (modify and then) set width and/or hight of panes by other means...
Win11 Pro 223H2 Gerrman
Re: SetLayout() giving static values
OK: that would be "manual automation"
Something like Chaplin's "modern times". (I think that was the name, wasn't it?)
Something like Chaplin's "modern times". (I think that was the name, wasn't it?)
Win11 Pro 223H2 Gerrman
-
- Site Admin
- Posts: 60595
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: SetLayout() giving static values
I saw it coming... had to remove this "fix". These values are not usable for the user. I will remove them from SetLayout().
FAQ | XY News RSS | XY Twitter
Re: SetLayout() giving static values
WWait wait wait!
remove them from the returned layout string, okay, but please let them be definable with setlayout('Pane#Height/Width');
remove them from the returned layout string, okay, but please let them be definable with setlayout('Pane#Height/Width');
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]
[ this user is asleep ]
-
- Site Admin
- Posts: 60595
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: SetLayout() giving static values
I should have said: I should remove them from SetLayout().
I won't do anything now. It's an expert function anyway, so this might as well be solvable in the docs...
I won't do anything now. It's an expert function anyway, so this might as well be solvable in the docs...
FAQ | XY News RSS | XY Twitter
Re: SetLayout() giving static values
Will that mean there will be no way to get (and maybe also to set) these values?
While it wouldn't help much to set them, if I can't get them.
It would affect scripts! At least mine...
(I've used the partly wrong values for several years now...)
OK: if there would be any other solution to get and set pane widths and heights
While it wouldn't help much to set them, if I can't get them.
It would affect scripts! At least mine...
(I've used the partly wrong values for several years now...)
OK: if there would be any other solution to get and set pane widths and heights
Win11 Pro 223H2 Gerrman
Re: SetLayout() giving static values
ok, if I understood Don's comment right, he's just going to revert the "fix", so setlayout() might return out-of-date values, but you can still set the height/widths with it.
As for getting the values, use controlposition():
As for getting the values, use controlposition():
Code: Select all
gettoken(controlposition('L 1'), 4, '|'); // pane 1 height
gettoken(controlposition('L 2'), 3, '|'); // pane 2 width
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]
[ this user is asleep ]