Message 1 of 6
I want to display text on the model panel without using mel's headsUpDisplay.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
try:
from PySide6.QtWidgets import QLabel, QWidget
from shiboken6 import wrapInstance
except:
from PySide2.QtWidgets import QLabel, QWidget
from shiboken2 import wrapInstance
from maya import OpenMayaUI
ptr = OpenMayaUI.M3dView.active3dView().widget()
view = wrapInstance(int(ptr), QWidget)
label = QLabel("TEST")
label.setParent(view)
label.show()
Text does not update properly. (Press and release the space key to update)
Is there any good way to update the text? Or another way?
Resolved.
I forgot the show.