Regression: Themes: Highlight color in the text menus #112122

Closed
opened 2023-09-08 08:44:08 +02:00 by Arunderan · 8 comments

System Information
Operating system: Windows-10-10.0.19045-SP0 64 Bits
Graphics card: NVIDIA GeForce RTX 3060 Ti/PCIe/SSE2 NVIDIA Corporation 4.6.0 NVIDIA 536.23

Blender Version
Broken: version: 4.0.0 Alpha, branch: main, commit date: 2023-09-03 15:22, hash: 30de3d7c1a79
Worked: 3.6.2

Short description of error
The highlight color is not longer adjustable by the Selected color in the User Interface / Menu Item panel. But changes with the Inner color. This breaks theming.

Exact steps for others to reproduce the error

  • Enter Preferences.
  • Navigage to Themes tab, User Interface, Menu Item panel.
  • Play around with the Selected and Inner color
**System Information** Operating system: Windows-10-10.0.19045-SP0 64 Bits Graphics card: NVIDIA GeForce RTX 3060 Ti/PCIe/SSE2 NVIDIA Corporation 4.6.0 NVIDIA 536.23 **Blender Version** Broken: version: 4.0.0 Alpha, branch: main, commit date: 2023-09-03 15:22, hash: `30de3d7c1a79` Worked: 3.6.2 **Short description of error** The highlight color is not longer adjustable by the Selected color in the User Interface / Menu Item panel. But changes with the Inner color. This breaks theming. **Exact steps for others to reproduce the error** - Enter Preferences. - Navigage to Themes tab, User Interface, Menu Item panel. - Play around with the Selected and Inner color
Arunderan added the
Type
Report
Priority
Normal
Status
Needs Triage
labels 2023-09-08 08:44:09 +02:00
Member

Thanks for the report. I can confirm. We'd need to tweak the preference labels and properties here.
I'll check.

Thanks for the report. I can confirm. We'd need to tweak the preference labels and properties here. I'll check.
Pratik Borhade added
Module
User Interface
Status
Confirmed
and removed
Status
Needs Triage
labels 2023-09-08 11:18:38 +02:00
Member

AFAICT this is working as expected. inner property is used to fill the hovered/selected button
We could make this consistent with other widget types. For example: UILIST
So highlight color will be decided by the text color.

diff --git a/source/blender/editors/interface/interface_widgets.cc b/source/blender/editors/interface/interface_widgets.cc
index f412c113302..f92167e2a25 100644
--- a/source/blender/editors/interface/interface_widgets.cc
+++ b/source/blender/editors/interface/interface_widgets.cc
@@ -2744,9 +2744,9 @@ static void widget_state_menu_item(uiWidgetType *wt,
   }
   else if (state->but_flag & UI_ACTIVE) {
     /* Regular hover. */
-    color_blend_v3_v3(wt->wcol.inner, wt->wcol.text, 0.2f);
+    copy_v3_v3_uchar(wt->wcol.inner, wt->wcol.text);
     copy_v3_v3_uchar(wt->wcol.text, wt->wcol.text_sel);
-    wt->wcol.inner[3] = 255;
+    wt->wcol.inner[3] = 20;
     wt->wcol.text[3] = 255;
   }
 }

I doubt whether this will be classified as a bug. One proper fix will to add a member in uiWidgetColors struct, which can be used to decide hover color.
@Harley ^

AFAICT this is working as expected. `inner` property is used to fill the hovered/selected button We could make this consistent with other widget types. For example: UILIST So highlight color will be decided by the text color. ```Diff diff --git a/source/blender/editors/interface/interface_widgets.cc b/source/blender/editors/interface/interface_widgets.cc index f412c113302..f92167e2a25 100644 --- a/source/blender/editors/interface/interface_widgets.cc +++ b/source/blender/editors/interface/interface_widgets.cc @@ -2744,9 +2744,9 @@ static void widget_state_menu_item(uiWidgetType *wt, } else if (state->but_flag & UI_ACTIVE) { /* Regular hover. */ - color_blend_v3_v3(wt->wcol.inner, wt->wcol.text, 0.2f); + copy_v3_v3_uchar(wt->wcol.inner, wt->wcol.text); copy_v3_v3_uchar(wt->wcol.text, wt->wcol.text_sel); - wt->wcol.inner[3] = 255; + wt->wcol.inner[3] = 20; wt->wcol.text[3] = 255; } } ``` - - - I doubt whether this will be classified as a bug. One proper fix will to add a member in `uiWidgetColors` struct, which can be used to decide hover color. @Harley ^
Pratik Borhade added
Status
Needs Info from Developers
and removed
Status
Confirmed
labels 2023-09-08 12:48:39 +02:00
Iliya Katushenock changed title from Themes - Highlight color in the text menus regression to Regression: Themes: Highlight color in the text menus 2023-09-08 13:37:13 +02:00
Author

Well, it does influence the inactive color now, which it imo shouldn't. Inactive should be greyed out, not colored with the highlight color. And it works different from Blender 3.6.2, it breaks the old themes.

What is the Selected color now doing?

Well, it does influence the inactive color now, which it imo shouldn't. Inactive should be greyed out, not colored with the highlight color. And it works different from Blender 3.6.2, it breaks the old themes. What is the Selected color now doing?
Contributor

image

Can confirm from another user in Erindales discord server, using the highlight color for disabled menu entries does indeed cause a conflicting UX. Should be a different prop that isn't the highlight colour.

![image](/attachments/5a5adf6e-931d-4a8e-8537-88806ec8cfe3) Can confirm from another user in Erindales discord server, using the highlight color for disabled menu entries does indeed cause a conflicting UX. Should be a different prop that isn't the highlight colour.

I was about to report it too. This just doesn't make sense.

Blender 4.0.1
imageimage

Blender 3.5
imageimage

I was about to report it too. This just doesn't make sense. **Blender 4.0.1** ![image](/attachments/4f31973a-f58f-44fb-bc3a-396ef6b2faf0)![image](/attachments/c71f131d-3de6-4d7f-98f7-3bad0b103470) **Blender 3.5** ![image](/attachments/9b26d699-6e80-4c47-bf8a-072d4cd95535)![image](/attachments/af6965e2-4ecd-404e-8654-ab03fde604b7)
Pratik Borhade added
Status
Confirmed
and removed
Status
Needs Info from Developers
labels 2024-03-29 11:06:37 +01:00
Member

I don't think this is applicable to the latest Blender 4.2 alpha? Not sure what's broken, tried to replicate the image in the report description and it looks as expected.

inner color for menu item

  • Menu Item Inner -- Background color of the menu entry background
  • Menu Item Inner Selected -- Used when the menu entry is selected (for example the active editor in the editors dropdown)
I don't think this is applicable to the latest Blender 4.2 alpha? Not sure what's broken, tried to replicate the image in the report description and it looks as expected. ![inner color for menu item](/attachments/d3efc5b3-9928-4554-a9dd-2a3cd2c4713a) - Menu Item Inner -- Background color of the menu entry background - Menu Item Inner Selected -- Used when the menu entry is selected (for example the active editor in the editors dropdown)
222 KiB
Author

Yes, works as expected now. I guess there was a fix from another task then.

Yes, works as expected now. I guess there was a fix from another task then.
Member

Yes, works as expected now. I guess there was a fix from another task then.

Fixed by: !113082 / b5ebf31fb1

> Yes, works as expected now. I guess there was a fix from another task then. Fixed by: !113082 / b5ebf31fb114d3d43c11227eca9b1f3ded9f06f1
Blender Bot added
Status
Archived
and removed
Status
Confirmed
labels 2024-04-04 13:42:25 +02:00
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
5 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#112122
No description provided.