Changeset View
Changeset View
Standalone View
Standalone View
release/scripts/startup/bl_ui/space_image.py
| Show First 20 Lines • Show All 229 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| layout.operator("image.save_all_modified", text="Save All Images") | layout.operator("image.save_all_modified", text="Save All Images") | ||||
| if ima: | if ima: | ||||
| layout.separator() | layout.separator() | ||||
| layout.menu("IMAGE_MT_image_invert") | layout.menu("IMAGE_MT_image_invert") | ||||
| layout.operator("image.resize", text="Resize") | layout.operator("image.resize", text="Resize") | ||||
| layout.menu("IMAGE_MT_image_flip") | |||||
| if ima and not show_render: | if ima and not show_render: | ||||
| if ima.packed_file: | if ima.packed_file: | ||||
| if ima.filepath: | if ima.filepath: | ||||
| layout.separator() | layout.separator() | ||||
| layout.operator("image.unpack", text="Unpack") | layout.operator("image.unpack", text="Unpack") | ||||
| else: | else: | ||||
| layout.separator() | layout.separator() | ||||
| layout.operator("image.pack", text="Pack") | layout.operator("image.pack", text="Pack") | ||||
| if ima: | if ima: | ||||
| layout.separator() | layout.separator() | ||||
| layout.operator("palette.extract_from_image", text="Extract Palette") | layout.operator("palette.extract_from_image", text="Extract Palette") | ||||
| layout.operator("gpencil.image_to_grease_pencil", text="Generate Grease Pencil") | layout.operator("gpencil.image_to_grease_pencil", text="Generate Grease Pencil") | ||||
| class IMAGE_MT_image_flip(Menu): | |||||
| bl_label = "Flip" | |||||
| def draw(self, _context): | |||||
| layout = self.layout | |||||
| layout.operator("image.flip", text="Horizontally").use_flip_horizontal = True | |||||
| layout.operator("image.flip", text="Vertically").use_flip_vertical = True | |||||
| class IMAGE_MT_image_invert(Menu): | class IMAGE_MT_image_invert(Menu): | ||||
| bl_label = "Invert" | bl_label = "Invert" | ||||
| def draw(self, _context): | def draw(self, _context): | ||||
| layout = self.layout | layout = self.layout | ||||
| props = layout.operator("image.invert", text="Invert Image Colors", icon='IMAGE_RGB') | props = layout.operator("image.invert", text="Invert Image Colors", icon='IMAGE_RGB') | ||||
| ▲ Show 20 Lines • Show All 1,318 Lines • ▼ Show 20 Lines | |||||
| classes = ( | classes = ( | ||||
| IMAGE_MT_view, | IMAGE_MT_view, | ||||
| IMAGE_MT_view_zoom, | IMAGE_MT_view_zoom, | ||||
| IMAGE_MT_select, | IMAGE_MT_select, | ||||
| IMAGE_MT_select_linked, | IMAGE_MT_select_linked, | ||||
| IMAGE_MT_image, | IMAGE_MT_image, | ||||
| IMAGE_MT_image_flip, | |||||
| IMAGE_MT_image_invert, | IMAGE_MT_image_invert, | ||||
| IMAGE_MT_uvs, | IMAGE_MT_uvs, | ||||
| IMAGE_MT_uvs_showhide, | IMAGE_MT_uvs_showhide, | ||||
| IMAGE_MT_uvs_transform, | IMAGE_MT_uvs_transform, | ||||
| IMAGE_MT_uvs_snap, | IMAGE_MT_uvs_snap, | ||||
| IMAGE_MT_uvs_mirror, | IMAGE_MT_uvs_mirror, | ||||
| IMAGE_MT_uvs_align, | IMAGE_MT_uvs_align, | ||||
| IMAGE_MT_uvs_merge, | IMAGE_MT_uvs_merge, | ||||
| ▲ Show 20 Lines • Show All 60 Lines • Show Last 20 Lines | |||||