UI: improve layout for the texture mapping panel

Group Mirror X and Y under a heading.
Similarly, do the same for Even and Odd tiles.

Pull Request: https://projects.blender.org/blender/blender/pulls/107987
This commit is contained in:
Damien Picard
2023-06-13 19:20:17 +02:00
committed by Hans Goudey
parent 864798b4c7
commit b73ecb0be8

View File

@@ -12,6 +12,7 @@ from bpy.types import (
ParticleSettings,
Texture,
)
from bpy.app.translations import contexts as i18n_contexts
from rna_prop_ui import PropertyPanel
from bl_ui.properties_paint_common import brush_texture_settings
@@ -512,10 +513,10 @@ class TEXTURE_PT_image_mapping(TextureTypePanel, Panel):
sub.prop(tex, "repeat_x", text="Repeat X")
sub.prop(tex, "repeat_y", text="Y")
col = flow.column()
col = flow.column(heading="Mirror")
sub = col.column()
sub.active = (tex.repeat_x > 1)
sub.prop(tex, "use_mirror_x", text="Mirror X")
sub.prop(tex, "use_mirror_x", text="X")
sub = col.column()
sub.active = (tex.repeat_y > 1)
@@ -527,8 +528,8 @@ class TEXTURE_PT_image_mapping(TextureTypePanel, Panel):
col = flow.column()
col.prop(tex, "checker_distance", text="Distance")
col = flow.column()
col.prop(tex, "use_checker_even", text="Tiles Even")
col = flow.column(heading="Tiles")
col.prop(tex, "use_checker_even", text="Even", text_ctxt=i18n_contexts.amount)
col.prop(tex, "use_checker_odd", text="Odd")
else:
del flow