diff options
Diffstat (limited to 'release/scripts/ui/space_node.py')
-rw-r--r-- | release/scripts/ui/space_node.py | 50 |
1 files changed, 43 insertions, 7 deletions
diff --git a/release/scripts/ui/space_node.py b/release/scripts/ui/space_node.py index cd1425ee122..aaf14813ee5 100644 --- a/release/scripts/ui/space_node.py +++ b/release/scripts/ui/space_node.py @@ -68,6 +68,10 @@ class NODE_HT_header(bpy.types.Header): layout.prop(scene, "use_nodes") layout.prop(scene.render, "use_free_unused_nodes", text="Free Unused") layout.prop(snode, "show_backdrop") + if snode.show_backdrop: + row = layout.row(align=True) + row.prop(snode, "backdrop_channels", text="", expand=True) + layout.prop(snode, "use_auto_render") layout.separator() @@ -92,11 +96,11 @@ class NODE_MT_view(bpy.types.Menu): if context.space_data.show_backdrop: layout.separator() - - layout.operator("node.backimage_move",text = "Backdrop move") - layout.operator("node.backimage_zoom",text = "Backdrop zoom in").factor = 1.2 - layout.operator("node.backimage_zoom",text = "Backdrop zoom out").factor = 0.833 - + + layout.operator("node.backimage_move", text="Backdrop move") + layout.operator("node.backimage_zoom", text="Backdrop zoom in").factor = 1.2 + layout.operator("node.backimage_zoom", text="Backdrop zoom out").factor = 0.833 + layout.separator() layout.operator("screen.area_dupli") @@ -158,14 +162,46 @@ class NODE_MT_node(bpy.types.Menu): layout.separator() layout.operator("node.show_cyclic_dependencies") + layout.operator("node.read_renderlayers") + layout.operator("node.read_fullsamplelayers") + + +# Node Backdrop options +class NODE_PT_properties(bpy.types.Panel): + bl_space_type = 'NODE_EDITOR' + bl_region_type = 'UI' + bl_label = "Backdrop" + + @classmethod + def poll(cls, context): + snode = context.space_data + return snode.tree_type == 'COMPOSITING' + + def draw_header(self, context): + snode = context.space_data + self.layout.prop(snode, "show_backdrop", text="") + + def draw(self, context): + layout = self.layout + + snode = context.space_data + layout.active = snode.show_backdrop + layout.prop(snode, "backdrop_channels", text="") + layout.prop(snode, "backdrop_zoom", text="Zoom") + + col = layout.column(align=True) + col.label(text="Offset:") + col.prop(snode, "backdrop_x", text="X") + col.prop(snode, "backdrop_y", text="Y") + col.operator("node.backimage_move", text="Move") def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() |