4 class DataButtonsPanel(bpy.types.Panel):
5 __space_type__ = "BUTTONS_WINDOW"
6 __region_type__ = "WINDOW"
9 def poll(self, context):
10 ob = context.active_object
11 return (ob and ob.type == 'MESH')
13 class DATA_PT_surface(DataButtonsPanel):
14 __idname__ = "DATA_PT_surface"
17 def draw(self, context):
18 mesh = context.active_object.data
21 split = layout.split()
24 sub.itemR(mesh, "autosmooth")
25 sub.itemR(mesh, "autosmooth_angle", text="Angle")
27 sub.itemR(mesh, "vertex_normal_flip")
28 sub.itemR(mesh, "double_sided")
30 layout.itemR(mesh, "texco_mesh")
32 bpy.types.register(DATA_PT_surface)