View Issue Details

IDProjectCategoryView StatusLast Update
0034698LazarusWidgetsetpublic2019-01-18 16:52
ReporterCyril LAMYAssigned ToZeljan Rikalo 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
PlatformiMac 27-inch, Late 2013 OSOSXOS VersionSierra
Product Version2.0RC2Product Build 
Target VersionFixed in Version 
Summary0034698: Wrong Form position if set to poMainFormCenter
DescriptionUsing Qt5 :
If a form that have WindowState set to wsMaximized is calling a second form that has position set to poMainFormCenter, the second form isn't centered into the first form.

If changing Widgetset to cocoa and running the same program, the second form is centered into the first form.

If using QT5 and setting the first form windowState to wsNormal and setting width and height manually to the maximum screen size, the second form will be centered into the first. The problem occurs only when the first form windowstate is set to wsMaximized.
Steps To ReproduceCreate a new project.
Set Form1 WindowState to wsMaximized .
Create a new form (Form2).
Set Form2 position to poMainFormCenter.
On form1, create a button that make a form2.showmodal when clicked on it.
Additional InformationMy screen resolution is 2560x1440.
TagsNo tags attached.
Fixed in Revision59893
LazTarget-
WidgetsetQT5
Attached Files

Relationships

related to 0034880 closedZeljan Rikalo With QT5, Widgets are at wrong positions the second time the form is shown 

Activities

Zeljan Rikalo

2018-12-13 17:19

developer   ~0112539

Please attach example project

Cyril LAMY

2018-12-13 20:48

reporter  

Bug MainFormCenter.zip (707,049 bytes)

Cyril LAMY

2018-12-13 20:48

reporter  

ok-with_carbon.png (312,250 bytes)

Cyril LAMY

2018-12-13 20:49

reporter  

not-with_qt5.png (332,287 bytes)

Cyril LAMY

2018-12-13 20:52

reporter   ~0112549

Example project attached.

I've also uploaded 2 screenshots of this project. First is ok with carbon. In the second screenshot, with qt5, you can see that the form2 isn't centered with form1 (you can also see there is a problem with anchors of button on form1).

Zeljan Rikalo

2018-12-14 18:18

developer   ~0112570

Something is wrong with maximize, seem that it does not send resize event...

Zeljan Rikalo

2018-12-22 12:23

developer   ~0112809

Please test and close if ok.

Cyril LAMY

2018-12-23 20:40

reporter   ~0112839

Yes it's good now
Thank you

Issue History

Date Modified Username Field Change
2018-12-13 09:28 Cyril LAMY New Issue
2018-12-13 17:19 Zeljan Rikalo Note Added: 0112539
2018-12-13 18:02 Zeljan Rikalo Assigned To => Zeljan Rikalo
2018-12-13 18:02 Zeljan Rikalo Status new => assigned
2018-12-13 20:48 Cyril LAMY File Added: Bug MainFormCenter.zip
2018-12-13 20:48 Cyril LAMY File Added: ok-with_carbon.png
2018-12-13 20:49 Cyril LAMY File Added: not-with_qt5.png
2018-12-13 20:52 Cyril LAMY Note Added: 0112549
2018-12-14 18:18 Zeljan Rikalo LazTarget => -
2018-12-14 18:18 Zeljan Rikalo Note Added: 0112570
2018-12-14 18:18 Zeljan Rikalo Status assigned => confirmed
2018-12-22 12:23 Zeljan Rikalo Fixed in Revision => 59893
2018-12-22 12:23 Zeljan Rikalo Note Added: 0112809
2018-12-22 12:23 Zeljan Rikalo Status confirmed => resolved
2018-12-22 12:23 Zeljan Rikalo Resolution open => fixed
2018-12-23 20:40 Cyril LAMY Note Added: 0112839
2018-12-23 20:41 Cyril LAMY Status resolved => closed
2019-01-18 16:52 Zeljan Rikalo Relationship added related to 0034880