mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 00:44:52 +01:00
change popup text to popup icon
This commit is contained in:
parent
3b53093d12
commit
6e21bc4779
2 changed files with 24 additions and 3 deletions
BIN
client/ayon_core/resources/images/popout.png
Normal file
BIN
client/ayon_core/resources/images/popout.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.1 KiB |
|
|
@ -1,7 +1,13 @@
|
||||||
from math import ceil
|
from math import ceil
|
||||||
from qtpy import QtWidgets, QtCore, QtGui
|
from qtpy import QtWidgets, QtCore, QtGui
|
||||||
|
|
||||||
from ayon_core.tools.utils import NiceCheckbox
|
from ayon_core.tools.utils import (
|
||||||
|
NiceCheckbox,
|
||||||
|
IconButton,
|
||||||
|
paint_image_with_color,
|
||||||
|
)
|
||||||
|
from ayon_core.resources import get_image_path
|
||||||
|
from ayon_core.style import get_objected_colors
|
||||||
|
|
||||||
# from ayon_core.tools.utils import DeselectableTreeView
|
# from ayon_core.tools.utils import DeselectableTreeView
|
||||||
from .constants import (
|
from .constants import (
|
||||||
|
|
@ -410,12 +416,27 @@ class PublishReportViewerWidget(QtWidgets.QFrame):
|
||||||
|
|
||||||
details_widget = QtWidgets.QWidget(self)
|
details_widget = QtWidgets.QWidget(self)
|
||||||
details_tab_widget = QtWidgets.QTabWidget(details_widget)
|
details_tab_widget = QtWidgets.QTabWidget(details_widget)
|
||||||
details_popup_btn = QtWidgets.QPushButton("PopUp", details_widget)
|
|
||||||
|
btns_widget = QtWidgets.QWidget(details_widget)
|
||||||
|
|
||||||
|
popout_image = QtGui.QImage(get_image_path("popout.png"))
|
||||||
|
popout_color = get_objected_colors("font")
|
||||||
|
popout_icon = QtGui.QIcon(
|
||||||
|
paint_image_with_color(popout_image, popout_color.get_qcolor())
|
||||||
|
)
|
||||||
|
details_popup_btn = IconButton(btns_widget)
|
||||||
|
details_popup_btn.setIcon(popout_icon)
|
||||||
|
details_popup_btn.setToolTip("Pop Out")
|
||||||
|
|
||||||
|
btns_layout = QtWidgets.QHBoxLayout(btns_widget)
|
||||||
|
btns_layout.setContentsMargins(0, 0, 0, 0)
|
||||||
|
btns_layout.addStretch(1)
|
||||||
|
btns_layout.addWidget(details_popup_btn, 0)
|
||||||
|
|
||||||
details_layout = QtWidgets.QVBoxLayout(details_widget)
|
details_layout = QtWidgets.QVBoxLayout(details_widget)
|
||||||
details_layout.setContentsMargins(0, 0, 0, 0)
|
details_layout.setContentsMargins(0, 0, 0, 0)
|
||||||
details_layout.addWidget(details_tab_widget, 1)
|
details_layout.addWidget(details_tab_widget, 1)
|
||||||
details_layout.addWidget(details_popup_btn, 0)
|
details_layout.addWidget(btns_widget, 0)
|
||||||
|
|
||||||
details_popup = DetailsPopup(self, details_tab_widget)
|
details_popup = DetailsPopup(self, details_tab_widget)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue