0

I have an application that is suppose to run in full screen and not allow the user to minimize or exit with the use of the minimize and exit buttons that usually appear on the corner of the window. Essentially the title bar or whatever it is called is not visible.

I'm trying to make a test where squish checks whether the exit/minimize buttons can be pressed or is visible. Is there a way to do this?

When I try to use Spy or record function all I get is the window commands for minimize/exit a window but no clickbutton or a way to verify the visibility of the buttons.

Thanks!

4
  • Can QWidget::isFullScreen() solve your problem? Commented Dec 6, 2013 at 0:50
  • Sorry if I wasn't clear. I did use that to get fullscreen and have no problems with my application being in fullscreen. I'm trying to make a squish test case to verify that the exit and minimize buttons do not appear as its part of the requirements. Or a test to verify the application is in fullscreen mode. Commented Dec 6, 2013 at 16:06
  • isFullScreen() is a test to verify fullscreen mode. Commented Dec 6, 2013 at 23:58
  • Ok. So how do I add this to my test case or make a verification point with it? Commented Dec 9, 2013 at 16:21

1 Answer 1

2

I asked squish tech support and they recommended using the qt window flags such as:

def logWindowFlags(flags):
  test.log("Qt::WindowMinimizeButtonHint = %s" % flags.testFlag(Qt.WindowMinimizeButtonHint))
  test.log("Qt::WindowMaximizeButtonHint = %s" % flags.testFlag(Qt.WindowMaximizeButtonHint))
  test.log("Qt::WindowCloseButtonHint = %s" % flags.testFlag(Qt.WindowCloseButtonHint))
  test.log("Qt::WindowOkButtonHint = %s" % flags.testFlag(Qt.WindowOkButtonHint))
def main:
  logWindowFlags(widgetObject.windowFlags())
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.