Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Montagne <montagne29@wanadoo.fr>2012-07-03 13:01:43 +0400
committerBastien Montagne <montagne29@wanadoo.fr>2012-07-03 13:01:43 +0400
commit2dc06f6d50d14a97ff0c37f88b6979d18a0fd279 (patch)
tree60728ddc2bb420bcf11901e27a11a677276cb889
parent842985a49773634076d45f845957216006fc683e (diff)
Style edit (mostly), use """ for docstrings (not ''').
-rw-r--r--add_curve_aceous_galore.py3
-rw-r--r--add_curve_ivygen.py2
-rw-r--r--add_curve_sapling/__init__.py13
-rw-r--r--add_curve_torus_knots.py2
-rw-r--r--add_mesh_BoltFactory/Boltfactory.py2
-rw-r--r--add_mesh_BoltFactory/createMesh.py4
-rw-r--r--add_mesh_ant_landscape.py6
-rw-r--r--add_mesh_extra_objects/add_mesh_3d_function_surface.py6
-rw-r--r--add_mesh_extra_objects/add_mesh_extra_objects.py6
-rw-r--r--add_mesh_extra_objects/add_mesh_gears.py4
-rw-r--r--add_mesh_extra_objects/add_mesh_gemstones.py2
-rw-r--r--add_mesh_extra_objects/add_mesh_honeycomb.py2
-rw-r--r--add_mesh_extra_objects/add_mesh_teapot.py2
-rw-r--r--add_mesh_extra_objects/add_mesh_torusknot.py2
-rw-r--r--add_mesh_extra_objects/add_mesh_twisted_torus.py2
-rw-r--r--add_mesh_pipe_joint.py10
-rw-r--r--animation_add_corrective_shape_key.py2
-rw-r--r--animation_animall.py4
-rw-r--r--curve_simplify.py4
-rw-r--r--io_anim_bvh/__init__.py4
-rw-r--r--io_anim_camera.py2
-rw-r--r--io_anim_nuke_chan/__init__.py8
-rw-r--r--io_convert_image_to_mesh_img/__init__.py2
-rw-r--r--io_convert_image_to_mesh_img/import_img.py44
-rw-r--r--io_curve_svg/__init__.py2
-rw-r--r--io_export_after_effects.py2
-rw-r--r--io_export_pc2.py6
-rw-r--r--io_export_unreal_psk_psa.py3
-rw-r--r--io_import_gimp_image_to_scene.py10
-rw-r--r--io_import_scene_dxf.py2
-rw-r--r--io_import_scene_lwo.py56
-rw-r--r--io_import_scene_mhx.py2
-rw-r--r--io_import_scene_unreal_psk.py2
-rw-r--r--io_mesh_ply/__init__.py6
-rw-r--r--io_mesh_raw/__init__.py4
-rw-r--r--io_mesh_stl/__init__.py4
-rw-r--r--io_mesh_stl/blender_utils.py8
-rw-r--r--io_mesh_stl/stl_utils.py28
-rw-r--r--io_scene_3ds/__init__.py4
-rw-r--r--io_scene_3ds/export_3ds.py88
-rw-r--r--io_scene_3ds/import_3ds.py4
-rw-r--r--io_scene_fbx/__init__.py2
-rw-r--r--io_scene_fbx/export_fbx.py28
-rw-r--r--io_scene_m3/__init__.py2
-rw-r--r--io_scene_m3/import_m3.py2
-rw-r--r--io_scene_map/__init__.py2
-rw-r--r--io_scene_map/export_map.py24
-rw-r--r--io_scene_obj/__init__.py4
-rw-r--r--io_scene_obj/export_obj.py8
-rw-r--r--io_scene_obj/import_obj.py32
-rw-r--r--io_scene_x3d/__init__.py4
-rw-r--r--io_scene_x3d/import_x3d.py48
-rw-r--r--io_shape_mdd/__init__.py4
-rw-r--r--io_shape_mdd/export_mdd.py8
-rw-r--r--mesh_relax.py3
-rw-r--r--mocap/__init__.py49
-rw-r--r--modules/constants_utils.py4
-rw-r--r--modules/cursor_utils.py4
-rw-r--r--modules/geometry_utils.py4
-rw-r--r--modules/misc_utils.py4
-rw-r--r--modules/selection_utils.py4
-rw-r--r--modules/ui_utils.py4
-rw-r--r--netrender/operators.py30
-rw-r--r--object_add_chain.py2
-rw-r--r--object_animrenderbake.py4
-rw-r--r--object_fracture/fracture_ops.py10
-rw-r--r--object_fracture/fracture_setup.py2
-rw-r--r--object_grease_scatter.py4
-rw-r--r--paint_palette.py8
-rw-r--r--render_copy_settings/operator.py10
-rw-r--r--render_povray/update_files.py4
-rw-r--r--rigify/metarig_menu.py2
-rw-r--r--rigify/ui.py5
-rw-r--r--rigify/utils.py4
-rw-r--r--space_view3d_copy_attributes.py28
-rw-r--r--space_view3d_materials_utils.py16
-rw-r--r--space_view3d_math_vis/__init__.py3
-rw-r--r--space_view3d_panel_measure.py2
-rw-r--r--system_demo_mode/__init__.py2
-rw-r--r--system_demo_mode/demo_mode.py4
-rw-r--r--system_property_chart.py4
-rw-r--r--texture_paint_layer_manager.py10
82 files changed, 386 insertions, 381 deletions
diff --git a/add_curve_aceous_galore.py b/add_curve_aceous_galore.py
index 44447162..b6417434 100644
--- a/add_curve_aceous_galore.py
+++ b/add_curve_aceous_galore.py
@@ -762,11 +762,10 @@ def main(context, self, align_matrix):
return
class Curveaceous_galore(bpy.types.Operator):
- ''''''
+ """Add many types of curves"""
bl_idname = "mesh.curveaceous_galore"
bl_label = "Curveaceous galore"
bl_options = {'REGISTER', 'UNDO'}
- bl_description = "adds many types of curves"
# align_matrix for the invoke
align_matrix = Matrix()
diff --git a/add_curve_ivygen.py b/add_curve_ivygen.py
index b680cfed..26770fda 100644
--- a/add_curve_ivygen.py
+++ b/add_curve_ivygen.py
@@ -44,7 +44,7 @@ import time
def createIvyGeometry(IVY, growLeaves):
- '''Create the curve geometry for IVY'''
+ """Create the curve geometry for IVY"""
# Compute the local size and the gauss weight filter
#local_ivyBranchSize = IVY.ivyBranchSize # * radius * IVY.ivySize
gaussWeight = (1.0, 2.0, 4.0, 7.0, 9.0, 10.0, 9.0, 7.0, 4.0, 2.0, 1.0)
diff --git a/add_curve_sapling/__init__.py b/add_curve_sapling/__init__.py
index 81d7aea9..12d3c9c1 100644
--- a/add_curve_sapling/__init__.py
+++ b/add_curve_sapling/__init__.py
@@ -74,9 +74,9 @@ settings = [('0', 'Geometry', 'Geometry'),
def getPresetpath():
- '''Support user defined scripts directory
+ """Support user defined scripts directory
Find the first ocurrence of add_curve_sapling/presets in possible script paths
- and return it as preset path'''
+ and return it as preset path"""
presetpath = ""
for p in bpy.utils.script_paths():
presetpath = os.path.join(p, 'addons', 'add_curve_sapling', 'presets')
@@ -86,7 +86,7 @@ def getPresetpath():
class ExportData(bpy.types.Operator):
- '''This operator handles writing presets to file'''
+ """This operator handles writing presets to file"""
bl_idname = 'sapling.exportdata'
bl_label = 'Export Preset'
@@ -114,7 +114,7 @@ class ExportData(bpy.types.Operator):
class ImportData(bpy.types.Operator):
- '''This operator handles importing existing presets'''
+ """This operator handles importing existing presets"""
bl_idname = 'sapling.importdata'
bl_label = 'Import Preset'
@@ -135,9 +135,8 @@ class ImportData(bpy.types.Operator):
class PresetMenu(bpy.types.Menu):
- '''Create the preset menu by finding all preset files
- in the preset directory
- '''
+ """Create the preset menu by finding all preset files """ \
+ """in the preset directory"""
bl_idname = "sapling.presetmenu"
bl_label = "Presets"
diff --git a/add_curve_torus_knots.py b/add_curve_torus_knots.py
index 21c406d0..42b7a6ef 100644
--- a/add_curve_torus_knots.py
+++ b/add_curve_torus_knots.py
@@ -97,7 +97,7 @@ def create_torus_knot(self, context):
class torus_knot_plus(bpy.types.Operator, AddObjectHelper):
- ''''''
+ """"""
bl_idname = "curve.torus_knot_plus"
bl_label = "Torus Knot +"
bl_options = {'REGISTER', 'UNDO'}
diff --git a/add_mesh_BoltFactory/Boltfactory.py b/add_mesh_BoltFactory/Boltfactory.py
index 24237acd..cd123b02 100644
--- a/add_mesh_BoltFactory/Boltfactory.py
+++ b/add_mesh_BoltFactory/Boltfactory.py
@@ -42,7 +42,7 @@ def align_matrix(context):
class add_mesh_bolt(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "mesh.bolt_add"
bl_label = "Add Bolt"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_BoltFactory/createMesh.py b/add_mesh_BoltFactory/createMesh.py
index fa625b8d..e9d2be14 100644
--- a/add_mesh_BoltFactory/createMesh.py
+++ b/add_mesh_BoltFactory/createMesh.py
@@ -59,7 +59,7 @@ def unpack_face_list(list_of_tuples):
return l
-'''
+"""
Remove Doubles takes a list on Verts and a list of Faces and
removes the doubles, much like Blender does in edit mode.
It doesn’t have the range function but it will round the corrdinates
@@ -67,7 +67,7 @@ and remove verts that are very close togther. The function
is useful because you can perform a “Remove Doubles” with out
having to enter Edit Mode. Having to enter edit mode has the
disadvantage of not being able to interactively change the properties.
-'''
+"""
def RemoveDoubles(verts,faces,Decimal_Places = 4):
diff --git a/add_mesh_ant_landscape.py b/add_mesh_ant_landscape.py
index fcc1e8ed..c3aeb866 100644
--- a/add_mesh_ant_landscape.py
+++ b/add_mesh_ant_landscape.py
@@ -30,7 +30,7 @@ bl_info = {
"func=detail&aid=23130",
"category": "Add Mesh"}
-'''
+"""
Another Noise Tool: Landscape mesh generator
MESH OPTIONS:
@@ -66,7 +66,7 @@ Sealevel: Flattens terrain below sealevel.
Platlevel: Flattens terrain above plateau level.
Strata: Strata amount, number of strata/terrace layers.
Strata type: Strata types, Smooth, Sharp-sub, Sharp-add
-'''
+"""
# import modules
import bpy
@@ -430,7 +430,7 @@ def sphere_gen( sub_d, size_me, options ):
###------------------------------------------------------------
# Add landscape
class landscape_add(bpy.types.Operator):
- '''Add a landscape mesh'''
+ """Add a landscape mesh"""
bl_idname = "mesh.landscape_add"
bl_label = "Landscape"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_extra_objects/add_mesh_3d_function_surface.py b/add_mesh_extra_objects/add_mesh_3d_function_surface.py
index eabf680c..bd3ddfc7 100644
--- a/add_mesh_extra_objects/add_mesh_3d_function_surface.py
+++ b/add_mesh_extra_objects/add_mesh_3d_function_surface.py
@@ -145,7 +145,7 @@ def createFaces(vertIdx1, vertIdx2, closed=False, flipped=False):
class AddZFunctionSurface(bpy.types.Operator):
- '''Add a surface defined defined by a function z=f(x,y)'''
+ """Add a surface defined defined by a function z=f(x,y)"""
bl_idname = "mesh.primitive_z_function_surface"
bl_label = "Add Z Function Surface"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -398,8 +398,8 @@ def xyz_function_surface_faces(self, x_eq, y_eq, z_eq,
# v_min = -pi/4,
# v max = 5*pi/2
class AddXYZFunctionSurface(bpy.types.Operator):
- '''Add a surface defined defined by 3 functions:''' \
- + ''' x=F1(u,v), y=F2(u,v) and z=F3(u,v)'''
+ """Add a surface defined defined by 3 functions:""" \
+ """ x=F1(u,v), y=F2(u,v) and z=F3(u,v)"""
bl_idname = "mesh.primitive_xyz_function_surface"
bl_label = "Add X,Y,Z Function Surface"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_extra_objects/add_mesh_extra_objects.py b/add_mesh_extra_objects/add_mesh_extra_objects.py
index f2f4d8cd..1007b157 100644
--- a/add_mesh_extra_objects/add_mesh_extra_objects.py
+++ b/add_mesh_extra_objects/add_mesh_extra_objects.py
@@ -357,7 +357,7 @@ def trapezohedron(s,r,h):
return verts,faces
class AddSqorus(bpy.types.Operator):
- '''Add a sqorus mesh'''
+ """Add a sqorus mesh"""
bl_idname = "mesh.primitive_sqorus_add"
bl_label = "Add Sqorus"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -386,7 +386,7 @@ class AddSqorus(bpy.types.Operator):
class AddWedge(bpy.types.Operator):
- '''Add a wedge mesh'''
+ """Add a wedge mesh"""
bl_idname = "mesh.primitive_wedge_add"
bl_label = "Add Wedge"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -420,7 +420,7 @@ class AddWedge(bpy.types.Operator):
class AddStar(bpy.types.Operator):
- '''Add a star mesh'''
+ """Add a star mesh"""
bl_idname = "mesh.primitive_star_add"
bl_label = "Add Star"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_extra_objects/add_mesh_gears.py b/add_mesh_extra_objects/add_mesh_gears.py
index 8b35ffca..504fdcfd 100644
--- a/add_mesh_extra_objects/add_mesh_gears.py
+++ b/add_mesh_extra_objects/add_mesh_gears.py
@@ -570,7 +570,7 @@ def add_worm(teethNum, rowNum, radius, Ad, De, p_angle,
class AddGear(bpy.types.Operator):
- '''Add a gear mesh'''
+ """Add a gear mesh"""
bl_idname = "mesh.primitive_gear"
bl_label = "Add Gear"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -676,7 +676,7 @@ class AddGear(bpy.types.Operator):
class AddWormGear(bpy.types.Operator):
- '''Add a worm gear mesh'''
+ """Add a worm gear mesh"""
bl_idname = "mesh.primitive_worm_gear"
bl_label = "Add Worm Gear"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_extra_objects/add_mesh_gemstones.py b/add_mesh_extra_objects/add_mesh_gemstones.py
index 378ee072..075d8266 100644
--- a/add_mesh_extra_objects/add_mesh_gemstones.py
+++ b/add_mesh_extra_objects/add_mesh_gemstones.py
@@ -238,7 +238,7 @@ def add_diamond(segments, girdle_radius, table_radius,
class AddDiamond(bpy.types.Operator):
- '''Add a diamond mesh'''
+ """Add a diamond mesh"""
bl_idname = "mesh.primitive_diamond_add"
bl_label = "Add Diamond"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_extra_objects/add_mesh_honeycomb.py b/add_mesh_extra_objects/add_mesh_honeycomb.py
index f58cd552..b39cb42d 100644
--- a/add_mesh_extra_objects/add_mesh_honeycomb.py
+++ b/add_mesh_extra_objects/add_mesh_honeycomb.py
@@ -207,7 +207,7 @@ def edge_max(diam):
return diam * sin(pi / 3)
class add_mesh_honeycomb(bpy.types.Operator):
- '''Simple honeycomb mesh generator'''
+ """Simple honeycomb mesh generator"""
bl_idname = 'mesh.honeycomb_add'
bl_label = 'Add HoneyComb'
bl_options = {'REGISTER', 'UNDO'}
diff --git a/add_mesh_extra_objects/add_mesh_teapot.py b/add_mesh_extra_objects/add_mesh_teapot.py
index 7530735b..93030aa3 100644
--- a/add_mesh_extra_objects/add_mesh_teapot.py
+++ b/add_mesh_extra_objects/add_mesh_teapot.py
@@ -37,7 +37,7 @@ bl_info = {
import bpy, mathutils, io, operator, functools
class AddTeapot(bpy.types.Operator):
- '''Add a teapot mesh.'''
+ """Add a teapot mesh"""
bl_idname = "mesh.primitive_teapot_add"
bl_label = "Add Teapot"
bl_options = {"REGISTER", "UNDO"}
diff --git a/add_mesh_extra_objects/add_mesh_torusknot.py b/add_mesh_extra_objects/add_mesh_torusknot.py
index 7174c657..2ce4b2a1 100644
--- a/add_mesh_extra_objects/add_mesh_torusknot.py
+++ b/add_mesh_extra_objects/add_mesh_torusknot.py
@@ -115,7 +115,7 @@ def make_knot(knotidx, ures):
return (verts, faces)
class AddTorusKnot(bpy.types.Operator):
- '''Add a torus-knot mesh.'''
+ """Add a torus-knot mesh"""
bl_idname = "mesh.primitive_torusknot_add"
bl_label = "Add Torus Knot"
bl_options = {"REGISTER", "UNDO"}
diff --git a/add_mesh_extra_objects/add_mesh_twisted_torus.py b/add_mesh_extra_objects/add_mesh_twisted_torus.py
index de07003e..f2e5e84b 100644
--- a/add_mesh_extra_objects/add_mesh_twisted_torus.py
+++ b/add_mesh_extra_objects/add_mesh_twisted_torus.py
@@ -182,7 +182,7 @@ def add_twisted_torus(major_rad, minor_rad, major_seg, minor_seg, twists):
class AddTwistedTorus(bpy.types.Operator):
- '''Add a torus mesh'''
+ """Add a torus mesh"""
bl_idname = "mesh.primitive_twisted_torus_add"
bl_label = "Add Torus"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
diff --git a/add_mesh_pipe_joint.py b/add_mesh_pipe_joint.py
index b11ed2bf..aa41532e 100644
--- a/add_mesh_pipe_joint.py
+++ b/add_mesh_pipe_joint.py
@@ -123,7 +123,7 @@ def createFaces(vertIdx1, vertIdx2, closed=False, flipped=False):
class AddElbowJoint(bpy.types.Operator):
# Create the vertices and polygons for a simple elbow (bent pipe).
- '''Add an Elbow pipe mesh'''
+ """Add an Elbow pipe mesh"""
bl_idname = "mesh.primitive_elbow_joint_add"
bl_label = "Add Pipe Elbow"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -224,7 +224,7 @@ class AddElbowJoint(bpy.types.Operator):
class AddTeeJoint(bpy.types.Operator):
# Create the vertices and polygons for a simple tee (T) joint.
# The base arm of the T can be positioned in an angle if needed though.
- '''Add a Tee-Joint mesh'''
+ """Add a Tee-Joint mesh"""
bl_idname = "mesh.primitive_tee_joint_add"
bl_label = "Add Pipe Tee-Joint"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -401,7 +401,7 @@ class AddTeeJoint(bpy.types.Operator):
class AddWyeJoint(bpy.types.Operator):
- '''Add a Wye-Joint mesh'''
+ """Add a Wye-Joint mesh"""
bl_idname = "mesh.primitive_wye_joint_add"
bl_label = "Add Pipe Wye-Joint"
bl_options = {'REGISTER', 'UNDO', 'PRESET'}
@@ -595,7 +595,7 @@ class AddWyeJoint(bpy.types.Operator):
class AddCrossJoint(bpy.types.Operator):
- '''Add a Cross-Joint mesh'''
+ """Add a Cross-Joint mesh"""
# Create the vertices and polygons for a coss (+ or X) pipe joint.
bl_idname = "mesh.primitive_cross_joint_add"
bl_label = "Add Pipe Cross-Joint"
@@ -850,7 +850,7 @@ class AddCrossJoint(bpy.types.Operator):
class AddNJoint(bpy.types.Operator):
- '''Add a N-Joint mesh'''
+ """Add a N-Joint mesh"""
# Create the vertices and polygons for a regular n-joint.
bl_idname = "mesh.primitive_n_joint_add"
bl_label = "Add Pipe N-Joint"
diff --git a/animation_add_corrective_shape_key.py b/animation_add_corrective_shape_key.py
index dc24639d..230959e6 100644
--- a/animation_add_corrective_shape_key.py
+++ b/animation_add_corrective_shape_key.py
@@ -211,7 +211,7 @@ def func_object_duplicate_flatten_modifiers(scene, obj):
class object_duplicate_flatten_modifiers(bpy.types.Operator):
- '''Duplicates the selected object with modifiers applied'''
+ """Duplicates the selected object with modifiers applied"""
bl_idname = "object.object_duplicate_flatten_modifiers"
bl_label = "Duplicate and apply all"
diff --git a/animation_animall.py b/animation_animall.py
index 60367e43..a1061533 100644
--- a/animation_animall.py
+++ b/animation_animall.py
@@ -29,7 +29,7 @@ bl_info = {
'func=detail&aid=24874',
'category': 'Animation'}
-'''-------------------------------------------------------------------------
+"""-------------------------------------------------------------------------
Thanks to Campbell Barton and Joshua Leung for hes API additions and fixes
Daniel 'ZanQdo' Salazar
@@ -40,7 +40,7 @@ Rev 0.4 added support for ShapeKey layer animation, removed support
for direct point animation since this new aproach is much stronger
and inline with the animation system
Rev 0.5 merged curve animation features from rotobezier and ported to new bmesh API
--------------------------------------------------------------------------'''
+-------------------------------------------------------------------------"""
import bpy
from bpy.props import *
diff --git a/curve_simplify.py b/curve_simplify.py
index 8ae67bb3..b624a128 100644
--- a/curve_simplify.py
+++ b/curve_simplify.py
@@ -355,7 +355,7 @@ def fcurves_simplify(context, obj, options, fcurves):
#### ANIMATION CURVES OPERATOR ##################
#################################################
class GRAPH_OT_simplify(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "graph.simplify"
bl_label = "simplifiy f-curves"
bl_description = "simplify selected f-curves"
@@ -459,7 +459,7 @@ class GRAPH_OT_simplify(bpy.types.Operator):
##### Curves OPERATOR #####
###########################
class CURVE_OT_simplify(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "curve.simplify"
bl_label = "simplifiy curves"
bl_description = "simplify curves"
diff --git a/io_anim_bvh/__init__.py b/io_anim_bvh/__init__.py
index ca2438eb..993bd734 100644
--- a/io_anim_bvh/__init__.py
+++ b/io_anim_bvh/__init__.py
@@ -52,7 +52,7 @@ from bpy_extras.io_utils import (ImportHelper,
class ImportBVH(bpy.types.Operator, ImportHelper):
- '''Load a BVH motion capture file'''
+ """Load a BVH motion capture file"""
bl_idname = "import_anim.bvh"
bl_label = "Import BVH"
bl_options = {'REGISTER', 'UNDO'}
@@ -143,7 +143,7 @@ class ImportBVH(bpy.types.Operator, ImportHelper):
class ExportBVH(bpy.types.Operator, ExportHelper):
- '''Save a BVH motion capture file from an armature'''
+ """Save a BVH motion capture file from an armature"""
bl_idname = "export_anim.bvh"
bl_label = "Export BVH"
diff --git a/io_anim_camera.py b/io_anim_camera.py
index 6a282e9c..e04fe517 100644
--- a/io_anim_camera.py
+++ b/io_anim_camera.py
@@ -118,7 +118,7 @@ from bpy_extras.io_utils import ExportHelper
class CameraExporter(bpy.types.Operator, ExportHelper):
- '''Save a python script which re-creates cameras and markers elsewhere'''
+ """Save a python script which re-creates cameras and markers elsewhere"""
bl_idname = "export_animation.cameras"
bl_label = "Export Camera & Markers"
diff --git a/io_anim_nuke_chan/__init__.py b/io_anim_nuke_chan/__init__.py
index 5636de29..c025812c 100644
--- a/io_anim_nuke_chan/__init__.py
+++ b/io_anim_nuke_chan/__init__.py
@@ -66,8 +66,8 @@ rotation_order = EnumProperty(
class ImportChan(Operator, ImportHelper):
- '''Import animation from .chan file, exported from nuke or houdini. ''' \
- '''The importer uses frame numbers from the file'''
+ """Import animation from .chan file, exported from nuke or houdini """ \
+ """(the importer uses frame numbers from the file)"""
bl_idname = "import_scene.import_chan"
bl_label = "Import chan file"
@@ -106,8 +106,8 @@ class ImportChan(Operator, ImportHelper):
class ExportChan(Operator, ExportHelper):
- '''Export the animation to .chan file, readable by nuke and houdini. ''' \
- '''The exporter uses frames from the frames range'''
+ """Export the animation to .chan file, readable by nuke and houdini """ \
+ """(the exporter uses frames from the frames range)"""
bl_idname = "export.export_chan"
bl_label = "Export chan file"
diff --git a/io_convert_image_to_mesh_img/__init__.py b/io_convert_image_to_mesh_img/__init__.py
index 89b64317..dd162a71 100644
--- a/io_convert_image_to_mesh_img/__init__.py
+++ b/io_convert_image_to_mesh_img/__init__.py
@@ -59,7 +59,7 @@ from bpy_extras.io_utils import ImportHelper
class ImportHiRISEIMGDTM(bpy.types.Operator, ImportHelper):
- '''Import a HiRISE DTM formatted as a PDS IMG file'''
+ """Import a HiRISE DTM formatted as a PDS IMG file"""
bl_idname = "import_shape.img"
bl_label = "Import HiRISE DTM from PDS IMG"
bl_options = {'UNDO'}
diff --git a/io_convert_image_to_mesh_img/import_img.py b/io_convert_image_to_mesh_img/import_img.py
index 04892069..68caab8d 100644
--- a/io_convert_image_to_mesh_img/import_img.py
+++ b/io_convert_image_to_mesh_img/import_img.py
@@ -28,7 +28,7 @@ import os
import queue, threading
class image_properties:
- ''' keeps track of image attributes throughout the hirise_dtm_importer class '''
+ """ keeps track of image attributes throughout the hirise_dtm_importer class """
def __init__(self, name, dimensions, pixel_scale):
self.name( name )
self.dims( dimensions )
@@ -56,7 +56,7 @@ class image_properties:
return self.__pixel_scale
class hirise_dtm_importer(object):
- ''' methods to understand/import a HiRISE DTM formatted as a PDS .IMG '''
+ """ methods to understand/import a HiRISE DTM formatted as a PDS .IMG """
def __init__(self, context, filepath):
self.__context = context
@@ -141,9 +141,9 @@ class hirise_dtm_importer(object):
return (label, self.parsePDSLabel(self.iterArr(label)))
def getLinesAndSamples(self, label):
- ''' uses the parsed PDS Label to get the LINES and LINE_SAMPLES parameters
+ """ uses the parsed PDS Label to get the LINES and LINE_SAMPLES parameters
from the first object named "IMAGE" -- is hackish
- '''
+ """
for obj in label:
if obj[0] == "IMAGE":
return self.getLinesAndSamples(obj[1])
@@ -155,9 +155,9 @@ class hirise_dtm_importer(object):
return ( line_samples, lines )
def getValidMinMax(self, label):
- ''' uses the parsed PDS Label to get the VALID_MINIMUM and VALID_MAXIMUM parameters
+ """ uses the parsed PDS Label to get the VALID_MINIMUM and VALID_MAXIMUM parameters
from the first object named "IMAGE" -- is hackish
- '''
+ """
for obj in label:
if obj[0] == "IMAGE":
return self.getValidMinMax(obj[1])
@@ -169,9 +169,9 @@ class hirise_dtm_importer(object):
return vmin, vmax
def getMissingConstant(self, label):
- ''' uses the parsed PDS Label to get the MISSING_CONSTANT parameter
+ """ uses the parsed PDS Label to get the MISSING_CONSTANT parameter
from the first object named "IMAGE" -- is hackish
- '''
+ """
for obj in label:
if obj[0] == "IMAGE":
return self.getMissingConstant(obj[1])
@@ -192,7 +192,7 @@ class hirise_dtm_importer(object):
############################################################################
def bin2(self, image_iter, bin2_method_type="SLOW"):
- ''' this is an iterator that: Given an image iterator will yield binned lines '''
+ """ this is an iterator that: Given an image iterator will yield binned lines """
ignore_value = self.__ignore_value
@@ -227,7 +227,7 @@ class hirise_dtm_importer(object):
line_count += 1
def bin6(self, image_iter, bin6_method_type="SLOW"):
- ''' this is an iterator that: Given an image iterator will yield binned lines '''
+ """ this is an iterator that: Given an image iterator will yield binned lines """
img_props = next(image_iter)
# dimensions shrink as we remove pixels
@@ -256,7 +256,7 @@ class hirise_dtm_importer(object):
raw_data = []
def bin6_real(self, raw_data):
- ''' does a 6x6 sample of raw_data and returns a single line of data '''
+ """ does a 6x6 sample of raw_data and returns a single line of data """
# TODO: make this more efficient
binned_data = []
@@ -287,7 +287,7 @@ class hirise_dtm_importer(object):
return binned_data
def bin6_real_fast(self, raw_data):
- ''' takes a single value from each 6x6 sample of raw_data and returns a single line of data '''
+ """ takes a single value from each 6x6 sample of raw_data and returns a single line of data """
# TODO: make this more efficient
binned_data = []
@@ -300,7 +300,7 @@ class hirise_dtm_importer(object):
return binned_data
def bin12(self, image_iter, bin12_method_type="SLOW"):
- ''' this is an iterator that: Given an image iterator will yield binned lines '''
+ """ this is an iterator that: Given an image iterator will yield binned lines """
img_props = next(image_iter)
# dimensions shrink as we remove pixels
@@ -329,7 +329,7 @@ class hirise_dtm_importer(object):
raw_data = []
def bin12_real(self, raw_data):
- ''' does a 12x12 sample of raw_data and returns a single line of data '''
+ """ does a 12x12 sample of raw_data and returns a single line of data """
binned_data = []
@@ -363,11 +363,11 @@ class hirise_dtm_importer(object):
return binned_data
def bin12_real_fast(self, raw_data):
- ''' takes a single value from each 12x12 sample of raw_data and returns a single line of data '''
+ """ takes a single value from each 12x12 sample of raw_data and returns a single line of data """
return raw_data[0][11::12]
def cropXY(self, image_iter, XSize=None, YSize=None, XOffset=0, YOffset=0):
- ''' return a cropped portion of the image '''
+ """ return a cropped portion of the image """
img_props = next(image_iter)
# dimensions shrink as we remove pixels
@@ -398,7 +398,7 @@ class hirise_dtm_importer(object):
currentY += 1
def getImage(self, img, img_props):
- ''' Assumes 32-bit pixels -- bins image '''
+ """ Assumes 32-bit pixels -- bins image """
dims = img_props.dims()
# setup to unpack more efficiently.
@@ -438,9 +438,9 @@ class hirise_dtm_importer(object):
yield unpack( unpack_str, pixels )
def shiftToOrigin(self, image_iter, image_min_max):
- ''' takes a generator and shifts the points by the valid minimum
+ """ takes a generator and shifts the points by the valid minimum
also removes points with value self.__ignore_value and replaces them with None
- '''
+ """
# use the passed in values ...
valid_min = image_min_max[0]
@@ -459,7 +459,7 @@ class hirise_dtm_importer(object):
yield list(map(normalize_fun, line))
def scaleZ(self, image_iter, scale_factor):
- ''' scales the mesh values by a factor '''
+ """ scales the mesh values by a factor """
# pass on dimensions since we don't modify them here
yield next(image_iter)
@@ -475,9 +475,9 @@ class hirise_dtm_importer(object):
yield list(map(scale_fun, line))
def genMesh(self, image_iter):
- '''Returns a mesh object from an image iterator this has the
+ """Returns a mesh object from an image iterator this has the
value-added feature that a value of "None" is ignored
- '''
+ """
# Get the output image size given the above transforms
img_props = next(image_iter)
diff --git a/io_curve_svg/__init__.py b/io_curve_svg/__init__.py
index 02177515..db58a9f1 100644
--- a/io_curve_svg/__init__.py
+++ b/io_curve_svg/__init__.py
@@ -46,7 +46,7 @@ from bpy_extras.io_utils import ImportHelper
class ImportSVG(bpy.types.Operator, ImportHelper):
- '''Load a SVG file'''
+ """Load a SVG file"""
bl_idname = "import_curve.svg"
bl_label = "Import SVG"
bl_options = {'UNDO'}
diff --git a/io_export_after_effects.py b/io_export_after_effects.py
index 580f6e2f..a71348a3 100644
--- a/io_export_after_effects.py
+++ b/io_export_after_effects.py
@@ -693,7 +693,7 @@ from bpy.props import StringProperty, BoolProperty
class ExportJsx(bpy.types.Operator, ExportHelper):
- '''Export selected cameras and objects animation to After Effects'''
+ """Export selected cameras and objects animation to After Effects"""
bl_idname = "export.jsx"
bl_label = "Export to Adobe After Effects"
filename_ext = ".jsx"
diff --git a/io_export_pc2.py b/io_export_pc2.py
index e6a19d8c..440e4c2f 100644
--- a/io_export_pc2.py
+++ b/io_export_pc2.py
@@ -30,13 +30,13 @@ bl_info = {
"func=detail&aid=24703",
"category": "Import-Export"}
-'''
+"""
Usage Notes:
in Maya Mel:
cacheFile -pc2 1 -pcf "<insert filepath of source>" -f "<insert target filename w/o extension>" -dir "<insert directory path for target>" -format "OneFile";
-'''
+"""
import bpy
from bpy.props import *
@@ -104,7 +104,7 @@ def do_export(context, props, filepath):
###### EXPORT OPERATOR #######
class Export_pc2(bpy.types.Operator, ExportHelper):
- '''Exports the active Object as a .pc2 Pointcache file'''
+ """Export the active Object as a .pc2 Pointcache file"""
bl_idname = "export_shape.pc2"
bl_label = "Export Pointcache (.pc2)"
diff --git a/io_export_unreal_psk_psa.py b/io_export_unreal_psk_psa.py
index c8ac57c2..137d3d44 100644
--- a/io_export_unreal_psk_psa.py
+++ b/io_export_unreal_psk_psa.py
@@ -2179,8 +2179,7 @@ class Panel_UDKExport( bpy.types.Panel ):
#layout.separator()
class ExportUDKAnimData(bpy.types.Operator):
-
- '''Export Skeleton Mesh / Animation Data file(s)'''
+ """Export Skeleton Mesh / Animation Data file(s)"""
bl_idname = "export_anim.udk" # this is important since its how bpy.ops.export.udk_anim_data is constructed
bl_label = "Export PSK/PSA"
__doc__ = """One mesh and one armature else select one mesh or armature to be exported"""
diff --git a/io_import_gimp_image_to_scene.py b/io_import_gimp_image_to_scene.py
index ee717dac..a39ef1ed 100644
--- a/io_import_gimp_image_to_scene.py
+++ b/io_import_gimp_image_to_scene.py
@@ -87,9 +87,9 @@ def main(File, Path, LayerViewers, MixerViewers, LayerOffset,
ResX, ResY = map (int, Segment[4:].split(','))
if Line.startswith("b'L") or Line.startswith("b'l"):
- '''The "nice" method to check if layer has alpha channel
+ """The "nice" method to check if layer has alpha channel
sadly GIMP sometimes decides not to export an alpha channel
- if it's pure white so we are not completly sure here yet'''
+ if it's pure white so we are not completly sure here yet"""
if Line.startswith("b'L"): HasAlpha = True
else: HasAlpha = False
@@ -103,8 +103,8 @@ def main(File, Path, LayerViewers, MixerViewers, LayerOffset,
imageFile = 'l' + Segment[3:] + '.jpg'
imageFileAlpha ='la'+Segment[3:]+'.jpg'
- '''Phisically double checking if alpha image exists
- now we can be sure! (damn GIMP)'''
+ """Phisically double checking if alpha image exists
+ now we can be sure! (damn GIMP)"""
if HasAlpha:
if not os.path.isfile(PathSaveRaw+imageFileAlpha): HasAlpha = False
@@ -541,7 +541,7 @@ from math import pi
# Operator
class GIMPImageToScene(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "import.gimp_image_to_scene"
bl_label = "GIMP Image to Scene"
bl_description = "Imports GIMP multilayer image files into 3D Scenes"
diff --git a/io_import_scene_dxf.py b/io_import_scene_dxf.py
index 406063bb..511891c2 100644
--- a/io_import_scene_dxf.py
+++ b/io_import_scene_dxf.py
@@ -2419,7 +2419,7 @@ def tripleList(list1):
return list3
class IMPORT_OT_autocad_dxf(bpy.types.Operator):
- '''Import from DXF file format (.dxf)'''
+ """Import from DXF file format (.dxf)"""
bl_idname = "import_scene.autocad_dxf"
bl_description = 'Import from DXF file format (.dxf)'
bl_label = "Import DXF" +' v.'+ __version__
diff --git a/io_import_scene_lwo.py b/io_import_scene_lwo.py
index d74cc74c..b019f5bc 100644
--- a/io_import_scene_lwo.py
+++ b/io_import_scene_lwo.py
@@ -153,7 +153,7 @@ def load_lwo(filename,
ADD_SUBD_MOD=True,
LOAD_HIDDEN=False,
SKEL_TO_ARM=True):
- '''Read the LWO file, hand off to version specific function.'''
+ """Read the LWO file, hand off to version specific function."""
name, ext= os.path.splitext(os.path.basename(filename))
file= open(filename, 'rb')
@@ -189,7 +189,7 @@ def load_lwo(filename,
def read_lwo2(file, filename, layers, surfs, tags, add_subd_mod, load_hidden, skel_to_arm):
- '''Read version 2 file, LW 6+.'''
+ """Read version 2 file, LW 6+."""
handle_layer= True
last_pols_count= 0
just_read_bones= False
@@ -275,7 +275,7 @@ def read_lwo2(file, filename, layers, surfs, tags, add_subd_mod, load_hidden, sk
def read_lwob(file, filename, layers, surfs, tags, add_subd_mod):
- '''Read version 1 file, LW < 6.'''
+ """Read version 1 file, LW < 6."""
last_pols_count= 0
print("Importing LWO: " + filename + "\nLWO v1 Format")
@@ -317,7 +317,7 @@ def read_lwob(file, filename, layers, surfs, tags, add_subd_mod):
def read_lwostring(raw_name):
- '''Parse a zero-padded string.'''
+ """Parse a zero-padded string."""
i = raw_name.find(b'\0')
name_len = i + 1
@@ -334,7 +334,7 @@ def read_lwostring(raw_name):
def read_vx(pointdata):
- '''Read a variable-length index.'''
+ """Read a variable-length index."""
if pointdata[0] != 255:
index= pointdata[0]*256 + pointdata[1]
size= 2
@@ -346,7 +346,7 @@ def read_vx(pointdata):
def read_tags(tag_bytes, object_tags):
- '''Read the object's Tags chunk.'''
+ """Read the object's Tags chunk."""
offset= 0
chunk_len= len(tag_bytes)
@@ -357,7 +357,7 @@ def read_tags(tag_bytes, object_tags):
def read_layr(layr_bytes, object_layers, load_hidden):
- '''Read the object's layer data.'''
+ """Read the object's layer data."""
new_layr= _obj_layer()
new_layr.index, flags= struct.unpack(">HH", layr_bytes[0:4])
@@ -386,7 +386,7 @@ def read_layr(layr_bytes, object_layers, load_hidden):
def read_layr_5(layr_bytes, object_layers):
- '''Read the object's layer data.'''
+ """Read the object's layer data."""
# XXX: Need to check what these two exactly mean for a LWOB/LWLO file.
new_layr= _obj_layer()
new_layr.index, flags= struct.unpack(">HH", layr_bytes[0:4])
@@ -405,7 +405,7 @@ def read_layr_5(layr_bytes, object_layers):
def read_pnts(pnt_bytes, object_layers):
- '''Read the layer's points.'''
+ """Read the layer's points."""
print("\tReading Layer ("+object_layers[-1].name+") Points")
offset= 0
chunk_len= len(pnt_bytes)
@@ -422,7 +422,7 @@ def read_pnts(pnt_bytes, object_layers):
def read_weightmap(weight_bytes, object_layers):
- '''Read a weight map's values.'''
+ """Read a weight map's values."""
chunk_len= len(weight_bytes)
offset= 2
name, name_len= read_lwostring(weight_bytes[offset:])
@@ -440,7 +440,7 @@ def read_weightmap(weight_bytes, object_layers):
def read_morph(morph_bytes, object_layers, is_abs):
- '''Read an endomorph's relative or absolute displacement values.'''
+ """Read an endomorph's relative or absolute displacement values."""
chunk_len= len(morph_bytes)
offset= 2
name, name_len= read_lwostring(morph_bytes[offset:])
@@ -464,7 +464,7 @@ def read_morph(morph_bytes, object_layers, is_abs):
def read_colmap(col_bytes, object_layers):
- '''Read the RGB or RGBA color map.'''
+ """Read the RGB or RGBA color map."""
chunk_len= len(col_bytes)
dia,= struct.unpack(">H", col_bytes[0:2])
offset= 2
@@ -497,7 +497,7 @@ def read_colmap(col_bytes, object_layers):
def read_color_vmad(col_bytes, object_layers, last_pols_count):
- '''Read the Discontinous (per-polygon) RGB values.'''
+ """Read the Discontinous (per-polygon) RGB values."""
chunk_len= len(col_bytes)
dia,= struct.unpack(">H", col_bytes[0:2])
offset= 2
@@ -546,7 +546,7 @@ def read_color_vmad(col_bytes, object_layers, last_pols_count):
def read_uvmap(uv_bytes, object_layers):
- '''Read the simple UV coord values.'''
+ """Read the simple UV coord values."""
chunk_len= len(uv_bytes)
offset= 2
name, name_len= read_lwostring(uv_bytes[offset:])
@@ -570,7 +570,7 @@ def read_uvmap(uv_bytes, object_layers):
def read_uv_vmad(uv_bytes, object_layers, last_pols_count):
- '''Read the Discontinous (per-polygon) uv values.'''
+ """Read the Discontinous (per-polygon) uv values."""
chunk_len= len(uv_bytes)
offset= 2
name, name_len= read_lwostring(uv_bytes[offset:])
@@ -602,7 +602,7 @@ def read_uv_vmad(uv_bytes, object_layers, last_pols_count):
def read_weight_vmad(ew_bytes, object_layers):
- '''Read the VMAD Weight values.'''
+ """Read the VMAD Weight values."""
chunk_len= len(ew_bytes)
offset= 2
name, name_len= read_lwostring(ew_bytes[offset:])
@@ -639,7 +639,7 @@ def read_weight_vmad(ew_bytes, object_layers):
def read_pols(pol_bytes, object_layers):
- '''Read the layer's polygons, each one is just a list of point indexes.'''
+ """Read the layer's polygons, each one is just a list of point indexes."""
print("\tReading Layer ("+object_layers[-1].name+") Polygons")
offset= 0
pols_count = len(pol_bytes)
@@ -660,10 +660,10 @@ def read_pols(pol_bytes, object_layers):
def read_pols_5(pol_bytes, object_layers):
- '''
+ """
Read the polygons, each one is just a list of point indexes.
But it also includes the surface index.
- '''
+ """
print("\tReading Layer ("+object_layers[-1].name+") Polygons")
offset= 0
chunk_len= len(pol_bytes)
@@ -692,7 +692,7 @@ def read_pols_5(pol_bytes, object_layers):
def read_bones(bone_bytes, object_layers):
- '''Read the layer's skelegons.'''
+ """Read the layer's skelegons."""
print("\tReading Layer ("+object_layers[-1].name+") Bones")
offset= 0
bones_count = len(bone_bytes)
@@ -710,7 +710,7 @@ def read_bones(bone_bytes, object_layers):
def read_bone_tags(tag_bytes, object_layers, object_tags, type):
- '''Read the bone name or roll tags.'''
+ """Read the bone name or roll tags."""
offset= 0
chunk_len= len(tag_bytes)
@@ -730,7 +730,7 @@ def read_bone_tags(tag_bytes, object_layers, object_tags, type):
def read_surf_tags(tag_bytes, object_layers, last_pols_count):
- '''Read the list of PolyIDs and tag indexes.'''
+ """Read the list of PolyIDs and tag indexes."""
print("\tReading Layer ("+object_layers[-1].name+") Surface Assignments")
offset= 0
chunk_len= len(tag_bytes)
@@ -748,7 +748,7 @@ def read_surf_tags(tag_bytes, object_layers, last_pols_count):
def read_surf(surf_bytes, object_surfs):
- '''Read the object's surface data.'''
+ """Read the object's surface data."""
if len(object_surfs) == 0:
print("Reading Object Surfaces")
@@ -816,7 +816,7 @@ def read_surf(surf_bytes, object_surfs):
def read_surf_5(surf_bytes, object_surfs):
- '''Read the object's surface data.'''
+ """Read the object's surface data."""
if len(object_surfs) == 0:
print("Reading Object Surfaces")
@@ -875,7 +875,7 @@ def read_surf_5(surf_bytes, object_surfs):
def create_mappack(data, map_name, map_type):
- '''Match the map data to faces.'''
+ """Match the map data to faces."""
pack= {}
def color_pointmap(map):
@@ -943,7 +943,7 @@ def create_mappack(data, map_name, map_type):
def build_armature(layer_data, bones):
- '''Build an armature from the skelegon data in the mesh.'''
+ """Build an armature from the skelegon data in the mesh."""
print("Building Armature")
# New Armatures include a default bone, remove it.
@@ -980,7 +980,7 @@ def build_armature(layer_data, bones):
def build_objects(object_layers, object_surfs, object_tags, object_name, add_subd_mod, skel_to_arm):
- '''Using the gathered data, create the objects.'''
+ """Using the gathered data, create the objects."""
ob_dict= {} # Used for the parenting setup.
print("Adding %d Materials" % len(object_surfs))
@@ -1214,7 +1214,7 @@ from bpy.props import StringProperty, BoolProperty
class IMPORT_OT_lwo(bpy.types.Operator):
- '''Import LWO Operator.'''
+ """Import LWO Operator"""
bl_idname= "import_scene.lwo"
bl_label= "Import LWO"
bl_description= "Import a LightWave Object file"
diff --git a/io_import_scene_mhx.py b/io_import_scene_mhx.py
index e56f7f63..497d698d 100644
--- a/io_import_scene_mhx.py
+++ b/io_import_scene_mhx.py
@@ -2896,7 +2896,7 @@ MhxBoolProps = [
]
class ImportMhx(bpy.types.Operator, ImportHelper):
- '''Import from MHX file format (.mhx)'''
+ """Import from MHX file format (.mhx)"""
bl_idname = "import_scene.makehuman_mhx"
bl_description = 'Import from MHX file format (.mhx)'
bl_label = "Import MHX"
diff --git a/io_import_scene_unreal_psk.py b/io_import_scene_unreal_psk.py
index 4bb0f3e6..96784b1d 100644
--- a/io_import_scene_unreal_psk.py
+++ b/io_import_scene_unreal_psk.py
@@ -585,7 +585,7 @@ def getInputFilename(self,filename,importmesh,importbone,bDebugLogPSK,importmult
pskimport(filename,importmesh,importbone,bDebugLogPSK,importmultiuvtextures)
#import panel
class IMPORT_OT_psk(bpy.types.Operator):
- '''Load a skeleton mesh psk File'''
+ """Load a skeleton mesh psk File"""
bl_idname = "import_scene.psk"
bl_label = "Import PSK"
bl_space_type = "PROPERTIES"
diff --git a/io_mesh_ply/__init__.py b/io_mesh_ply/__init__.py
index a233b680..c9bb5318 100644
--- a/io_mesh_ply/__init__.py
+++ b/io_mesh_ply/__init__.py
@@ -51,7 +51,7 @@ from bpy_extras.io_utils import ImportHelper, ExportHelper
class ImportPLY(bpy.types.Operator, ImportHelper):
- '''Load a PLY geometry file'''
+ """Load a PLY geometry file"""
bl_idname = "import_mesh.ply"
bl_label = "Import PLY"
bl_options = {'UNDO'}
@@ -81,8 +81,8 @@ class ImportPLY(bpy.types.Operator, ImportHelper):
class ExportPLY(bpy.types.Operator, ExportHelper):
- '''Export a single object as a stanford PLY with normals, ''' \
- '''colours and texture coordinates'''
+ """Export a single object as a stanford PLY with normals, """ \
+ """colours and texture coordinates"""
bl_idname = "export_mesh.ply"
bl_label = "Export PLY"
diff --git a/io_mesh_raw/__init__.py b/io_mesh_raw/__init__.py
index 464d0b49..61c21529 100644
--- a/io_mesh_raw/__init__.py
+++ b/io_mesh_raw/__init__.py
@@ -47,7 +47,7 @@ from bpy_extras.io_utils import ExportHelper
class RawImporter(bpy.types.Operator):
- '''Load Raw triangle mesh data'''
+ """Load Raw triangle mesh data"""
bl_idname = "import_mesh.raw"
bl_label = "Import RAW"
bl_options = {'UNDO'}
@@ -69,7 +69,7 @@ class RawImporter(bpy.types.Operator):
class RawExporter(bpy.types.Operator, ExportHelper):
- '''Save Raw triangle mesh data'''
+ """Save Raw triangle mesh data"""
bl_idname = "export_mesh.raw"
bl_label = "Export RAW"
diff --git a/io_mesh_stl/__init__.py b/io_mesh_stl/__init__.py
index 9df62d1c..1088490a 100644
--- a/io_mesh_stl/__init__.py
+++ b/io_mesh_stl/__init__.py
@@ -64,7 +64,7 @@ from bpy.types import Operator, OperatorFileListElement
class ImportSTL(Operator, ImportHelper):
- '''Load STL triangle mesh data'''
+ """Load STL triangle mesh data"""
bl_idname = "import_mesh.stl"
bl_label = "Import STL"
bl_options = {'UNDO'}
@@ -108,7 +108,7 @@ class ImportSTL(Operator, ImportHelper):
class ExportSTL(Operator, ExportHelper):
- '''Save STL triangle mesh data from the active object'''
+ """Save STL triangle mesh data from the active object"""
bl_idname = "export_mesh.stl"
bl_label = "Export STL"
diff --git a/io_mesh_stl/blender_utils.py b/io_mesh_stl/blender_utils.py
index 76c864cd..1d24369e 100644
--- a/io_mesh_stl/blender_utils.py
+++ b/io_mesh_stl/blender_utils.py
@@ -22,10 +22,10 @@ import bpy
def create_and_link_mesh(name, faces, points):
- '''
+ """
Create a blender mesh and object called name from a list of
*points* and *faces* and link it in the current scene.
- '''
+ """
mesh = bpy.data.meshes.new(name)
mesh.from_pydata(points, [], faces)
@@ -42,7 +42,7 @@ def create_and_link_mesh(name, faces, points):
def faces_from_mesh(ob, apply_modifier=False, triangulate=True):
- '''
+ """
From an object, return a generator over a list of faces.
Each faces is a list of his vertexes. Each vertex is a tuple of
@@ -53,7 +53,7 @@ def faces_from_mesh(ob, apply_modifier=False, triangulate=True):
triangulate
Split the quad into two triangles
- '''
+ """
# get the modifiers
try:
diff --git a/io_mesh_stl/stl_utils.py b/io_mesh_stl/stl_utils.py
index be4dc0a6..ded7d2c6 100644
--- a/io_mesh_stl/stl_utils.py
+++ b/io_mesh_stl/stl_utils.py
@@ -18,13 +18,13 @@
# <pep8 compliant>
-'''
+"""
Import and export STL files
Used as a blender script, it load all the stl files in the scene:
blender --python stl_utils.py -- file1.stl file2.stl file3.stl ...
-'''
+"""
import struct
import mmap
@@ -36,7 +36,7 @@ import itertools
@contextlib.contextmanager
def mmap_file(filename):
- '''
+ """
Context manager over the data of an mmap'ed file (Read ONLY).
@@ -45,7 +45,7 @@ def mmap_file(filename):
with mmap_file(filename) as m:
m.read()
print m[10:50]
- '''
+ """
with open(filename, 'rb') as file:
# check http://bugs.python.org/issue8046 to have mmap context
# manager fixed in python
@@ -55,7 +55,7 @@ def mmap_file(filename):
class ListDict(dict):
- '''
+ """
Set struct with order.
You can:
@@ -64,7 +64,7 @@ class ListDict(dict):
Like collections.OrderedDict, but quicker, can be replaced if
ODict is optimised.
- '''
+ """
def __init__(self):
dict.__init__(self)
@@ -72,9 +72,9 @@ class ListDict(dict):
self._len = 0
def add(self, item):
- '''
+ """
Add a value to the Set, return its position in it.
- '''
+ """
value = self.setdefault(item, self._len)
if value == self._len:
self.list.append(item)
@@ -92,13 +92,13 @@ def _header_version():
def _is_ascii_file(data):
- '''
+ """
This function returns True if the data represents an ASCII file.
Please note that a False value does not necessary means that the data
represents a binary file. It can be a (very *RARE* in real life, but
can easily be forged) ascii file.
- '''
+ """
size = struct.unpack_from('<I', data, BINARY_HEADER)[0]
return not data.size() == BINARY_HEADER + 4 + BINARY_STRIDE * size
@@ -199,7 +199,7 @@ def _ascii_write(filename, faces):
def write_stl(filename, faces, ascii=False):
- '''
+ """
Write a stl file from faces,
filename
@@ -210,12 +210,12 @@ def write_stl(filename, faces, ascii=False):
ascii
save the file in ascii format (very huge)
- '''
+ """
(_ascii_write if ascii else _binary_write)(filename, faces)
def read_stl(filename):
- '''
+ """
Return the triangles and points of an stl binary file.
Please note that this process can take lot of time if the file is
@@ -238,7 +238,7 @@ def read_stl(filename):
>>>
>>> # print the coordinate of the triangle n
>>> print(pts[i] for i in tris[n])
- '''
+ """
tris, pts = [], ListDict()
diff --git a/io_scene_3ds/__init__.py b/io_scene_3ds/__init__.py
index 9ac41168..aba53bdd 100644
--- a/io_scene_3ds/__init__.py
+++ b/io_scene_3ds/__init__.py
@@ -50,7 +50,7 @@ from bpy_extras.io_utils import (ImportHelper,
class Import3DS(bpy.types.Operator, ImportHelper):
- '''Import from 3DS file format (.3ds)'''
+ """Import from 3DS file format (.3ds)"""
bl_idname = "import_scene.autodesk_3ds"
bl_label = 'Import 3DS'
bl_options = {'UNDO'}
@@ -120,7 +120,7 @@ class Import3DS(bpy.types.Operator, ImportHelper):
class Export3DS(bpy.types.Operator, ExportHelper):
- '''Export to 3DS file format (.3ds)'''
+ """Export to 3DS file format (.3ds)"""
bl_idname = "export_scene.autodesk_3ds"
bl_label = 'Export 3DS'
diff --git a/io_scene_3ds/export_3ds.py b/io_scene_3ds/export_3ds.py
index 40fdeda3..1856659b 100644
--- a/io_scene_3ds/export_3ds.py
+++ b/io_scene_3ds/export_3ds.py
@@ -135,8 +135,8 @@ SZ_FLOAT = 4
class _3ds_ushort(object):
- '''Class representing a short (2-byte integer) for a 3ds file.
- *** This looks like an unsigned short H is unsigned from the struct docs - Cam***'''
+ """Class representing a short (2-byte integer) for a 3ds file.
+ *** This looks like an unsigned short H is unsigned from the struct docs - Cam***"""
__slots__ = ("value", )
def __init__(self, val=0):
@@ -153,7 +153,7 @@ class _3ds_ushort(object):
class _3ds_uint(object):
- '''Class representing an int (4-byte integer) for a 3ds file.'''
+ """Class representing an int (4-byte integer) for a 3ds file."""
__slots__ = ("value", )
def __init__(self, val):
@@ -170,7 +170,7 @@ class _3ds_uint(object):
class _3ds_float(object):
- '''Class representing a 4-byte IEEE floating point number for a 3ds file.'''
+ """Class representing a 4-byte IEEE floating point number for a 3ds file."""
__slots__ = ("value", )
def __init__(self, val):
@@ -187,7 +187,7 @@ class _3ds_float(object):
class _3ds_string(object):
- '''Class representing a zero-terminated string for a 3ds file.'''
+ """Class representing a zero-terminated string for a 3ds file."""
__slots__ = ("value", )
def __init__(self, val):
@@ -206,7 +206,7 @@ class _3ds_string(object):
class _3ds_point_3d(object):
- '''Class representing a three-dimensional point for a 3ds file.'''
+ """Class representing a three-dimensional point for a 3ds file."""
__slots__ = "x", "y", "z"
def __init__(self, point):
@@ -224,7 +224,7 @@ class _3ds_point_3d(object):
# Used for writing a track
"""
class _3ds_point_4d(object):
- '''Class representing a four-dimensional point for a 3ds file, for instance a quaternion.'''
+ """Class representing a four-dimensional point for a 3ds file, for instance a quaternion."""
__slots__ = "x","y","z","w"
def __init__(self, point=(0.0,0.0,0.0,0.0)):
self.x, self.y, self.z, self.w = point
@@ -242,7 +242,7 @@ class _3ds_point_4d(object):
class _3ds_point_uv(object):
- '''Class representing a UV-coordinate for a 3ds file.'''
+ """Class representing a UV-coordinate for a 3ds file."""
__slots__ = ("uv", )
def __init__(self, point):
@@ -260,7 +260,7 @@ class _3ds_point_uv(object):
class _3ds_rgb_color(object):
- '''Class representing a (24-bit) rgb color for a 3ds file.'''
+ """Class representing a (24-bit) rgb color for a 3ds file."""
__slots__ = "r", "g", "b"
def __init__(self, col):
@@ -277,7 +277,7 @@ class _3ds_rgb_color(object):
class _3ds_face(object):
- '''Class representing a face for a 3ds file.'''
+ """Class representing a face for a 3ds file."""
__slots__ = ("vindex", )
def __init__(self, vindex):
@@ -298,10 +298,10 @@ class _3ds_face(object):
class _3ds_array(object):
- '''Class representing an array of variables for a 3ds file.
+ """Class representing an array of variables for a 3ds file.
Consists of a _3ds_ushort to indicate the number of items, followed by the items themselves.
- '''
+ """
__slots__ = "values", "size"
def __init__(self):
@@ -331,7 +331,7 @@ class _3ds_array(object):
class _3ds_named_variable(object):
- '''Convenience class for named variables.'''
+ """Convenience class for named variables."""
__slots__ = "value", "name"
@@ -359,10 +359,10 @@ class _3ds_named_variable(object):
#the chunk class
class _3ds_chunk(object):
- '''Class representing a chunk in a 3ds file.
+ """Class representing a chunk in a 3ds file.
Chunks contain zero or more variables, followed by zero or more subchunks.
- '''
+ """
__slots__ = "ID", "size", "variables", "subchunks"
def __init__(self, chunk_id=0):
@@ -372,19 +372,19 @@ class _3ds_chunk(object):
self.subchunks = []
def add_variable(self, name, var):
- '''Add a named variable.
+ """Add a named variable.
- The name is mostly for debugging purposes.'''
+ The name is mostly for debugging purposes."""
self.variables.append(_3ds_named_variable(name, var))
def add_subchunk(self, chunk):
- '''Add a subchunk.'''
+ """Add a subchunk."""
self.subchunks.append(chunk)
def get_size(self):
- '''Calculate the size of the chunk and return it.
+ """Calculate the size of the chunk and return it.
- The sizes of the variables and subchunks are used to determine this chunk\'s size.'''
+ The sizes of the variables and subchunks are used to determine this chunk\'s size."""
tmpsize = self.ID.get_size() + self.size.get_size()
for variable in self.variables:
tmpsize += variable.get_size()
@@ -407,9 +407,9 @@ class _3ds_chunk(object):
return True
def write(self, file):
- '''Write the chunk to a file.
+ """Write the chunk to a file.
- Uses the write function of the variables and the subchunks to do the actual work.'''
+ Uses the write function of the variables and the subchunks to do the actual work."""
#write header
self.ID.write(file)
self.size.write(file)
@@ -419,10 +419,10 @@ class _3ds_chunk(object):
subchunk.write(file)
def dump(self, indent=0):
- '''Write the chunk to a file.
+ """Write the chunk to a file.
Dump is used for debugging purposes, to dump the contents of a chunk to the standard output.
- Uses the dump function of the named variables and the subchunks to do the actual work.'''
+ Uses the dump function of the named variables and the subchunks to do the actual work."""
print(indent * " ",
"ID=%r" % hex(self.ID.value),
"size=%r" % self.get_size())
@@ -453,9 +453,9 @@ def get_material_image_texslots(material):
def make_material_subchunk(chunk_id, color):
- '''Make a material subchunk.
+ """Make a material subchunk.
- Used for color subchunks, such as diffuse color or ambient color subchunks.'''
+ Used for color subchunks, such as diffuse color or ambient color subchunks."""
mat_sub = _3ds_chunk(chunk_id)
col1 = _3ds_chunk(RGB1)
col1.add_variable("color1", _3ds_rgb_color(color))
@@ -540,7 +540,7 @@ def make_material_texture_chunk(chunk_id, texslots, tess_uv_image=None):
def make_material_chunk(material, image):
- '''Make a material chunk out of a blender material.'''
+ """Make a material chunk out of a blender material."""
material_chunk = _3ds_chunk(MATERIAL)
name = _3ds_chunk(MATNAME)
@@ -601,9 +601,9 @@ def make_material_chunk(material, image):
class tri_wrapper(object):
- '''Class representing a triangle.
+ """Class representing a triangle.
- Used when converting faces to triangles'''
+ Used when converting faces to triangles"""
__slots__ = "vertex_index", "mat", "image", "faceuvs", "offset"
@@ -616,9 +616,9 @@ class tri_wrapper(object):
def extract_triangles(mesh):
- '''Extract triangles from a mesh.
+ """Extract triangles from a mesh.
- If the mesh contains quads, they will be split into triangles.'''
+ If the mesh contains quads, they will be split into triangles."""
tri_list = []
do_uv = bool(mesh.tessface_uv_textures)
@@ -656,11 +656,11 @@ def extract_triangles(mesh):
def remove_face_uv(verts, tri_list):
- '''Remove face UV coordinates from a list of triangles.
+ """Remove face UV coordinates from a list of triangles.
Since 3ds files only support one pair of uv coordinates for each vertex, face uv coordinates
need to be converted to vertex uv coordinates. That means that vertices need to be duplicated when
- there are multiple uv coordinates per vertex.'''
+ there are multiple uv coordinates per vertex."""
# initialize a list of UniqueLists, one per vertex:
#uv_list = [UniqueList() for i in xrange(len(verts))]
@@ -722,9 +722,9 @@ def remove_face_uv(verts, tri_list):
def make_faces_chunk(tri_list, mesh, materialDict):
- '''Make a chunk for the faces.
+ """Make a chunk for the faces.
- Also adds subchunks assigning materials to all faces.'''
+ Also adds subchunks assigning materials to all faces."""
materials = mesh.materials
if not materials:
@@ -793,14 +793,14 @@ def make_faces_chunk(tri_list, mesh, materialDict):
def make_vert_chunk(vert_array):
- '''Make a vertex chunk out of an array of vertices.'''
+ """Make a vertex chunk out of an array of vertices."""
vert_chunk = _3ds_chunk(OBJECT_VERTICES)
vert_chunk.add_variable("vertices", vert_array)
return vert_chunk
def make_uv_chunk(uv_array):
- '''Make a UV chunk out of an array of UVs.'''
+ """Make a UV chunk out of an array of UVs."""
uv_chunk = _3ds_chunk(OBJECT_UV)
uv_chunk.add_variable("uv coords", uv_array)
return uv_chunk
@@ -815,7 +815,7 @@ def make_matrix_4x3_chunk(matrix):
def make_mesh_chunk(mesh, matrix, materialDict):
- '''Make a chunk out of a Blender mesh.'''
+ """Make a chunk out of a Blender mesh."""
# Extract the triangles from the mesh:
tri_list = extract_triangles(mesh)
@@ -857,7 +857,7 @@ def make_mesh_chunk(mesh, matrix, materialDict):
""" # COMMENTED OUT FOR 2.42 RELEASE!! CRASHES 3DS MAX
def make_kfdata(start=0, stop=0, curtime=0):
- '''Make the basic keyframe data chunk'''
+ """Make the basic keyframe data chunk"""
kfdata = _3ds_chunk(KFDATA)
kfhdr = _3ds_chunk(KFDATA_KFHDR)
@@ -882,9 +882,9 @@ def make_kfdata(start=0, stop=0, curtime=0):
"""
def make_track_chunk(ID, obj):
- '''Make a chunk for track data.
+ """Make a chunk for track data.
- Depending on the ID, this will construct a position, rotation or scale track.'''
+ Depending on the ID, this will construct a position, rotation or scale track."""
track_chunk = _3ds_chunk(ID)
track_chunk.add_variable("track_flags", _3ds_ushort())
track_chunk.add_variable("unknown", _3ds_uint())
@@ -922,10 +922,10 @@ def make_track_chunk(ID, obj):
"""
def make_kf_obj_node(obj, name_to_id):
- '''Make a node chunk for a Blender object.
+ """Make a node chunk for a Blender object.
Takes the Blender object as a parameter. Object id's are taken from the dictionary name_to_id.
- Blender Empty objects are converted to dummy nodes.'''
+ Blender Empty objects are converted to dummy nodes."""
name = obj.name
# main object node chunk:
@@ -995,7 +995,7 @@ def save(operator,
import time
from bpy_extras.io_utils import create_derived_objects, free_derived_objects
- '''Save the Blender scene to a 3ds file.'''
+ """Save the Blender scene to a 3ds file."""
# Time the export
time1 = time.clock()
diff --git a/io_scene_3ds/import_3ds.py b/io_scene_3ds/import_3ds.py
index 77fdcf70..09dddb52 100644
--- a/io_scene_3ds/import_3ds.py
+++ b/io_scene_3ds/import_3ds.py
@@ -608,9 +608,9 @@ def process_next_chunk(file, previous_chunk, importedObjects, IMAGE_SEARCH):
# print 'Found an OBJECT_MESH chunk'
pass
elif new_chunk.ID == OBJECT_VERTICES:
- '''
+ """
Worldspace vertex locations
- '''
+ """
# print 'elif new_chunk.ID == OBJECT_VERTICES:'
temp_data = file.read(STRUCT_SIZE_UNSIGNED_SHORT)
num_verts = struct.unpack('<H', temp_data)[0]
diff --git a/io_scene_fbx/__init__.py b/io_scene_fbx/__init__.py
index 5712e3f2..23792f0e 100644
--- a/io_scene_fbx/__init__.py
+++ b/io_scene_fbx/__init__.py
@@ -53,7 +53,7 @@ from bpy_extras.io_utils import (ExportHelper,
class ExportFBX(bpy.types.Operator, ExportHelper):
- '''Selection to an ASCII Autodesk FBX'''
+ """Selection to an ASCII Autodesk FBX"""
bl_idname = "export_scene.fbx"
bl_label = "Export FBX"
bl_options = {'PRESET'}
diff --git a/io_scene_fbx/export_fbx.py b/io_scene_fbx/export_fbx.py
index 73e1b195..f02e7183 100644
--- a/io_scene_fbx/export_fbx.py
+++ b/io_scene_fbx/export_fbx.py
@@ -158,10 +158,10 @@ def action_bone_names(obj, action):
# ob must be OB_MESH
def BPyMesh_meshWeight2List(ob, me):
- ''' Takes a mesh and return its group names and a list of lists, one list per vertex.
+ """ Takes a mesh and return its group names and a list of lists, one list per vertex.
aligning the each vert list with the group names, each list contains float value for the weight.
These 2 lists can be modified and then used with list2MeshWeight to apply the changes.
- '''
+ """
# Clear the vert group.
groupNames = [g.name for g in ob.vertex_groups]
@@ -464,9 +464,9 @@ def save_single(operator, scene, filepath="",
# --------------- funcs for exporting
def object_tx(ob, loc, matrix, matrix_mod=None):
- '''
+ """
Matrix mod is so armature objects can modify their bone matrices
- '''
+ """
if isinstance(ob, bpy.types.Bone):
# we know we have a matrix
@@ -524,11 +524,11 @@ def save_single(operator, scene, filepath="",
return loc, rot, scale, matrix, matrix_rot
def write_object_tx(ob, loc, matrix, matrix_mod=None):
- '''
+ """
We have loc to set the location if non blender objects that have a location
matrix_mod is only used for bones at the moment
- '''
+ """
loc, rot, scale, matrix, matrix_rot = object_tx(ob, loc, matrix, matrix_mod)
fw('\n\t\t\tProperty: "Lcl Translation", "Lcl Translation", "A+",%.15f,%.15f,%.15f' % loc)
@@ -850,9 +850,9 @@ def save_single(operator, scene, filepath="",
write_camera_dummy('Producer Left', (-4000, 0, 0), 1, 30000, 1, (0, 1, 0))
def write_camera(my_cam):
- '''
+ """
Write a blender camera
- '''
+ """
render = scene.render
width = render.resolution_x
height = render.resolution_y
@@ -897,14 +897,14 @@ def save_single(operator, scene, filepath="",
fw('\n\t\t\tProperty: "AspectW", "double", "",%i' % width)
fw('\n\t\t\tProperty: "AspectH", "double", "",%i' % height)
- '''Camera aspect ratio modes.
+ """Camera aspect ratio modes.
0 If the ratio mode is eWINDOW_SIZE, both width and height values aren't relevant.
1 If the ratio mode is eFIXED_RATIO, the height value is set to 1.0 and the width value is relative to the height value.
2 If the ratio mode is eFIXED_RESOLUTION, both width and height values are in pixels.
3 If the ratio mode is eFIXED_WIDTH, the width value is in pixels and the height value is relative to the width value.
4 If the ratio mode is eFIXED_HEIGHT, the height value is in pixels and the width value is relative to the height value.
- Definition at line 234 of file kfbxcamera.h. '''
+ Definition at line 234 of file kfbxcamera.h. """
fw('\n\t\t\tProperty: "PixelAspectRatio", "double", "",1'
'\n\t\t\tProperty: "UseFrameColor", "bool", "",0'
@@ -1253,9 +1253,9 @@ def save_single(operator, scene, filepath="",
}''')
def write_deformer_skin(obname):
- '''
+ """
Each mesh has its own deformer
- '''
+ """
fw('\n\tDeformer: "Deformer::Skin %s", "Skin" {' % obname)
fw('''
Version: 100
@@ -1269,13 +1269,13 @@ def save_single(operator, scene, filepath="",
# in the example was 'Bip01 L Thigh_2'
def write_sub_deformer_skin(my_mesh, my_bone, weights):
- '''
+ """
Each subdeformer is specific to a mesh, but the bone it links to can be used by many sub-deformers
So the SubDeformer needs the mesh-object name as a prefix to make it unique
Its possible that there is no matching vgroup in this mesh, in that case no verts are in the subdeformer,
a but silly but dosnt really matter
- '''
+ """
fw('\n\tDeformer: "SubDeformer::Cluster %s %s", "Cluster" {' % (my_mesh.fbxName, my_bone.fbxName))
fw('''
diff --git a/io_scene_m3/__init__.py b/io_scene_m3/__init__.py
index a3a1d62d..d50ca8a1 100644
--- a/io_scene_m3/__init__.py
+++ b/io_scene_m3/__init__.py
@@ -50,7 +50,7 @@ from bpy_extras.io_utils import ImportHelper
class ImportM3(bpy.types.Operator, ImportHelper):
- '''Import from M3 file format (.m3)'''
+ """Import from M3 file format (.m3)"""
bl_idname = 'import_scene.blizzard_m3'
bl_label = 'Import M3'
bl_options = {'UNDO'}
diff --git a/io_scene_m3/import_m3.py b/io_scene_m3/import_m3.py
index b50562ef..f22a089c 100644
--- a/io_scene_m3/import_m3.py
+++ b/io_scene_m3/import_m3.py
@@ -338,7 +338,7 @@ def read(file, context, op):
class M3Importer(bpy.types.Operator):
- '''Import from M3 file format (.m3)'''
+ """Import from M3 file format (.m3)"""
bl_idname = "import_mesh.blizzard_m3"
bl_label = 'Import M3'
bl_options = {'UNDO'}
diff --git a/io_scene_map/__init__.py b/io_scene_map/__init__.py
index 8c7ee394..c1b77772 100644
--- a/io_scene_map/__init__.py
+++ b/io_scene_map/__init__.py
@@ -45,7 +45,7 @@ from bpy_extras.io_utils import ExportHelper
class ExportMAP(bpy.types.Operator, ExportHelper):
- '''Export selection to a quake map'''
+ """Export selection to a quake map"""
bl_idname = "export_scene.quake_map"
bl_label = "Export MAP"
bl_options = {'PRESET'}
diff --git a/io_scene_map/export_map.py b/io_scene_map/export_map.py
index 2d11aad1..2b407980 100644
--- a/io_scene_map/export_map.py
+++ b/io_scene_map/export_map.py
@@ -53,11 +53,11 @@ def face_material_get(face):
def write_cube2brush(file, faces):
- '''
+ """
Takes 6 faces and writes a brush,
these faces can be from 1 mesh, 1 cube within a mesh of larger cubes
Faces could even come from different meshes or be contrived.
- '''
+ """
# comment only
# file.write('// brush "%s", "%s"\n' % (ob.name, ob.data.name))
file.write('// brush from cube\n{\n')
@@ -102,10 +102,10 @@ def round_vec(v):
def write_face2brush(file, face):
- '''
+ """
takes a face and writes it as a brush
each face is a cube/brush
- '''
+ """
if PREF_GRID_SNAP:
format_vec = '( %d %d %d ) '
@@ -173,9 +173,9 @@ def write_face2brush(file, face):
def is_cube_facegroup(faces):
- '''
- Returens a bool, true if the faces make up a cube
- '''
+ """
+ Returns a bool, true if the faces make up a cube
+ """
# cube must have 6 faces
if len(faces) != 6:
# print('1')
@@ -209,10 +209,10 @@ def is_cube_facegroup(faces):
def is_tricyl_facegroup(faces):
- '''
+ """
is the face group a tri cylinder
- Returens a bool, true if the faces make an extruded tri solid
- '''
+ Returns a bool, true if the faces make an extruded tri solid
+ """
# cube must have 5 faces
if len(faces) != 5:
@@ -246,11 +246,11 @@ def is_tricyl_facegroup(faces):
def write_node_map(file, ob):
- '''
+ """
Writes the properties of an object (empty in this case)
as a MAP node as long as it has the property name - classname
returns True/False based on weather a node was written
- '''
+ """
props = [(p.name, p.value) for p in ob.game.properties]
IS_MAP_NODE = False
diff --git a/io_scene_obj/__init__.py b/io_scene_obj/__init__.py
index b7def44f..56e6b699 100644
--- a/io_scene_obj/__init__.py
+++ b/io_scene_obj/__init__.py
@@ -54,7 +54,7 @@ from bpy_extras.io_utils import (ExportHelper,
class ImportOBJ(bpy.types.Operator, ImportHelper):
- '''Load a Wavefront OBJ File'''
+ """Load a Wavefront OBJ File"""
bl_idname = "import_scene.obj"
bl_label = "Import OBJ"
bl_options = {'PRESET', 'UNDO'}
@@ -196,7 +196,7 @@ class ImportOBJ(bpy.types.Operator, ImportHelper):
class ExportOBJ(bpy.types.Operator, ExportHelper):
- '''Save a Wavefront OBJ File'''
+ """Save a Wavefront OBJ File"""
bl_idname = "export_scene.obj"
bl_label = 'Export OBJ'
diff --git a/io_scene_obj/export_obj.py b/io_scene_obj/export_obj.py
index 99bd2f5d..01708090 100644
--- a/io_scene_obj/export_obj.py
+++ b/io_scene_obj/export_obj.py
@@ -229,12 +229,12 @@ def write_file(filepath, objects, scene,
EXPORT_GLOBAL_MATRIX=None,
EXPORT_PATH_MODE='AUTO',
):
- '''
+ """
Basic write function. The context and options must be already set
This can be accessed externaly
eg.
write( 'c:\\test\\foobar.obj', Blender.Object.GetSelected() ) # Using default options.
- '''
+ """
if EXPORT_GLOBAL_MATRIX is None:
EXPORT_GLOBAL_MATRIX = mathutils.Matrix()
@@ -684,11 +684,11 @@ def _write(context, filepath,
# Window.WaitCursor(0)
-'''
+"""
Currently the exporter lacks these features:
* multiple scene export (only active scene is written)
* particles
-'''
+"""
def save(operator, context, filepath="",
diff --git a/io_scene_obj/import_obj.py b/io_scene_obj/import_obj.py
index 23e28913..66a76c18 100644
--- a/io_scene_obj/import_obj.py
+++ b/io_scene_obj/import_obj.py
@@ -40,10 +40,10 @@ from bpy_extras.image_utils import load_image
def line_value(line_split):
- '''
+ """
Returns 1 string represneting the value for this line
None will be returned if theres only 1 word
- '''
+ """
length = len(line_split)
if length == 1:
return None
@@ -56,10 +56,10 @@ def line_value(line_split):
def obj_image_load(imagepath, DIR, recursive):
- '''
+ """
Mainly uses comprehensiveImageLoad
but tries to replace '_' with ' ' for Max's exporter replaces spaces with underscores.
- '''
+ """
if b'_' in imagepath:
image = load_image(imagepath.replace(b'_', b' '), DIR, recursive=recursive)
if image:
@@ -69,10 +69,10 @@ def obj_image_load(imagepath, DIR, recursive):
def create_materials(filepath, material_libs, unique_materials, unique_material_images, use_image_search):
- '''
+ """
Create all the used materials in this obj,
assign colors and images to the materials from all referenced material libs
- '''
+ """
DIR = os.path.dirname(filepath)
#==================================================================================#
@@ -349,10 +349,10 @@ def create_materials(filepath, material_libs, unique_materials, unique_material_
def split_mesh(verts_loc, faces, unique_materials, filepath, SPLIT_OB_OR_GROUP):
- '''
+ """
Takes vert_loc and faces, and separates into multiple sets of
(verts_loc, faces, unique_materials, dataname)
- '''
+ """
filename = os.path.splitext((os.path.basename(filepath)))[0]
@@ -424,10 +424,10 @@ def create_mesh(new_objects,
vertex_groups,
dataname,
):
- '''
+ """
Takes all the data gathered and generates a mesh, adding the new object to new_objects
deals with fgons, sharp edges and assigning materials
- '''
+ """
from bpy_extras.mesh_utils import ngon_tessellate
if not has_ngons:
@@ -705,9 +705,9 @@ def create_mesh(new_objects,
def create_nurbs(context_nurbs, vert_loc, new_objects):
- '''
+ """
Add nurbs object to blender, only support one type at the moment
- '''
+ """
deg = context_nurbs.get(b'deg', (3,))
curv_range = context_nurbs.get(b'curv_range')
curv_idx = context_nurbs.get(b'curv_idx', [])
@@ -788,10 +788,10 @@ def strip_slash(line_split):
def get_float_func(filepath):
- '''
+ """
find the float function for this obj file
- whether to replace commas or not
- '''
+ """
file = open(filepath, 'rb')
for line in file: # .readlines():
line = line.lstrip()
@@ -819,12 +819,12 @@ def load(operator, context, filepath,
use_groups_as_vgroups=False,
global_matrix=None,
):
- '''
+ """
Called by the user interface or another script.
load_obj(path) - should give acceptable results.
This function passes the file and sends the data off
to be split into objects and then converted into mesh objects
- '''
+ """
print('\nimporting obj %r' % filepath)
filepath = os.fsencode(filepath)
diff --git a/io_scene_x3d/__init__.py b/io_scene_x3d/__init__.py
index 21080b3f..8f188417 100644
--- a/io_scene_x3d/__init__.py
+++ b/io_scene_x3d/__init__.py
@@ -48,7 +48,7 @@ from bpy_extras.io_utils import (ImportHelper,
class ImportX3D(bpy.types.Operator, ImportHelper):
- '''Import an X3D or VRML2 file'''
+ """Import an X3D or VRML2 file"""
bl_idname = "import_scene.x3d"
bl_label = "Import X3D/VRML2"
bl_options = {'PRESET', 'UNDO'}
@@ -96,7 +96,7 @@ class ImportX3D(bpy.types.Operator, ImportHelper):
class ExportX3D(bpy.types.Operator, ExportHelper):
- '''Export selection to Extensible 3D file (.x3d)'''
+ """Export selection to Extensible 3D file (.x3d)"""
bl_idname = "export_scene.x3d"
bl_label = 'Export X3D'
bl_options = {'PRESET'}
diff --git a/io_scene_x3d/import_x3d.py b/io_scene_x3d/import_x3d.py
index 84f46fa2..896e4793 100644
--- a/io_scene_x3d/import_x3d.py
+++ b/io_scene_x3d/import_x3d.py
@@ -55,9 +55,9 @@ def imageConvertCompat(path):
# =============================== VRML Spesific
def vrmlFormat(data):
- '''
+ """
Keep this as a valid vrml file, but format in a way we can predict.
- '''
+ """
# Strip all commends - # not in strings - warning multiline strings are ignored.
def strip_comment(l):
#l = ' '.join(l.split())
@@ -270,9 +270,9 @@ def is_nodeline(i, words):
def is_numline(i):
- '''
+ """
Does this line start with a number?
- '''
+ """
# Works but too slow.
'''
@@ -490,7 +490,7 @@ class vrmlNode(object):
return child
def getSerialized(self, results, ancestry):
- ''' Return this node and all its children in a flat list '''
+ """ Return this node and all its children in a flat list """
ancestry = ancestry[:] # always use a copy
# self_real = self.getRealNode()
@@ -720,9 +720,9 @@ class vrmlNode(object):
return default
def getFieldAsArray(self, field, group, ancestry):
- '''
+ """
For this parser arrays are children
- '''
+ """
def array_as_number(array_string):
array_data = []
@@ -813,9 +813,9 @@ class vrmlNode(object):
return new_array
def getFieldAsStringArray(self, field, ancestry):
- '''
+ """
Get a list of strings
- '''
+ """
self_real = self.getRealNode() # in case we're an instance
child_array = None
@@ -1181,10 +1181,10 @@ class vrmlNode(object):
return False
def split_fields(value):
- '''
+ """
key 0.0 otherkey 1,2,3 opt1 opt1 0.0
-> [key 0.0], [otherkey 1,2,3], [opt1 opt1 0.0]
- '''
+ """
field_list = []
field_context = []
@@ -1243,10 +1243,10 @@ def gzipOpen(path):
def vrml_parse(path):
- '''
+ """
Sets up the root node and returns it so load_web3d() can deal with the blender side of things.
Return root (vrmlNode, '') or (None, 'Error String')
- '''
+ """
data = gzipOpen(path)
if data is None:
@@ -1358,10 +1358,10 @@ class x3dNode(vrmlNode):
def x3d_parse(path):
- '''
+ """
Sets up the root node and returns it so load_web3d() can deal with the blender side of things.
Return root (x3dNode, '') or (None, 'Error String')
- '''
+ """
try:
import xml.dom.minidom
@@ -1422,7 +1422,7 @@ GLOBALS = {'CIRCLE_DETAIL': 16}
def translateRotation(rot):
- ''' axis, angle '''
+ """ axis, angle """
return Matrix.Rotation(rot[3], 4, Vector(rot[:3]))
@@ -1707,14 +1707,14 @@ def importMesh_IndexedFaceSet(geom, bpyima, ancestry):
# we have to create VRML's coords as UVs instead.
# VRML docs
- '''
+ """
If the texCoord field is NULL, a default texture coordinate mapping is calculated using the local
coordinate system bounding box of the shape. The longest dimension of the bounding box defines the S coordinates,
and the next longest defines the T coordinates. If two or all three dimensions of the bounding box are equal,
ties shall be broken by choosing the X, Y, or Z dimension in that order of preference.
The value of the S coordinate ranges from 0 to 1, from one end of the bounding box to the other.
The T coordinate ranges between 0 and the ratio of the second greatest dimension of the bounding box to the greatest dimension.
- '''
+ """
# Note, S,T == U,V
# U gets longest, V gets second longest
@@ -2422,10 +2422,10 @@ def translateScalarInterpolator(node, action, ancestry):
def translateTimeSensor(node, action, ancestry):
- '''
+ """
Apply a time sensor to an action, VRML has many combinations of loop/start/stop/cycle times
to give different results, for now just do the basics
- '''
+ """
# XXX25 TODO
if 1:
@@ -2452,9 +2452,9 @@ def translateTimeSensor(node, action, ancestry):
def importRoute(node, ancestry):
- '''
+ """
Animation route only at the moment
- '''
+ """
if not hasattr(node, 'fields'):
return
@@ -2470,7 +2470,7 @@ def importRoute(node, ancestry):
# for getting definitions
defDict = node.getDefDict()
- '''
+ """
Handles routing nodes to eachother
ROUTE vpPI.value_changed TO champFly001.set_position
@@ -2478,7 +2478,7 @@ ROUTE vpOI.value_changed TO champFly001.set_orientation
ROUTE vpTs.fraction_changed TO vpPI.set_fraction
ROUTE vpTs.fraction_changed TO vpOI.set_fraction
ROUTE champFly001.bindTime TO vpTs.set_startTime
- '''
+ """
#from_id, from_type = node.id[1].split('.')
#to_id, to_type = node.id[3].split('.')
diff --git a/io_shape_mdd/__init__.py b/io_shape_mdd/__init__.py
index 44a1dfd2..b36bebc0 100644
--- a/io_shape_mdd/__init__.py
+++ b/io_shape_mdd/__init__.py
@@ -45,7 +45,7 @@ from bpy_extras.io_utils import ExportHelper, ImportHelper
class ImportMDD(bpy.types.Operator, ImportHelper):
- '''Import MDD vertex keyframe file to shape keys'''
+ """Import MDD vertex keyframe file to shape keys"""
bl_idname = "import_shape.mdd"
bl_label = "Import MDD"
bl_options = {'UNDO'}
@@ -87,7 +87,7 @@ class ImportMDD(bpy.types.Operator, ImportHelper):
class ExportMDD(bpy.types.Operator, ExportHelper):
- '''Animated mesh to MDD vertex keyframe file'''
+ """Animated mesh to MDD vertex keyframe file"""
bl_idname = "export_shape.mdd"
bl_label = "Export MDD"
diff --git a/io_shape_mdd/export_mdd.py b/io_shape_mdd/export_mdd.py
index 9b0ad8b6..d078083a 100644
--- a/io_shape_mdd/export_mdd.py
+++ b/io_shape_mdd/export_mdd.py
@@ -35,18 +35,18 @@ from struct import pack
def zero_file(filepath):
- '''
+ """
If a file fails, this replaces it with 1 char, better not remove it?
- '''
+ """
file = open(filepath, 'w')
file.write('\n') # apparently macosx needs some data in a blank file?
file.close()
def check_vertcount(mesh, vertcount):
- '''
+ """
check and make sure the vertcount is consistent throughout the frame range
- '''
+ """
if len(mesh.vertices) != vertcount:
raise Exception('Error, number of verts has changed during animation, cannot export')
diff --git a/mesh_relax.py b/mesh_relax.py
index 7e9aa4db..d168d051 100644
--- a/mesh_relax.py
+++ b/mesh_relax.py
@@ -92,7 +92,8 @@ def relax_mesh(context):
bpy.ops.object.mode_set(mode='EDIT')
class Relax(bpy.types.Operator):
- '''Relaxes selected vertices while retaining the shape as much as possible'''
+ """Relaxes selected vertices while retaining the shape """ \
+ """as much as possible"""
bl_idname = 'mesh.relax'
bl_label = 'Relax'
bl_options = {'REGISTER', 'UNDO'}
diff --git a/mocap/__init__.py b/mocap/__init__.py
index 197967e6..f754333f 100644
--- a/mocap/__init__.py
+++ b/mocap/__init__.py
@@ -431,7 +431,7 @@ class ExtraToolsPanel(bpy.types.Panel):
class OBJECT_OT_RetargetButton(bpy.types.Operator):
#Retargeting operator. Assumes selected and active armatures, where the performer (the selected one)
# has an action for retargeting
- '''Retarget animation from selected armature to active armature '''
+ """Retarget animation from selected armature to active armature"""
bl_idname = "mocap.retarget"
bl_label = "Retarget active action from Performer to Enduser"
bl_options = {'REGISTER', 'UNDO'}
@@ -469,7 +469,7 @@ class OBJECT_OT_RetargetButton(bpy.types.Operator):
class OBJECT_OT_SaveMappingButton(bpy.types.Operator):
#Operator for saving mapping to enduser armature
- '''Save mapping to active armature (for future retargets) '''
+ """Save mapping to active armature (for future retargets)"""
bl_idname = "mocap.savemapping"
bl_label = "Save user generated mapping from Performer to Enduser"
@@ -491,7 +491,7 @@ class OBJECT_OT_SaveMappingButton(bpy.types.Operator):
class OBJECT_OT_LoadMappingButton(bpy.types.Operator):
- '''Load saved mapping from active armature'''
+ """Load saved mapping from active armature"""
#Operator for loading mapping to enduser armature
bl_idname = "mocap.loadmapping"
bl_label = "Load user generated mapping from Performer to Enduser"
@@ -515,7 +515,7 @@ class OBJECT_OT_LoadMappingButton(bpy.types.Operator):
class OBJECT_OT_SelectMapBoneButton(bpy.types.Operator):
#Operator for setting selected bone in enduser armature to the performer mapping
- '''Select a bone for faster mapping'''
+ """Select a bone for faster mapping"""
bl_idname = "mocap.selectmap"
bl_label = "Select a bone for faster mapping"
perf_bone = StringProperty()
@@ -547,7 +547,7 @@ class OBJECT_OT_SelectMapBoneButton(bpy.types.Operator):
class OBJECT_OT_ConvertSamplesButton(bpy.types.Operator):
#Operator to convert samples to beziers on the selected object
- '''Convert active armature's sampled keyframed to beziers'''
+ """Convert active armature's sampled keyframed to beziers"""
bl_idname = "mocap.samples"
bl_label = "Convert samples / simplifies keyframes to beziers"
@@ -562,7 +562,8 @@ class OBJECT_OT_ConvertSamplesButton(bpy.types.Operator):
class OBJECT_OT_LooperButton(bpy.types.Operator):
#Operator to trim fcurves which contain a few loops to a single one on the selected object
- '''Trim active armature's animation to a single cycle, given a cyclic animation (such as a walk cycle)'''
+ """Trim active armature's animation to a single cycle, given """ \
+ """a cyclic animation (such as a walk cycle)"""
bl_idname = "mocap.looper"
bl_label = "Loop animation / sampled mocap data"
@@ -577,7 +578,8 @@ class OBJECT_OT_LooperButton(bpy.types.Operator):
class OBJECT_OT_DenoiseButton(bpy.types.Operator):
#Operator to denoise impluse noise on the active object's fcurves
- '''Denoise active armature's animation (good for dealing with 'bad' frames inherent in mocap animation)'''
+ """Denoise active armature's animation (good for dealing """ \
+ """with 'bad' frames inherent in mocap animation)"""
bl_idname = "mocap.denoise"
bl_label = "Denoise sampled mocap data"
@@ -592,7 +594,8 @@ class OBJECT_OT_DenoiseButton(bpy.types.Operator):
class OBJECT_OT_LimitDOFButton(bpy.types.Operator):
#Operator to analyze performer armature and apply rotation constraints on the enduser armature
- '''Create limit constraints on the active armature from the selected armature's animation's range of motion'''
+ """Create limit constraints on the active armature from """ \
+ """the selected armature's animation's range of motion"""
bl_idname = "mocap.limitdof"
bl_label = "Analyze animations Max/Min DOF and add hard/soft constraints"
@@ -614,7 +617,7 @@ class OBJECT_OT_LimitDOFButton(bpy.types.Operator):
class OBJECT_OT_RemoveLimitDOFButton(bpy.types.Operator):
#Removes constraints created by above operator
- '''Remove previously created limit constraints on the active armature'''
+ """Remove previously created limit constraints on the active armature"""
bl_idname = "mocap.removelimitdof"
bl_label = "Remove previously created limit constraints on the active armature"
@@ -632,7 +635,8 @@ class OBJECT_OT_RemoveLimitDOFButton(bpy.types.Operator):
class OBJECT_OT_RotateFixArmature(bpy.types.Operator):
#Operator to fix common imported Mocap data issue of wrong axis system on active object
- '''Realign the active armature's axis system to match Blender (commonly needed after bvh import)'''
+ """Realign the active armature's axis system to match Blender """ \
+ """(commonly needed after bvh import)"""
bl_idname = "mocap.rotate_fix"
bl_label = "Rotate selected armature 90 degrees (fix for bvh import)"
@@ -648,7 +652,8 @@ class OBJECT_OT_RotateFixArmature(bpy.types.Operator):
class OBJECT_OT_ScaleFixArmature(bpy.types.Operator):
#Operator to scale down the selected armature to match the active one
- '''Rescale selected armature to match the active animation, for convenience'''
+ """Rescale selected armature to match the active animation, """ \
+ """for convenience"""
bl_idname = "mocap.scale_fix"
bl_label = "Scale performer armature to match target armature"
@@ -671,7 +676,8 @@ class OBJECT_OT_ScaleFixArmature(bpy.types.Operator):
class MOCAP_OT_AddMocapFix(bpy.types.Operator):
#Operator to add a post-retarget fix
- '''Add a post-retarget fix - useful for fixing certain artifacts following the retarget'''
+ """Add a post-retarget fix - useful for fixing certain """ \
+ """artifacts following the retarget"""
bl_idname = "mocap.addmocapfix"
bl_label = "Add Mocap Fix to target armature"
type = EnumProperty(name="Type of Fix",
@@ -696,7 +702,7 @@ class MOCAP_OT_AddMocapFix(bpy.types.Operator):
class OBJECT_OT_RemoveMocapConstraint(bpy.types.Operator):
#Operator to remove a post-retarget fix
- '''Remove this post-retarget fix'''
+ """Remove this post-retarget fix"""
bl_idname = "mocap.removeconstraint"
bl_label = "Remove fixes from target armature"
constraint = IntProperty()
@@ -721,7 +727,7 @@ class OBJECT_OT_RemoveMocapConstraint(bpy.types.Operator):
class OBJECT_OT_BakeMocapConstraints(bpy.types.Operator):
#Operator to bake all post-retarget fixes
- '''Bake all post-retarget fixes to the Retarget Fixes NLA Track'''
+ """Bake all post-retarget fixes to the Retarget Fixes NLA Track"""
bl_idname = "mocap.bakeconstraints"
bl_label = "Bake all fixes to target armature"
@@ -737,7 +743,8 @@ class OBJECT_OT_BakeMocapConstraints(bpy.types.Operator):
class OBJECT_OT_UnbakeMocapConstraints(bpy.types.Operator):
#Operator to unbake all post-retarget fixes
- '''Unbake all post-retarget fixes - removes the baked data from the Retarget Fixes NLA Track'''
+ """Unbake all post-retarget fixes - removes the baked data """ \
+ """from the Retarget Fixes NLA Track"""
bl_idname = "mocap.unbakeconstraints"
bl_label = "Unbake all fixes to target armature"
@@ -754,7 +761,8 @@ class OBJECT_OT_UnbakeMocapConstraints(bpy.types.Operator):
class OBJECT_OT_UpdateMocapConstraints(bpy.types.Operator):
#Operator to update all post-retarget fixes, similar to update dependencies on drivers
#Needed because python properties lack certain callbacks and some fixes take a while to recalculate.
- '''Update all post-retarget fixes (neccesary to take under consideration changes to armature object or pose)'''
+ """Update all post-retarget fixes (neccesary to take under """ \
+ """consideration changes to armature object or pose)"""
bl_idname = "mocap.updateconstraints"
bl_label = "Update all post-retarget fixes"
@@ -770,7 +778,7 @@ class OBJECT_OT_UpdateMocapConstraints(bpy.types.Operator):
class OBJECT_OT_GuessHierachyMapping(bpy.types.Operator):
#Operator which calls heurisitic function to guess mapping between 2 armatures
- '''Attemp to auto figure out hierarchy mapping'''
+ """Attempt to auto figure out hierarchy mapping"""
bl_idname = "mocap.guessmapping"
bl_label = "Attemp to auto figure out hierarchy mapping"
@@ -793,7 +801,7 @@ class OBJECT_OT_GuessHierachyMapping(bpy.types.Operator):
class OBJECT_OT_PathEditing(bpy.types.Operator):
#Operator which calls path editing function, making active object follow the selected curve.
- '''Set active object (stride object) to follow the selected curve'''
+ """Set active object (stride object) to follow the selected curve"""
bl_idname = "mocap.pathediting"
bl_label = "Set active object (stride object) to follow the selected curve"
@@ -813,7 +821,8 @@ class OBJECT_OT_PathEditing(bpy.types.Operator):
class OBJECT_OT_AnimationStitchingButton(bpy.types.Operator):
#Operator which calls stitching function, combining 2 animations onto the NLA.
- '''Stitche two defined animations into a single one via alignment of NLA Tracks'''
+ """Stitche two defined animations into a single one via """ \
+ """alignment of NLA Tracks"""
bl_idname = "mocap.animstitch"
bl_label = "Stitch two defined animations into a single one via alignment of NLA Tracks"
@@ -834,7 +843,7 @@ class OBJECT_OT_AnimationStitchingButton(bpy.types.Operator):
class OBJECT_OT_GuessAnimationStitchingButton(bpy.types.Operator):
#Operator which calls stitching function heuristic, setting good values for above operator.
- '''Guess the stitch frame and second offset for animation stitch'''
+ """Guess the stitch frame and second offset for animation stitch"""
bl_idname = "mocap.animstitchguess"
bl_label = "Guess the stitch frame and second offset for animation stitch"
diff --git a/modules/constants_utils.py b/modules/constants_utils.py
index 6840ae09..153553e7 100644
--- a/modules/constants_utils.py
+++ b/modules/constants_utils.py
@@ -17,14 +17,14 @@
#
# ##### END GPL LICENSE BLOCK #####
-'''
+"""
constants_utils.py
Useful constants...
-'''
+"""
diff --git a/modules/cursor_utils.py b/modules/cursor_utils.py
index 22aba71b..b2f4ca03 100644
--- a/modules/cursor_utils.py
+++ b/modules/cursor_utils.py
@@ -17,14 +17,14 @@
#
# ##### END GPL LICENSE BLOCK #####
-'''
+"""
cursor_utils.py
Helper methods for accessing the 3D cursor
-'''
+"""
import bpy
diff --git a/modules/geometry_utils.py b/modules/geometry_utils.py
index 2a574b5d..163d2b73 100644
--- a/modules/geometry_utils.py
+++ b/modules/geometry_utils.py
@@ -17,14 +17,14 @@
#
# ##### END GPL LICENSE BLOCK #####
-'''
+"""
geometry_utils.py
3d geometry calculations
-'''
+"""
from mathutils import Vector, Matrix
diff --git a/modules/misc_utils.py b/modules/misc_utils.py
index 4592c03b..0eb60425 100644
--- a/modules/misc_utils.py
+++ b/modules/misc_utils.py
@@ -17,12 +17,12 @@
#
# ##### END GPL LICENSE BLOCK #####
-'''
+"""
misc_util.py
Miscellaneous helper methods.
-'''
+"""
import bpy
from cursor_utils import *
diff --git a/modules/selection_utils.py b/modules/selection_utils.py
index 6c0b8827..aff9eea8 100644
--- a/modules/selection_utils.py
+++ b/modules/selection_utils.py
@@ -27,8 +27,8 @@ selected = []
class SelectionOrder(bpy.types.Operator):
- '''Store the object names in the order they are selected.
- Use RETURN key to confirm selection, ESCAPE key to cancel'''
+ """Store the object names in the order they are selected, """ \
+ """use RETURN key to confirm selection, ESCAPE key to cancel"""
bl_idname = "object.select_order"
bl_label = "Select with Order"
bl_options = {'UNDO'}
diff --git a/modules/ui_utils.py b/modules/ui_utils.py
index e938efa9..0fd7582a 100644
--- a/modules/ui_utils.py
+++ b/modules/ui_utils.py
@@ -17,14 +17,14 @@
#
# ##### END GPL LICENSE BLOCK #####
-'''
+"""
ui_utils.py
Some UI utility functions
-'''
+"""
diff --git a/netrender/operators.py b/netrender/operators.py
index 74b2a285..bf0dfd61 100644
--- a/netrender/operators.py
+++ b/netrender/operators.py
@@ -29,7 +29,7 @@ import netrender.model
import netrender.versioning as versioning
class RENDER_OT_netclientsendbake(bpy.types.Operator):
- '''Send a baking job to the Network'''
+ """Send a baking job to the Network"""
bl_idname = "render.netclientsendbake"
bl_label = "Bake on network"
@@ -58,7 +58,7 @@ class RENDER_OT_netclientsendbake(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientanim(bpy.types.Operator):
- '''Start rendering an animation on network'''
+ """Start rendering an animation on network"""
bl_idname = "render.netclientanim"
bl_label = "Animation on network"
@@ -85,7 +85,7 @@ class RENDER_OT_netclientanim(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientrun(bpy.types.Operator):
- '''Start network rendering service'''
+ """Start network rendering service"""
bl_idname = "render.netclientstart"
bl_label = "Start Service"
@@ -102,7 +102,7 @@ class RENDER_OT_netclientrun(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientsend(bpy.types.Operator):
- '''Send Render Job to the Network'''
+ """Send Render Job to the Network"""
bl_idname = "render.netclientsend"
bl_label = "Send job"
@@ -132,7 +132,7 @@ class RENDER_OT_netclientsend(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientsendframe(bpy.types.Operator):
- '''Send Render Job with current frame to the Network'''
+ """Send Render Job with current frame to the Network"""
bl_idname = "render.netclientsendframe"
bl_label = "Send current frame job"
@@ -162,7 +162,7 @@ class RENDER_OT_netclientsendframe(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientstatus(bpy.types.Operator):
- '''Refresh the status of the current jobs'''
+ """Refresh the status of the current jobs"""
bl_idname = "render.netclientstatus"
bl_label = "Client Status"
@@ -203,7 +203,7 @@ class RENDER_OT_netclientstatus(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientblacklistslave(bpy.types.Operator):
- '''Exclude from rendering, by adding slave to the blacklist'''
+ """Exclude from rendering, by adding slave to the blacklist"""
bl_idname = "render.netclientblacklistslave"
bl_label = "Client Blacklist Slave"
@@ -233,7 +233,7 @@ class RENDER_OT_netclientblacklistslave(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientwhitelistslave(bpy.types.Operator):
- '''Remove slave from the blacklist'''
+ """Remove slave from the blacklist"""
bl_idname = "render.netclientwhitelistslave"
bl_label = "Client Whitelist Slave"
@@ -264,7 +264,7 @@ class RENDER_OT_netclientwhitelistslave(bpy.types.Operator):
class RENDER_OT_netclientslaves(bpy.types.Operator):
- '''Refresh status about available Render slaves'''
+ """Refresh status about available Render slaves"""
bl_idname = "render.netclientslaves"
bl_label = "Client Slaves"
@@ -315,7 +315,7 @@ class RENDER_OT_netclientslaves(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientcancel(bpy.types.Operator):
- '''Cancel the selected network rendering job'''
+ """Cancel the selected network rendering job"""
bl_idname = "render.netclientcancel"
bl_label = "Client Cancel"
@@ -345,7 +345,7 @@ class RENDER_OT_netclientcancel(bpy.types.Operator):
return self.execute(context)
class RENDER_OT_netclientcancelall(bpy.types.Operator):
- '''Cancel all running network rendering jobs'''
+ """Cancel all running network rendering jobs"""
bl_idname = "render.netclientcancelall"
bl_label = "Client Cancel All"
@@ -373,7 +373,7 @@ class RENDER_OT_netclientcancelall(bpy.types.Operator):
return self.execute(context)
class netclientdownload(bpy.types.Operator):
- '''Download render results from the network'''
+ """Download render results from the network"""
bl_idname = "render.netclientdownload"
bl_label = "Client Download"
@@ -461,7 +461,7 @@ class netclientdownload(bpy.types.Operator):
return self.execute(context)
class netclientscan(bpy.types.Operator):
- '''Listen on network for master server broadcasting its address and port'''
+ """Listen on network for master server broadcasting its address and port"""
bl_idname = "render.netclientscan"
bl_label = "Client Scan"
@@ -485,7 +485,7 @@ class netclientscan(bpy.types.Operator):
return self.execute(context)
class netclientvcsguess(bpy.types.Operator):
- '''Guess VCS setting for the current file'''
+ """Guess VCS setting for the current file"""
bl_idname = "render.netclientvcsguess"
bl_label = "VCS Guess"
@@ -517,7 +517,7 @@ class netclientvcsguess(bpy.types.Operator):
class netclientweb(bpy.types.Operator):
- '''Open new window with information about running rendering jobs'''
+ """Open new window with information about running rendering jobs"""
bl_idname = "render.netclientweb"
bl_label = "Open Master Monitor"
diff --git a/object_add_chain.py b/object_add_chain.py
index 1fdd0391..f1f89170 100644
--- a/object_add_chain.py
+++ b/object_add_chain.py
@@ -142,7 +142,7 @@ def Add_Chain():
#makes AddChain an operator
class AddChain(bpy.types.Operator):
- '''Add a Chain'''
+ """Add a Chain"""
bl_idname = "mesh.primitive_chain_add"
bl_label = "Add Chain"
bl_options = {'REGISTER', 'UNDO'}
diff --git a/object_animrenderbake.py b/object_animrenderbake.py
index 177e9700..b79a0e59 100644
--- a/object_animrenderbake.py
+++ b/object_animrenderbake.py
@@ -39,9 +39,9 @@ class OBJECT_OT_animrenderbake(bpy.types.Operator):
bl_register = True
def framefile(self, orig, frame):
- '''
+ """
Set frame number to file name image.png -> image0013.png
- '''
+ """
dot = orig.rfind(".")
return orig[:dot] + ('%04d' % frame) + orig[dot:]
diff --git a/object_fracture/fracture_ops.py b/object_fracture/fracture_ops.py
index 7a7ec387..87588aa4 100644
--- a/object_fracture/fracture_ops.py
+++ b/object_fracture/fracture_ops.py
@@ -341,7 +341,7 @@ def fracture_group(context, group):
class FractureSimple(bpy.types.Operator):
- '''Split object with boolean operations for simulation, uses an object'''
+ """Split object with boolean operations for simulation, uses an object"""
bl_idname = "object.fracture_simple"
bl_label = "Fracture Object"
bl_options = {'REGISTER', 'UNDO'}
@@ -387,7 +387,7 @@ class FractureSimple(bpy.types.Operator):
class FractureGroup(bpy.types.Operator):
- '''Split object with boolean operations for simulation, uses a group'''
+ """Split object with boolean operations for simulation, uses a group"""
bl_idname = "object.fracture_group"
bl_label = "Fracture Object (Group)"
bl_options = {'REGISTER', 'UNDO'}
@@ -447,7 +447,7 @@ def import_object(obname):
class ImportFractureRecorder(bpy.types.Operator):
- '''Imports a rigidbody recorder'''
+ """Imports a rigidbody recorder"""
bl_idname = "object.import_fracture_recorder"
bl_label = "Add Rigidbody Recorder (Fracture)"
bl_options = {'REGISTER', 'UNDO'}
@@ -459,7 +459,7 @@ class ImportFractureRecorder(bpy.types.Operator):
class ImportFractureBomb(bpy.types.Operator):
- '''Import a bomb'''
+ """Import a bomb"""
bl_idname = "object.import_fracture_bomb"
bl_label = "Add Bomb (Fracture)"
bl_options = {'REGISTER', 'UNDO'}
@@ -471,7 +471,7 @@ class ImportFractureBomb(bpy.types.Operator):
class ImportFractureProjectile(bpy.types.Operator, ):
- '''Imports a projectile'''
+ """Imports a projectile"""
bl_idname = "object.import_fracture_projectile"
bl_label = "Add Projectile (Fracture)"
bl_options = {'REGISTER', 'UNDO'}
diff --git a/object_fracture/fracture_setup.py b/object_fracture/fracture_setup.py
index 3ab93821..02c435f8 100644
--- a/object_fracture/fracture_setup.py
+++ b/object_fracture/fracture_setup.py
@@ -62,7 +62,7 @@ def setupshards(context):
class SetupFractureShards(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "object.setup_fracture_shards"
bl_label = "Setup Fracture Shards"
bl_options = {'REGISTER', 'UNDO'}
diff --git a/object_grease_scatter.py b/object_grease_scatter.py
index 97b016f0..f6b7258e 100644
--- a/object_grease_scatter.py
+++ b/object_grease_scatter.py
@@ -274,7 +274,7 @@ def _main(self,
# align the object with worldspace
obj_new.matrix_world = obj_mat
- # BGE settings for testiing
+ # BGE settings for testing
'''
inst_ob.game.physics_type = 'RIGID_BODY'
inst_ob.game.use_collision_bounds = True
@@ -321,7 +321,7 @@ from bpy.props import FloatProperty, StringProperty
class Scatter(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "object.scatter"
bl_label = "Grease Pencil Scatter"
diff --git a/paint_palette.py b/paint_palette.py
index 7c2c5748..e0371f4a 100644
--- a/paint_palette.py
+++ b/paint_palette.py
@@ -131,7 +131,7 @@ class PALETTE_MT_menu(bpy.types.Menu):
class LoadGimpPalette(bpy.types.Operator):
- ''' Executes a preset '''
+ """Execute a preset"""
bl_idname = "palette.load_gimp_palette"
bl_label = "Load a Gimp palette"
@@ -201,10 +201,10 @@ class LoadGimpPalette(bpy.types.Operator):
class WriteGimpPalette():
- '''Base preset class, only for subclassing
+ """Base preset class, only for subclassing
subclasses must define
- preset_values
- - preset_subdir '''
+ - preset_subdir """
bl_options = {'REGISTER'} # only because invoke_props_popup requires.
@@ -298,7 +298,7 @@ class WriteGimpPalette():
class AddPresetPalette(WriteGimpPalette, bpy.types.Operator):
- '''Add a Palette Preset'''
+ """Add a Palette Preset"""
bl_idname = "palette.preset_add"
bl_label = "Add Palette Preset"
preset_menu = "PALETTE_MT_menu"
diff --git a/render_copy_settings/operator.py b/render_copy_settings/operator.py
index 3b0da84f..31d36ecd 100644
--- a/render_copy_settings/operator.py
+++ b/render_copy_settings/operator.py
@@ -49,10 +49,8 @@ def collection_property_sort(collection, sortkey, start_idx=0):
class RenderCopySettingsPrepare(bpy.types.Operator):
- '''
- Prepare internal data for render_copy_settings (gathering all existing
- render settings, and scenes)
- '''
+ """Prepare internal data for render_copy_settings (gathering all """ \
+ """existingrender settings, and scenes)"""
bl_idname = "scene.render_copy_settings_prepare"
bl_label = "Render: Copy Settings Prepare"
bl_option = {'REGISTER'}
@@ -128,7 +126,7 @@ from bpy.props import EnumProperty
class RenderCopySettingsPreset(bpy.types.Operator):
- '''Apply some presets of render settings to copy to other scenes'''
+ """Apply some presets of render settings to copy to other scenes"""
bl_idname = "scene.render_copy_settings_preset"
bl_label = "Render: Copy Settings Preset"
bl_description = "Apply or clear this preset of render settings"
@@ -179,7 +177,7 @@ def do_copy(context, affected_settings, allowed_scenes):
class RenderCopySettings(bpy.types.Operator):
- '''Copy render settings from current scene to others'''
+ """Copy render settings from current scene to others"""
bl_idname = "scene.render_copy_settings"
bl_label = "Render: Copy Settings"
# Enable undo…
diff --git a/render_povray/update_files.py b/render_povray/update_files.py
index 4cd4f923..e1ecf786 100644
--- a/render_povray/update_files.py
+++ b/render_povray/update_files.py
@@ -122,9 +122,7 @@ def update2_0_0_9():
class RenderCopySettings(bpy.types.Operator):
- '''
- Update old POV properties to new ones.
- '''
+ """Update old POV properties to new ones"""
bl_idname = "scene.pov_update_properties"
bl_label = "PovRay render: Update to script v0.0.9"
bl_option = {'REGISTER'}
diff --git a/rigify/metarig_menu.py b/rigify/metarig_menu.py
index d5366480..6133f37e 100644
--- a/rigify/metarig_menu.py
+++ b/rigify/metarig_menu.py
@@ -23,7 +23,7 @@ from rigify.metarigs import human
class AddHuman(bpy.types.Operator):
- '''Add an advanced human metarig base'''
+ """Add an advanced human metarig base"""
bl_idname = "object.armature_human_advanced_add"
bl_label = "Add Humanoid (advanced metarig)"
bl_options = {'REGISTER', 'UNDO'}
diff --git a/rigify/ui.py b/rigify/ui.py
index 9b116260..6b356a77 100644
--- a/rigify/ui.py
+++ b/rigify/ui.py
@@ -230,7 +230,7 @@ def rigify_report_exception(operator, exception):
class Generate(bpy.types.Operator):
- '''Generates a rig from the active metarig armature'''
+ """Generates a rig from the active metarig armature"""
bl_idname = "pose.rigify_generate"
bl_label = "Rigify Generate Rig"
@@ -253,7 +253,8 @@ class Generate(bpy.types.Operator):
class Sample(bpy.types.Operator):
- '''Create a sample metarig to be modified before generating the final rig'''
+ """Create a sample metarig to be modified before generating """ \
+ """the final rig"""
bl_idname = "armature.metarig_sample_add"
bl_label = "Add a sample metarig for a rig type"
diff --git a/rigify/utils.py b/rigify/utils.py
index 197a1a25..e97fce79 100644
--- a/rigify/utils.py
+++ b/rigify/utils.py
@@ -462,10 +462,10 @@ def get_layers(layers):
def write_metarig(obj, layers=False, func_name="create_sample"):
- '''
+ """
Write a metarig as a python script, this rig is to have all info needed for
generating the real rig with rigify.
- '''
+ """
code = []
code.append("def %s(obj):" % func_name)
diff --git a/space_view3d_copy_attributes.py b/space_view3d_copy_attributes.py
index 73e4c412..8cbfc76b 100644
--- a/space_view3d_copy_attributes.py
+++ b/space_view3d_copy_attributes.py
@@ -37,7 +37,7 @@ from mathutils import Matrix, Vector
def build_exec(loopfunc, func):
- '''Generator function that returns exec functions for operators '''
+ """Generator function that returns exec functions for operators """
def exec_func(self, context):
loopfunc(self, context, func)
@@ -46,7 +46,7 @@ def build_exec(loopfunc, func):
def build_invoke(loopfunc, func):
- '''Generator function that returns invoke functions for operators'''
+ """Generator function that returns invoke functions for operators"""
def invoke_func(self, context, event):
loopfunc(self, context, func)
@@ -55,7 +55,7 @@ def build_invoke(loopfunc, func):
def build_op(idname, label, description, fpoll, fexec, finvoke):
- '''Generator function that returns the basic operator'''
+ """Generator function that returns the basic operator"""
class myopic(bpy.types.Operator):
bl_idname = idname
@@ -68,7 +68,7 @@ def build_op(idname, label, description, fpoll, fexec, finvoke):
def genops(copylist, oplist, prefix, poll_func, loopfunc):
- '''Generate ops from the copy list and its associated functions '''
+ """Generate ops from the copy list and its associated functions """
for op in copylist:
exec_func = build_exec(loopfunc, op[3])
invoke_func = build_invoke(loopfunc, op[3])
@@ -78,7 +78,7 @@ def genops(copylist, oplist, prefix, poll_func, loopfunc):
def generic_copy(source, target, string=""):
- ''' copy attributes from source to target that have string in them '''
+ """ copy attributes from source to target that have string in them """
for attr in dir(source):
if attr.find(string) > -1:
try:
@@ -89,9 +89,9 @@ def generic_copy(source, target, string=""):
def getmat(bone, active, context, ignoreparent):
- '''Helper function for visual transform copy,
+ """Helper function for visual transform copy,
gets the active transform in bone space
- '''
+ """
obj_act = context.active_object
data_bone = obj_act.data.bones[bone.name]
#all matrices are in armature space unless commented otherwise
@@ -112,7 +112,7 @@ def getmat(bone, active, context, ignoreparent):
def rotcopy(item, mat):
- '''copy rotation to item from matrix mat depending on item.rotation_mode'''
+ """copy rotation to item from matrix mat depending on item.rotation_mode"""
if item.rotation_mode == 'QUATERNION':
item.rotation_quaternion = mat.to_3x3().to_quaternion()
elif item.rotation_mode == 'AXIS_ANGLE':
@@ -123,7 +123,7 @@ def rotcopy(item, mat):
def pLoopExec(self, context, funk):
- '''Loop over selected bones and execute funk on them'''
+ """Loop over selected bones and execute funk on them"""
active = context.active_pose_bone
selected = context.selected_pose_bones
selected.remove(active)
@@ -218,7 +218,7 @@ def pose_invoke_func(self, context, event):
class CopySelectedPoseConstraints(bpy.types.Operator):
- ''' Copy Chosen constraints from active to selected'''
+ """Copy Chosen constraints from active to selected"""
bl_idname = "pose.copy_selected_constraints"
bl_label = "Copy Selected Constraints"
selection = bpy.props.BoolVectorProperty(size=32)
@@ -263,7 +263,7 @@ class VIEW3D_MT_posecopypopup(bpy.types.Menu):
def obLoopExec(self, context, funk):
- '''Loop over selected objects and execute funk on them'''
+ """Loop over selected objects and execute funk on them"""
active = context.active_object
selected = context.selected_objects[:]
selected.remove(active)
@@ -274,7 +274,7 @@ def obLoopExec(self, context, funk):
def world_to_basis(active, ob, context):
- '''put world coords of active as basis coords of ob'''
+ """put world coords of active as basis coords of ob"""
local = ob.parent.matrix_world.inverted() * active.matrix_world
P = ob.matrix_basis * ob.matrix_local.inverted()
mat = P * local
@@ -517,7 +517,7 @@ def object_invoke_func(self, context, event):
class CopySelectedObjectConstraints(bpy.types.Operator):
- ''' Copy Chosen constraints from active to selected'''
+ """Copy Chosen constraints from active to selected"""
bl_idname = "object.copy_selected_constraints"
bl_label = "Copy Selected Constraints"
selection = bpy.props.BoolVectorProperty(size=32)
@@ -547,7 +547,7 @@ class CopySelectedObjectConstraints(bpy.types.Operator):
class CopySelectedObjectModifiers(bpy.types.Operator):
- ''' Copy Chosen modifiers from active to selected'''
+ """Copy Chosen modifiers from active to selected"""
bl_idname = "object.copy_selected_modifiers"
bl_label = "Copy Selected Modifiers"
selection = bpy.props.BoolVectorProperty(size=32)
diff --git a/space_view3d_materials_utils.py b/space_view3d_materials_utils.py
index 48e1163b..609d8343 100644
--- a/space_view3d_materials_utils.py
+++ b/space_view3d_materials_utils.py
@@ -494,7 +494,7 @@ def remove_materials():
# operator classes:
class VIEW3D_OT_texface_to_material(bpy.types.Operator):
- '''Create texture materials for images assigned in UV editor'''
+ """Create texture materials for images assigned in UV editor"""
bl_idname = "view3d.texface_to_material"
bl_label = "MW Texface Images to Material/Texture"
bl_options = {'REGISTER', 'UNDO'}
@@ -514,7 +514,7 @@ class VIEW3D_OT_texface_to_material(bpy.types.Operator):
class VIEW3D_OT_assign_material(bpy.types.Operator):
- '''Assign a material to the selection'''
+ """Assign a material to the selection"""
bl_idname = "view3d.assign_material"
bl_label = "MW Assign Material"
bl_options = {'REGISTER', 'UNDO'}
@@ -540,8 +540,8 @@ class VIEW3D_OT_assign_material(bpy.types.Operator):
class VIEW3D_OT_clean_material_slots(bpy.types.Operator):
- '''Removes any material slots from selected objects '''\
- '''that are not used by the mesh'''
+ """Removes any material slots from selected objects """ \
+ """that are not used by the mesh"""
bl_idname = "view3d.clean_material_slots"
bl_label = "MW Clean Material Slots"
bl_options = {'REGISTER', 'UNDO'}
@@ -556,7 +556,7 @@ class VIEW3D_OT_clean_material_slots(bpy.types.Operator):
class VIEW3D_OT_material_to_texface(bpy.types.Operator):
- '''Transfer material assignments to UV editor'''
+ """Transfer material assignments to UV editor"""
bl_idname = "view3d.material_to_texface"
bl_label = "MW Material Images to Texface"
bl_options = {'REGISTER', 'UNDO'}
@@ -570,7 +570,7 @@ class VIEW3D_OT_material_to_texface(bpy.types.Operator):
return {'FINISHED'}
class VIEW3D_OT_material_remove(bpy.types.Operator):
- '''Remove all material slots from active objects'''
+ """Remove all material slots from active objects"""
bl_idname = "view3d.material_remove"
bl_label = "Remove All Material Slots"
bl_options = {'REGISTER', 'UNDO'}
@@ -585,7 +585,7 @@ class VIEW3D_OT_material_remove(bpy.types.Operator):
class VIEW3D_OT_select_material_by_name(bpy.types.Operator):
- '''Select geometry with this material assigned to it'''
+ """Select geometry with this material assigned to it"""
bl_idname = "view3d.select_material_by_name"
bl_label = "MW Select Material By Name"
bl_options = {'REGISTER', 'UNDO'}
@@ -606,7 +606,7 @@ class VIEW3D_OT_select_material_by_name(bpy.types.Operator):
class VIEW3D_OT_replace_material(bpy.types.Operator):
- '''Replace a material by name'''
+ """Replace a material by name"""
bl_idname = "view3d.replace_material"
bl_label = "MW Replace Material"
bl_options = {'REGISTER', 'UNDO'}
diff --git a/space_view3d_math_vis/__init__.py b/space_view3d_math_vis/__init__.py
index ba88910a..739c0473 100644
--- a/space_view3d_math_vis/__init__.py
+++ b/space_view3d_math_vis/__init__.py
@@ -59,7 +59,8 @@ class VIEW3D_PT_math_vis(bpy.types.Panel):
class SetupMathView(bpy.types.Operator):
- '''Visualize mathutils type python variables from the interactive console, see addon docs'''
+ """Visualize mathutils type python variables from the """ \
+ """interactive console, see addon docs"""
bl_idname = "view3d.math_vis_toggle"
bl_label = "Use Math Vis"
diff --git a/space_view3d_panel_measure.py b/space_view3d_panel_measure.py
index d0868490..85cea04c 100644
--- a/space_view3d_panel_measure.py
+++ b/space_view3d_panel_measure.py
@@ -904,7 +904,7 @@ def draw_measurements_callback(self, context):
class VIEW3D_OT_display_measurements(bpy.types.Operator):
- '''Display the measurements made in the 'Measure' panel'''
+ """Display the measurements made in the 'Measure' panel"""
bl_idname = "view3d.display_measurements"
bl_label = "Display the measurements made in the" \
" 'Measure' panel in the 3D View"
diff --git a/system_demo_mode/__init__.py b/system_demo_mode/__init__.py
index da8112df..d90c549c 100644
--- a/system_demo_mode/__init__.py
+++ b/system_demo_mode/__init__.py
@@ -47,7 +47,7 @@ from bpy.props import (StringProperty,
class DemoModeSetup(bpy.types.Operator):
- '''Create a demo script and optionally execute it'''
+ """Create a demo script and optionally execute it"""
bl_idname = "wm.demo_mode_setup"
bl_label = "Demo Mode (Setup)"
bl_options = {'PRESET'}
diff --git a/system_demo_mode/demo_mode.py b/system_demo_mode/demo_mode.py
index b52886be..0d02bcb4 100644
--- a/system_demo_mode/demo_mode.py
+++ b/system_demo_mode/demo_mode.py
@@ -18,7 +18,7 @@
# <pep8 compliant>
-'''
+"""
Even though this is in a package this can run as a stand alone scripts.
# --- example usage
@@ -32,7 +32,7 @@ config = [
]
# ---
/data/src/blender/lib/tests/rendering/
-'''
+"""
import bpy
import time
diff --git a/system_property_chart.py b/system_property_chart.py
index 8f58a17a..4178ebe0 100644
--- a/system_property_chart.py
+++ b/system_property_chart.py
@@ -54,9 +54,9 @@ def _property_chart_data_get(self, context):
def _property_chart_draw(self, context):
- '''
+ """
This function can run for different types.
- '''
+ """
obj, selected_objects = _property_chart_data_get(self, context)
if not obj:
diff --git a/texture_paint_layer_manager.py b/texture_paint_layer_manager.py
index 0fc6a9a2..b572a445 100644
--- a/texture_paint_layer_manager.py
+++ b/texture_paint_layer_manager.py
@@ -48,7 +48,7 @@ def load_a_brush(context, filepath):
class load_single_brush(bpy.types.Operator, ImportHelper):
- ''' Load an image as a brush texture'''
+ """Load an image as a brush texture"""
bl_idname = "texture.load_single_brush"
bl_label = "Load Image as Brush"
@@ -97,7 +97,7 @@ def loadbrushes(context, filepath):
class ImportBrushes(bpy.types.Operator, ImportHelper):
- ''' Load a directory of images as brush textures '''
+ """Load a directory of images as brush textures"""
bl_idname = "texture.load_brushes"
bl_label = "Load brushes directory"
@@ -366,7 +366,7 @@ def main(context,tn):
class set_active_paint_layer(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "object.set_active_paint_layer"
bl_label = "set_active_paint_layer"
tex_index = IntProperty(name = 'tex_index',
@@ -525,7 +525,7 @@ def add_paint(context, size =2048, typ = 'NORMAL'):
class add_paint_layer(bpy.types.Operator):
- ''''''
+ """"""
bl_idname = "object.add_paint_layer"
bl_label = "Add Paint Layer"
ttype = StringProperty(name ='ttype',default ='NORMAL')
@@ -596,7 +596,7 @@ def save_all_paint():
class save_all_generated(bpy.types.Operator):
- '''Saves painted layers to disc '''
+ """Saves painted layers to disc"""
bl_idname = "paint.save_all_generated"
bl_label = "SAVE PAINT LAYERS"