Created
October 12, 2012 13:20
-
-
Save yusukei/3879173 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import maya.OpenMayaUI | |
from PySide import QtGui | |
import shiboken | |
import maya.cmds as cmds | |
panel = cmds.getPanel(scriptType="scriptEditorPanel")[0] | |
widget = maya.OpenMayaUI.MQtUtil.findLayout(panel) | |
scriptEditor = shiboken.wrapInstance(long(widget), QtGui.QWidget) | |
mainWindow = shiboken.wrapInstance(long(maya.OpenMayaUI.MQtUtil.mainWindow()), QtGui.QWidget) | |
win = QtGui.QDockWidget('test', parent=mainWindow) | |
win.setWidget(scriptEditor) | |
win.setFloating(True) | |
win.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment