Page MenuHome

Theming colors and size of background (transparency) checkerboard pattern
Needs ReviewPublic

Authored by Michael Soluyanov (crantisz) on Sat, Feb 8, 9:51 PM.
Tokens
"Love" token, awarded by Thirio."Love" token, awarded by HooglyBoogly."Like" token, awarded by Fracture128."Love" token, awarded by Alumx."Love" token, awarded by amonpaike."Like" token, awarded by 1D_Inc."Like" token, awarded by blackward.

Details

Summary

This patch adds ability to set up colors and size of background (transparency) checkerboard pattern in viewport and 2d editors. No new backgrounds, only changing colors in existing ones.

This is not the background of the viewport, it is a transparency checkerboard that is turned on only in render mode, when the transparency mode is on. And also in 2D-editors, (image, sequencer, ets)

Some examples:

How it works:

Useful for bright themes:

Same in Krita:

Diff Detail

Event Timeline

Setting Pablo as reviewer since he is in charge of theme.

Hey @Michael Soluyanov (crantisz), I tried to contact you but it seems there is no direct message here, someone told me you're working on this patch so maybe you could merge this proposal which has already the code for it, it's just needs an update.
https://blender.community/c/rightclickselect/ymfbbc/

Hey @Michael Soluyanov (crantisz), I tried to contact you but it seems there is no direct message here, someone told me you're working on this patch so maybe you could merge this proposal which has already the code for it, it's just needs an update.
https://blender.community/c/rightclickselect/ymfbbc/

Hello, you do not understand a bit. This is not the background of the viewport, it is a transparency checkerboard that is turned on only in render mode, when the transparency mode is on. And also in 2D-editors, (image, sequencer, ets)

Brecht Van Lommel (brecht) requested changes to this revision.Tue, Feb 11, 12:20 PM

Avoid using different names and abbreviations in the user interface and implementation. Use either "transparent" or "alpha" for both.

release/scripts/startup/bl_ui/space_userpref.py
872

Capitalize checkerboard.

source/blender/blenloader/intern/versioning_userdef.c
187

When this is committed, it's best to bump the subversion immediately, since otherwise changes to this will be lost.

source/blender/draw/intern/shaders/common_globals_lib.glsl
73–74

I don't think this needs to be in GLSL, it doesn't seem to be read by any GLSL shader.

Is there somewhere else this can be stored?

source/blender/makesdna/DNA_userdef_types.h
179

Capitalize, remove empty line after comment.

182

Just use an int, no need to save space here.

source/blender/makesrna/intern/rna_userdef.c
1506

Capitalize color

1518

Capitalize size

This revision now requires changes to proceed.Tue, Feb 11, 12:20 PM

While this patch was on review, Checkerboard was moved from EEVEE to Overlays, so I keep it in GlobalsUboStorage: colors are already here, added size only. Text formatting fixed.

When this is committed, it's best to bump the subversion immediately, since otherwise changes to this will be lost.

So what is needed to do in this case? Make this in different way?

Avoid using different names and abbreviations in the user interface and implementation. Use either "transparent" or "alpha" for both.

Looks like "alpha" is already used in code... But for UX, better "transparent". For example, Krita uses "transparent" and "Transparency settings" in Photoshop

Michael Soluyanov (crantisz) marked 5 inline comments as done.Tue, Feb 11, 10:35 PM

Changed "alpha" to "transp"

Brecht Van Lommel (brecht) requested changes to this revision.Fri, Feb 14, 3:24 PM

When this is committed, it's best to bump the subversion immediately, since otherwise changes to this will be lost.

So what is needed to do in this case? Make this in different way?

Whoever commits this can do the subversion bump, nothing needed from your side.

source/blender/makesrna/intern/rna_userdef.c
1502

Don't use abbreviations, use transparent instead of transp.

This revision now requires changes to proceed.Fri, Feb 14, 3:24 PM

changed transp to transparent