Sun position: remove unused prop in HDRI mode
[blender-addons.git] / io_curve_svg / __init__.py
blob03b1755ede62f39ecc25650876ba19f2c0fd9f6c
1 # ##### BEGIN GPL LICENSE BLOCK #####
3 # This program is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU General Public License
5 # as published by the Free Software Foundation; either version 2
6 # of the License, or (at your option) any later version.
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 # GNU General Public License for more details.
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software Foundation,
15 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 # ##### END GPL LICENSE BLOCK #####
19 # <pep8 compliant>
21 bl_info = {
22 "name": "Scalable Vector Graphics (SVG) 1.1 format",
23 "author": "JM Soler, Sergey Sharybin",
24 "blender": (2, 80, 0),
25 "location": "File > Import > Scalable Vector Graphics (.svg)",
26 "description": "Import SVG as curves",
27 "warning": "",
28 "doc_url": "{BLENDER_MANUAL_URL}/addons/import_export/curve_svg.html",
29 "support": 'OFFICIAL',
30 "category": "Import-Export",
34 # To support reload properly, try to access a package var,
35 # if it's there, reload everything
36 if "bpy" in locals():
37 import importlib
38 if "import_svg" in locals():
39 importlib.reload(import_svg)
42 import bpy
43 from bpy.props import StringProperty
44 from bpy_extras.io_utils import ImportHelper
47 class ImportSVG(bpy.types.Operator, ImportHelper):
48 """Load a SVG file"""
49 bl_idname = "import_curve.svg"
50 bl_label = "Import SVG"
51 bl_options = {'UNDO'}
53 filename_ext = ".svg"
54 filter_glob: StringProperty(default="*.svg", options={'HIDDEN'})
56 def execute(self, context):
57 from . import import_svg
59 return import_svg.load(self, context, filepath=self.filepath)
62 def menu_func_import(self, context):
63 self.layout.operator(ImportSVG.bl_idname,
64 text="Scalable Vector Graphics (.svg)")
67 def register():
68 bpy.utils.register_class(ImportSVG)
70 bpy.types.TOPBAR_MT_file_import.append(menu_func_import)
73 def unregister():
74 bpy.utils.unregister_class(ImportSVG)
76 bpy.types.TOPBAR_MT_file_import.remove(menu_func_import)
78 # NOTES
79 # - blender version is hardcoded
81 if __name__ == "__main__":
82 register()