View Issue Details

IDProjectCategoryView StatusLast Update
0027922CommunityOCCT:Samplespublic2020-12-02 17:11
Reporterhpmachining Assigned Toabv 
PrioritynormalSeverityminor 
Status closedResolutionfixed 
OSLinux  
Product Version7.0.0 
Target Version7.5.0Fixed in Version7.5.0 
Summary0027922: Samples - Qt sample document window display problem
DescriptionPlease see this thread in the user forum for more details and a link to a video demonstrating the problem:
https://www.opencascade.com/content/qt-bottle-tutorial-linux-display-issue

If the Qt Bottle Tutorial or Import / Export samples are built on Linux, there is a problem with the display in the document window when it is resized with the mouse. After resizing, the display will continuously shrink. Maximizing the document window will restore the display to normal.

The problem appears to be inside OcctWindow. Another user replied on the thread I linked with more information.

Steps To Reproduce1) Build and run the Bottle sample using the provided scripts.
2) Create a new window and create the bottle.
3) Resize the document window by dragging the corner. Note: Not the main window, unless the document window is mazimized to the main window.
Additional information
and documentation updates
This problem does not occur in Windows, just Linux.
TagsNo tags attached.
Test case numberNot required

Relationships

related to 0026603 closedbugmaster Community Problem with maximization and normalization document windows in Qt samples with Qt 5.x 
related to 0031815 closedbugmaster Open CASCADE Visualization, TKOpenGl - avoid XResizeWindow() within OpenGl_Window::Resize() 

Activities

BenjaminBihler

2017-01-17 18:51

developer   ~0062711

Upvoting! I have the same issue and according to the original post we are not the only ones. When looking at the stacktrace there is a long chain of Qt methods related to showing a window that seem to call each other:

... and so on
QWidgetPrivate::showChildren()
QWidgetPrivate::show_helper()
QWidget::setVisible()
QWidget::show()
QWidgetPrivate::showChildren()
QWidgetPrivate::show_helper()
QWidget::setVisible()
QWidget::showMaximized()
some class calling showMaximized() of the application main window
main()

Would you have a look at it?

bugmaster

2020-09-30 15:47

administrator   ~0095498

Problem can be reproduced with new Qt Overview sample from branch CR31570_1.

I checked through VNC and locally on Debian 8,10

Qt Overview sample is not functional at all

The other QT samples (OCCT and Products) are not functional after display resizing

git

2020-10-01 14:39

administrator   ~0095525

Branch CR27922 has been created by inv.

SHA-1: 116916b5b98a21a1ea204f3f29b709b518f6d208


Detailed log of new commits:

Author: bugmaster
Date: Thu Oct 1 14:42:10 2020 +0300

    0027922: Samples - Qt sample document window display problem

vsv

2020-10-01 15:19

developer   ~0095528

Last edited: 2020-10-01 15:22

The problem of Qt samples that all successors of Aspect_Window class (usually it is OcctWindow) have a one common mistake: Method Size is redefined as following:
void OcctWindow::Size(Standard_Integer& theWidth, Standard_Integer& theHeight) const
{
  QRect aRect = myWidget->rect();
  theWidth = aRect.right();
  theHeight = aRect.bottom();
}

This is a wrong definition which causes the bug. Right definition must be:
void OcctWindow::Size(Standard_Integer& theWidth, Standard_Integer& theHeight) const
{
  QRect aRect = myWidget->rect();
  theWidth = aRect.width();
  theHeight = aRect.height();
}
it works well.

bugmaster

2020-10-01 15:39

administrator   ~0095532

Last edited: 2020-10-01 15:40

Vitaly,

I recompiled QT samples for OCCT and Products. Problem is not reproduced

Please review

bugmaster

2020-10-03 14:02

administrator   ~0095622

Combination -
OCCT branch : IR-2020-10-02
master SHA - 6522304c17181a09fa831c040219d611dc44b94a
a206de37fbfa0bf71bd534ae47192bbec23b8522
Products branch : IR-2020-10-02 SHA - d9c364e1137eed3249e5a05befa860c708f243c0
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 18085.050000000083 / 18057.60000000009 [+0.15%]
Products
Total CPU difference: 12174.620000000117 / 12124.200000000114 [+0.42%]
Windows-64-VC14:
OCCT
Total CPU difference: 19713.125 / 19772.65625 [-0.30%]
Products
Total CPU difference: 13533.8125 / 13527.921875 [+0.04%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2020-10-03 14:38

administrator   ~0095648

Branch CR27922 has been deleted by inv.

SHA-1: 116916b5b98a21a1ea204f3f29b709b518f6d208

Related Changesets

occt: master 7e6da17b

2020-10-01 11:42:10

abv


Committer: abv Details Diff
0027922: Samples - Qt sample document window display problem Affected Issues
0027922
mod - samples/qt/Common/src/OcctWindow.cxx Diff File

Issue History

Date Modified Username Field Change
2016-09-29 20:05 hpmachining New Issue
2016-09-29 20:05 hpmachining Assigned To => bugmaster
2016-09-29 20:14 kgv Relationship added related to 0026603
2017-01-17 18:51 BenjaminBihler Note Added: 0062711
2017-08-23 11:30 apv Test case number => Not required
2020-09-30 14:45 kgv Summary Qt Samples Document Window Display Problem => Samples - Qt sample document window display problem
2020-09-30 15:47 bugmaster Note Added: 0095498
2020-09-30 15:47 bugmaster Assigned To bugmaster => vsv
2020-09-30 15:47 bugmaster Status new => assigned
2020-10-01 14:38 bugmaster Assigned To vsv => bugmaster
2020-10-01 14:39 git Note Added: 0095525
2020-10-01 14:46 bugmaster Target Version => 7.5.0
2020-10-01 14:46 bugmaster Relationship added related to 0031815
2020-10-01 15:19 vsv Note Added: 0095528
2020-10-01 15:22 vsv Note Edited: 0095528
2020-10-01 15:39 bugmaster Note Added: 0095532
2020-10-01 15:39 bugmaster Assigned To bugmaster => vsv
2020-10-01 15:39 bugmaster Status assigned => resolved
2020-10-01 15:40 bugmaster Note Edited: 0095532
2020-10-01 15:45 vsv Assigned To vsv => bugmaster
2020-10-01 15:45 vsv Status resolved => reviewed
2020-10-03 14:02 bugmaster Note Added: 0095622
2020-10-03 14:02 bugmaster Status reviewed => tested
2020-10-03 14:05 abv Changeset attached => occt master 7e6da17b
2020-10-03 14:05 abv Assigned To bugmaster => abv
2020-10-03 14:05 abv Status tested => verified
2020-10-03 14:05 abv Resolution open => fixed
2020-10-03 14:38 git Note Added: 0095648
2020-12-02 16:40 emo Fixed in Version => 7.5.0
2020-12-02 17:11 emo Status verified => closed