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:
authorCampbell Barton <ideasman42@gmail.com>2018-10-02 03:18:55 +0300
committerCampbell Barton <ideasman42@gmail.com>2018-10-02 03:19:41 +0300
commit01370f8794eb19ed651b9bfe317de6525944bb50 (patch)
treeecb2c06090e698955f73421d9ab1afff350b8474 /object_print3d_utils/operators.py
parent15cf78e2a525cca3f650f7af45e9c4213303005f (diff)
Print3D: use annotations
Diffstat (limited to 'object_print3d_utils/operators.py')
-rw-r--r--object_print3d_utils/operators.py72
1 files changed, 36 insertions, 36 deletions
diff --git a/object_print3d_utils/operators.py b/object_print3d_utils/operators.py
index af8a29e8..ebc1a730 100644
--- a/object_print3d_utils/operators.py
+++ b/object_print3d_utils/operators.py
@@ -23,15 +23,15 @@
import bpy
from bpy.types import Operator
from bpy.props import (
- IntProperty,
- FloatProperty,
- )
+ IntProperty,
+ FloatProperty,
+)
import bmesh
from . import (
- mesh_helpers,
- report,
- )
+ mesh_helpers,
+ report,
+)
def clean_float(text):
@@ -430,16 +430,16 @@ class MESH_OT_Print3D_Clean_Non_Manifold(Operator):
bl_label = "Print3D Clean Non-Manifold and Inverted"
bl_options = {'REGISTER', 'UNDO'}
- threshold = bpy.props.FloatProperty(
- name="threshold",
- description="Minimum distance between elements to merge",
- default=0.0001,
- )
- sides = bpy.props.IntProperty(
- name="sides",
- description="Number of sides in hole required to fill",
- default=4,
- )
+ threshold: bpy.props.FloatProperty(
+ name="threshold",
+ description="Minimum distance between elements to merge",
+ default=0.0001,
+ )
+ sides: bpy.props.IntProperty(
+ name="sides",
+ description="Number of sides in hole required to fill",
+ default=4,
+ )
def execute(self, context):
self.context = context
@@ -600,7 +600,7 @@ class MESH_OT_Print3D_Select_Report(Operator):
bl_label = "Print3D Select Report"
bl_options = {'INTERNAL'}
- index = IntProperty()
+ index: IntProperty()
_type_to_mode = {
bmesh.types.BMVert: 'VERT',
@@ -659,14 +659,14 @@ class MESH_OT_Print3D_Scale_To_Volume(Operator):
bl_label = "Scale to Volume"
bl_options = {'REGISTER', 'UNDO'}
- volume_init = FloatProperty(
- options={'HIDDEN'},
- )
- volume = FloatProperty(
- name="Volume",
- unit='VOLUME',
- min=0.0, max=100000.0,
- )
+ volume_init: FloatProperty(
+ options={'HIDDEN'},
+ )
+ volume: FloatProperty(
+ name="Volume",
+ unit='VOLUME',
+ min=0.0, max=100000.0,
+ )
def execute(self, context):
import math
@@ -705,17 +705,17 @@ class MESH_OT_Print3D_Scale_To_Bounds(Operator):
bl_label = "Scale to Bounds"
bl_options = {'REGISTER', 'UNDO'}
- length_init = FloatProperty(
- options={'HIDDEN'},
- )
- axis_init = IntProperty(
- options={'HIDDEN'},
- )
- length = FloatProperty(
- name="Length Limit",
- unit='LENGTH',
- min=0.0, max=100000.0,
- )
+ length_init: FloatProperty(
+ options={'HIDDEN'},
+ )
+ axis_init: IntProperty(
+ options={'HIDDEN'},
+ )
+ length: FloatProperty(
+ name="Length Limit",
+ unit='LENGTH',
+ min=0.0, max=100000.0,
+ )
def execute(self, context):
scale = self.length / self.length_init