Page MenuHome

Fix width estimation for buttons with short labels in pie menus
ClosedPublic

Authored by Aleksandr Zinovev (raa) on Aug 11 2017, 1:53 PM.

Details

Summary

Not a regression (was broken in 2.78-), but looks safe enough for 2.79

Before and After:

Run this script in Blender to test the patch:

import bpy
 
class TestPie(bpy.types.Menu):
    bl_label = "Test Pie"

    def draw(self, context):
        layout = self.layout.menu_pie()
        layout.separator()
        layout.separator()
        layout.separator()
        
        col = layout.box().column(True)

        col.row(True).operator("ed.redo")
        col.row(True).operator("ed.redo", "1")

bpy.utils.register_class(TestPie)
bpy.ops.wm.call_menu_pie(name="TestPie")

Diff Detail

Repository
rB Blender

Event Timeline

This revision is now accepted and ready to land.Aug 11 2017, 2:29 PM
This revision was automatically updated to reflect the committed changes.