PB540 #PB_Ignore places windows always at 0,0 GTK3

Linux specific forum
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by ts-soft »

Code: Select all

OpenWindow(0, #PB_Ignore, #PB_Ignore, 640, 480, "")
Repeat : Until  WaitWindowEvent() = #PB_Event_CloseWindow
regards
Thomas
Last edited by ts-soft on Tue Nov 24, 2015 7:16 pm, edited 1 time in total.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: [PB540] #PB_Ignore places windows always at 0,0 GTK3

Post by Fred »

Fixed.
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: [Done] PB540 #PB_Ignore places windows always at 0,0 GTK

Post by ts-soft »

It's changed, but not fixed.

The window is always screencentered and not overlapped windows!
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by Fred »

Linux doesn't have a "remember from last time" window position, so it's always centered. What did you expect exactly ?
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by ts-soft »

If i open some windows (SDI Single Document Interface), the should overlapped and not one over the other, like
#CW_USEDEFAULT on windows.
Linux doesn't have a "remember from last time" window position
That was not useful for that.
MSDN wrote:If this parameter is set to CW_USEDEFAULT, the system selects the default position for the window's upper-left corner and ignores the y parameter.
This is required (for Linux)!

and i am sure, this has worked in earlier versions of pb.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by Fred »

If you can confirm it worked before as expected on GTK3, I will take a closer look
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by ts-soft »

I can't confirm, it worked with GTK3, i have never tested with GTK3.

I think, the "GTK_WIN_POS_NONE" constant is the same as "CW_USEDEFAULT" on windows???
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by Fred »

Where is this documented ?
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by ts-soft »

PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB540 #PB_Ignore places windows always at 0,0 GTK3

Post by Fred »

I beleive than using this flag will place the window exactly at the coordinate you defined (should be the default flag). It doesn't seems like the Windows behaviour.
Post Reply