Skip to content

Commit 55230c8

Browse files
[cuegui] Expand job user colors and add a custom RGB option (#1859)
Expand job user colors (right click job > Set user color) and add a custom RGB option popup. - Increased predefined color options from 4 to 15 with descriptive names - Added custom color picker dialog with RGB input (0-255 range) - Included live preview in custom color dialog - Updated menu items to show color names (e.g., "Set Color 1 - Dark Blue") - New colors include: Purple, Teal, Orange, Maroon, Forest Green, Lavender, Crimson, Navy, Olive, Plum, and Slate - Custom colors persist across sessions using existing storage mechanism This enhancement provides better visual organization for complex rendering workflows with many concurrent jobs **Link the Issue(s) this Pull Request is related to.** - #1858 - #1800
1 parent 38e6d7b commit 55230c8

File tree

7 files changed

+241
-8
lines changed

7 files changed

+241
-8
lines changed

cuegui/cuegui/Constants.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,17 @@ def __get_version_from_cmd(command):
185185
COLOR_USER_2 = QtGui.QColor(*__bg_colors[1])
186186
COLOR_USER_3 = QtGui.QColor(*__bg_colors[2])
187187
COLOR_USER_4 = QtGui.QColor(*__bg_colors[3])
188+
COLOR_USER_5 = QtGui.QColor(*__bg_colors[4])
189+
COLOR_USER_6 = QtGui.QColor(*__bg_colors[5])
190+
COLOR_USER_7 = QtGui.QColor(*__bg_colors[6])
191+
COLOR_USER_8 = QtGui.QColor(*__bg_colors[7])
192+
COLOR_USER_9 = QtGui.QColor(*__bg_colors[8])
193+
COLOR_USER_10 = QtGui.QColor(*__bg_colors[9])
194+
COLOR_USER_11 = QtGui.QColor(*__bg_colors[10])
195+
COLOR_USER_12 = QtGui.QColor(*__bg_colors[11])
196+
COLOR_USER_13 = QtGui.QColor(*__bg_colors[12])
197+
COLOR_USER_14 = QtGui.QColor(*__bg_colors[13])
198+
COLOR_USER_15 = QtGui.QColor(*__bg_colors[14])
188199

189200
__frame_colors = __config.get('style.colors.frame_state')
190201
RGB_FRAME_STATE = {

cuegui/cuegui/JobMonitorTree.py

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -513,6 +513,20 @@ def contextMenuEvent(self, e):
513513
self.__menuActions.jobs().addAction(color_menu, "setUserColor2")
514514
self.__menuActions.jobs().addAction(color_menu, "setUserColor3")
515515
self.__menuActions.jobs().addAction(color_menu, "setUserColor4")
516+
self.__menuActions.jobs().addAction(color_menu, "setUserColor5")
517+
self.__menuActions.jobs().addAction(color_menu, "setUserColor6")
518+
self.__menuActions.jobs().addAction(color_menu, "setUserColor7")
519+
self.__menuActions.jobs().addAction(color_menu, "setUserColor8")
520+
self.__menuActions.jobs().addAction(color_menu, "setUserColor9")
521+
self.__menuActions.jobs().addAction(color_menu, "setUserColor10")
522+
self.__menuActions.jobs().addAction(color_menu, "setUserColor11")
523+
self.__menuActions.jobs().addAction(color_menu, "setUserColor12")
524+
self.__menuActions.jobs().addAction(color_menu, "setUserColor13")
525+
self.__menuActions.jobs().addAction(color_menu, "setUserColor14")
526+
self.__menuActions.jobs().addAction(color_menu, "setUserColor15")
527+
color_menu.addSeparator()
528+
self.__menuActions.jobs().addAction(color_menu, "setUserCustomColor")
529+
color_menu.addSeparator()
516530
self.__menuActions.jobs().addAction(color_menu, "clearUserColor")
517531
menu.addMenu(color_menu)
518532

@@ -586,6 +600,62 @@ def actionSetUserColor(self, color):
586600
self.__userColors[objectKey] = color
587601
item.setUserColor(color)
588602

603+
def actionSetUserCustomColor(self):
604+
"""Opens a dialog to set a custom RGB color for selected items"""
605+
dialog = QtWidgets.QDialog(self)
606+
dialog.setWindowTitle("Set Custom Color (RGB)")
607+
dialog.setModal(True)
608+
609+
layout = QtWidgets.QFormLayout()
610+
611+
# Create spinboxes for RGB values
612+
r_spinbox = QtWidgets.QSpinBox()
613+
r_spinbox.setRange(0, 255)
614+
r_spinbox.setValue(100)
615+
616+
g_spinbox = QtWidgets.QSpinBox()
617+
g_spinbox.setRange(0, 255)
618+
g_spinbox.setValue(100)
619+
620+
b_spinbox = QtWidgets.QSpinBox()
621+
b_spinbox.setRange(0, 255)
622+
b_spinbox.setValue(100)
623+
624+
# Color preview label
625+
preview_label = QtWidgets.QLabel()
626+
preview_label.setMinimumSize(200, 50)
627+
preview_label.setFrameStyle(QtWidgets.QFrame.Box)
628+
preview_label.setStyleSheet("background-color: rgb(100, 100, 100);")
629+
630+
def update_preview():
631+
r = r_spinbox.value()
632+
g = g_spinbox.value()
633+
b = b_spinbox.value()
634+
preview_label.setStyleSheet(f"background-color: rgb({r}, {g}, {b});")
635+
636+
r_spinbox.valueChanged.connect(update_preview)
637+
g_spinbox.valueChanged.connect(update_preview)
638+
b_spinbox.valueChanged.connect(update_preview)
639+
640+
layout.addRow("Red (0-255):", r_spinbox)
641+
layout.addRow("Green (0-255):", g_spinbox)
642+
layout.addRow("Blue (0-255):", b_spinbox)
643+
layout.addRow("Preview:", preview_label)
644+
645+
# Buttons
646+
button_box = QtWidgets.QDialogButtonBox(
647+
QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel)
648+
button_box.accepted.connect(dialog.accept)
649+
button_box.rejected.connect(dialog.reject)
650+
layout.addRow(button_box)
651+
652+
dialog.setLayout(layout)
653+
654+
if dialog.exec_() == QtWidgets.QDialog.Accepted:
655+
# Create custom color from RGB values
656+
custom_color = QtGui.QColor(r_spinbox.value(), g_spinbox.value(), b_spinbox.value())
657+
self.actionSetUserColor(custom_color)
658+
589659
def actionEatSelectedItems(self):
590660
"""Eats all dead frames for selected jobs"""
591661
self.__menuActions.jobs().eatDead()

cuegui/cuegui/MenuActions.py

Lines changed: 83 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -762,29 +762,108 @@ def copyJobName(self, rpcObjects=None):
762762
" ".join(names), QtGui.QClipboard.Clipboard)
763763

764764
setUserColor1_info = [
765-
"Set Color 1", "Set user defined background color", cuegui.Constants.COLOR_USER_1]
765+
"Set Color 1 - Dark Blue", "Set user defined background color",
766+
cuegui.Constants.COLOR_USER_1]
766767

767768
def setUserColor1(self, rpcObjects=None):
768769
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_1)
769770

770771
setUserColor2_info = [
771-
"Set Color 2", "Set user defined background color", cuegui.Constants.COLOR_USER_2]
772+
"Set Color 2 - Dark Yellow", "Set user defined background color",
773+
cuegui.Constants.COLOR_USER_2]
772774

773775
def setUserColor2(self, rpcObjects=None):
774776
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_2)
775777

776778
setUserColor3_info = [
777-
"Set Color 3", "Set user defined background color", cuegui.Constants.COLOR_USER_3]
779+
"Set Color 3 - Dark Green", "Set user defined background color",
780+
cuegui.Constants.COLOR_USER_3]
778781

779782
def setUserColor3(self, rpcObjects=None):
780783
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_3)
781784

782785
setUserColor4_info = [
783-
"Set Color 4", "Set user defined background color", cuegui.Constants.COLOR_USER_4]
786+
"Set Color 4 - Dark Brown", "Set user defined background color",
787+
cuegui.Constants.COLOR_USER_4]
784788

785789
def setUserColor4(self, rpcObjects=None):
786790
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_4)
787791

792+
setUserColor5_info = [
793+
"Set Color 5 - Purple", "Set user defined background color", cuegui.Constants.COLOR_USER_5]
794+
795+
def setUserColor5(self, rpcObjects=None):
796+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_5)
797+
798+
setUserColor6_info = [
799+
"Set Color 6 - Teal", "Set user defined background color", cuegui.Constants.COLOR_USER_6]
800+
801+
def setUserColor6(self, rpcObjects=None):
802+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_6)
803+
804+
setUserColor7_info = [
805+
"Set Color 7 - Orange", "Set user defined background color", cuegui.Constants.COLOR_USER_7]
806+
807+
def setUserColor7(self, rpcObjects=None):
808+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_7)
809+
810+
setUserColor8_info = [
811+
"Set Color 8 - Maroon", "Set user defined background color", cuegui.Constants.COLOR_USER_8]
812+
813+
def setUserColor8(self, rpcObjects=None):
814+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_8)
815+
816+
setUserColor9_info = [
817+
"Set Color 9 - Forest Green", "Set user defined background color",
818+
cuegui.Constants.COLOR_USER_9]
819+
820+
def setUserColor9(self, rpcObjects=None):
821+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_9)
822+
823+
setUserColor10_info = [
824+
"Set Color 10 - Lavender", "Set user defined background color",
825+
cuegui.Constants.COLOR_USER_10]
826+
827+
def setUserColor10(self, rpcObjects=None):
828+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_10)
829+
830+
setUserColor11_info = [
831+
"Set Color 11 - Crimson", "Set user defined background color",
832+
cuegui.Constants.COLOR_USER_11]
833+
834+
def setUserColor11(self, rpcObjects=None):
835+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_11)
836+
837+
setUserColor12_info = [
838+
"Set Color 12 - Navy", "Set user defined background color", cuegui.Constants.COLOR_USER_12]
839+
840+
def setUserColor12(self, rpcObjects=None):
841+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_12)
842+
843+
setUserColor13_info = [
844+
"Set Color 13 - Olive", "Set user defined background color", cuegui.Constants.COLOR_USER_13]
845+
846+
def setUserColor13(self, rpcObjects=None):
847+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_13)
848+
849+
setUserColor14_info = [
850+
"Set Color 14 - Plum", "Set user defined background color", cuegui.Constants.COLOR_USER_14]
851+
852+
def setUserColor14(self, rpcObjects=None):
853+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_14)
854+
855+
setUserColor15_info = [
856+
"Set Color 15 - Slate", "Set user defined background color", cuegui.Constants.COLOR_USER_15]
857+
858+
def setUserColor15(self, rpcObjects=None):
859+
self._caller.actionSetUserColor(cuegui.Constants.COLOR_USER_15)
860+
861+
setUserCustomColor_info = [
862+
"Set Custom Color (RGB)...", "Set custom background color using RGB values", None]
863+
864+
def setUserCustomColor(self, rpcObjects=None):
865+
self._caller.actionSetUserCustomColor()
866+
788867
clearUserColor_info = ["Clear", "Clear user defined background color", None]
789868

790869
def clearUserColor(self, rpcObjects=None):

cuegui/cuegui/config/cuegui.yaml

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,21 @@ style.font.size: 10
5656
style.color_theme: 'plastique'
5757
# RGB values.
5858
style.colors.background: [
59-
[50, 50, 100],
60-
[100, 100, 50],
61-
[0, 50, 0],
62-
[50, 30, 0],
59+
[50, 50, 100], # Dark blue
60+
[100, 100, 50], # Dark yellow
61+
[0, 50, 0], # Dark green
62+
[50, 30, 0], # Dark brown
63+
[80, 0, 80], # Purple
64+
[0, 80, 80], # Teal
65+
[100, 50, 0], # Orange
66+
[70, 0, 35], # Maroon
67+
[0, 60, 30], # Forest green
68+
[90, 60, 90], # Lavender
69+
[100, 0, 50], # Crimson
70+
[0, 50, 100], # Navy
71+
[80, 80, 0], # Olive
72+
[60, 20, 60], # Plum
73+
[30, 70, 70], # Slate
6374
]
6475
style.colors.frame_state:
6576
DEAD: [255, 0, 0]

docs/_docs/user-guides/cuetopia-monitoring-guide.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ This guide provides comprehensive documentation for Cuetopia, which includes the
2020

2121
## Table of Contents
2222
1. [Monitor Jobs Plugin](#monitor-jobs-plugin)
23+
- [Job Color Organization](#job-color-organization)
2324
2. [Monitor Job Details Plugin](#monitor-job-details-plugin)
2425
3. [Job Graph Plugin](#job-graph-plugin)
2526
4. [Filters and Search Capabilities](#filters-and-search-capabilities)
@@ -132,6 +133,67 @@ Right-clicking on a job provides these actions:
132133
- Eat/retry frames
133134
- Add comments
134135
- Use local cores
136+
- Set user color (see [Job Color Organization](#job-color-organization))
137+
138+
### Job Color Organization
139+
140+
The Monitor Jobs view allows you to organize jobs visually by applying background colors. This feature is particularly useful when working with many concurrent renders, allowing you to group jobs by project, priority, department, or any other categorization scheme.
141+
142+
#### Setting Job Colors
143+
144+
To apply a color to one or more jobs:
145+
146+
1. **Select Jobs**: Click on a job or use Ctrl+click to select multiple jobs
147+
2. **Right-Click**: Open the context menu
148+
3. **Choose Color**: Navigate to "Set user color" submenu
149+
150+
![Set User Color Menu with 15 Options](/assets/images/cuegui/cuetopia/job_user_colors_set_user_color_with_15_color_options.png)
151+
152+
#### Available Color Options
153+
154+
The system provides **15 predefined colors** with descriptive names:
155+
156+
- **Set Color 1 - Dark Blue**
157+
- **Set Color 2 - Dark Yellow**
158+
- **Set Color 3 - Dark Green**
159+
- **Set Color 4 - Dark Brown**
160+
- **Set Color 5 - Purple**
161+
- **Set Color 6 - Teal**
162+
- **Set Color 7 - Orange**
163+
- **Set Color 8 - Maroon**
164+
- **Set Color 9 - Forest Green**
165+
- **Set Color 10 - Lavender**
166+
- **Set Color 11 - Crimson**
167+
- **Set Color 12 - Navy**
168+
- **Set Color 13 - Olive**
169+
- **Set Color 14 - Plum**
170+
- **Set Color 15 - Slate**
171+
172+
#### Custom Color Option
173+
174+
For complete flexibility, use the **"Set Custom Color (RGB)..."** option to create any color:
175+
176+
1. Select jobs and choose "Set Custom Color (RGB)..." from the menu
177+
2. Enter RGB values (0-255 range) using the spinboxes
178+
3. Preview the color in real-time as you adjust values
179+
4. Click OK to apply the custom color
180+
181+
![Custom Color Dialog](/assets/images/cuegui/cuetopia/job_user_colors_set_user_color_with_set_custom_color.png)
182+
183+
#### Color Management
184+
185+
- **Clear Colors**: Use "Clear" option to remove color assignments
186+
- **Persistent Colors**: Color assignments are saved and restored across CueGUI sessions
187+
- **Multiple Selection**: Apply colors to multiple jobs simultaneously
188+
- **Visual Organization**: Colors appear as background highlighting in the job list
189+
190+
#### Best Practices for Color Organization
191+
192+
- **Consistent Scheme**: Develop a facility-wide color coding standard
193+
- **Project-Based**: Use different colors for different shows or projects
194+
- **Priority-Based**: Use warmer colors (red, orange) for urgent jobs, cooler colors (blue, green) for routine work
195+
- **Department-Based**: Assign colors by department (lighting, compositing, effects)
196+
- **Status-Based**: Use colors to indicate job status or approval stages
135197

136198
---
137199

597 KB
Loading
537 KB
Loading

0 commit comments

Comments
 (0)