from PySide2 import QtWidgets, QtCore, QtGui
class fileOpen(QtWidgets.QFileDialog):
def __init__(self):
super(fileOpen, self).__init__()
self.setWindowTitle("ATK Open File")
self.setObjectName('ATKOpenFile')
self.buildUI()
def buildUI(self):
btnLayout = QtWidgets.QHBoxLayout()
self.setLayout(btnLayout)
btn = QtWidgets.QPushButton('Click')
btnLayout.addWidget(btn)
def showUI():
ui = fileOpen()
ui.setWindowFlags(QtCore.Qt.WindowStaysOnTopHint)
ui.show()
return ui
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/1633c52d-e9ce-4b4c-b09b-d4298883baf4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/9baad844-e50d-4687-af71-e2aa0d26e8f7%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/cf6202ef-bff7-412a-ba4e-8ee25f5b4fc6%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/cf6202ef-bff7-412a-ba4e-8ee25f5b4fc6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/dc53b860-3b14-48dd-a269-91f2465ec2b6%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/a328373e-1fce-47f7-af52-5aee20328636%40googlegroups.com.
Oh sorry about that. I was reading it wrong multiple times :-)For me, your example mostly works as expected on linux under PySide 1.x. But the reject signal is still mapped to the QFileDialog so when you hit ESC, the QFileDialog disappears and leaves behind your button and main widget. On PySide 2.x however, it completely doesn't work and pops up two individual widgets. It seems in Qt5 the QFileDialog is doing some late layout at the time its actually shown, so the child layouts and widgets aren't available yet.
On Sat, Nov 17, 2018 at 3:41 AM Adam Baker <aj...@sympatico.ca> wrote:
Hey Justin,
I am using a QWidget.QDialog here. I named the class “MainWindow” so I think your getting it mixed up. Sorry for that should have been more clear with my class names.
Any other ideas why I’d have this problem on OSX ? Haven’t tested with Windows yet.
-Adam
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.
Ahah no worries. After all this info do you have any suggestions on how I can edit the QFileDialog and add the extra widgets in on the right hand side?
- Adam B.
On Friday, 16 November 2018 23:42:53 UTC-5, Justin Israel wrote:
Oh sorry about that. I was reading it wrong multiple times :-)For me, your example mostly works as expected on linux under PySide 1.x. But the reject signal is still mapped to the QFileDialog so when you hit ESC, the QFileDialog disappears and leaves behind your button and main widget. On PySide 2.x however, it completely doesn't work and pops up two individual widgets. It seems in Qt5 the QFileDialog is doing some late layout at the time its actually shown, so the child layouts and widgets aren't available yet.
On Sat, Nov 17, 2018 at 3:41 AM Adam Baker <aj...@sympatico.ca> wrote:
Hey Justin,
I am using a QWidget.QDialog here. I named the class “MainWindow” so I think your getting it mixed up. Sorry for that should have been more clear with my class names.
Any other ideas why I’d have this problem on OSX ? Haven’t tested with Windows yet.
-Adam
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/a328373e-1fce-47f7-af52-5aee20328636%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/a56eda2e-f966-423e-a50c-3a1136a737a1%40googlegroups.com.