1 # This program is free software; you can redistribute it and/or
2 # modify it under the terms of the GNU General Public License
3 # as published by the Free Software Foundation; either version 2
4 # of the License, or (at your option) any later version.
6 # This program is distributed in the hope that it will be useful,
7 # but WITHOUT ANY WARRANTY; without even the implied warranty of
8 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 # GNU General Public License for more details.
11 # You should have received a copy of the GNU General Public License
12 # along with this program; if not, write to the Free Software Foundation,
13 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
16 from bpy
.props
import (
22 class AmaranthToolsetPreferences(bpy
.types
.AddonPreferences
):
23 bl_idname
= "amaranth"
24 use_frame_current
: BoolProperty(
25 name
="Current Frame Slider",
26 description
="Set the current frame from the Specials menu in the 3D View",
29 use_file_save_reload
: BoolProperty(
30 name
="Save & Reload File",
31 description
="File menu > Save & Reload, or Ctrl + Shift + W",
34 use_scene_refresh
: BoolProperty(
36 description
="Specials Menu [W]",
39 use_timeline_extra_info
: BoolProperty(
40 name
="Timeline Extra Info",
41 description
="Timeline Header",
44 use_image_node_display
: BoolProperty(
45 name
="Active Image Node in Editor",
46 description
="Display active node image in image editor",
49 use_scene_stats
: BoolProperty(
50 name
="Extra Scene Statistics",
51 description
="Display extra scene statistics in the status bar (may be slow in heavy scenes)",
54 frames_jump
: IntProperty(
56 description
="Number of frames to jump forward/backward",
60 use_framerate
: BoolProperty(
61 name
="Framerate Jump",
62 description
="Jump the amount of frames forward/backward that you have set as your framerate",
65 use_layers_for_render
: BoolProperty(
66 name
="Current Layers for Render",
67 description
="Save the layers that should be enabled for render",
71 def draw(self
, context
):
75 text
="Here you can enable or disable specific tools, "
76 "in case they interfere with others or are just plain annoying")
78 split
= layout
.split(factor
=0.25)
81 sub
= col
.column(align
=True)
82 sub
.label(text
="3D View", icon
="VIEW3D")
83 sub
.prop(self
, "use_frame_current")
84 sub
.prop(self
, "use_scene_refresh")
88 sub
.label(text
="General", icon
="SCENE_DATA")
89 sub
.prop(self
, "use_file_save_reload")
90 sub
.prop(self
, "use_timeline_extra_info")
91 sub
.prop(self
, "use_scene_stats")
92 sub
.prop(self
, "use_layers_for_render")
93 sub
.prop(self
, "use_framerate")
97 sub
.label(text
="Nodes Editor", icon
="NODETREE")
98 sub
.prop(self
, "use_image_node_display")
101 sub
= col
.column(align
=True)
104 text
="Set the current frame from the Specials menu in the 3D View [W]")
106 text
="Refresh the current Scene. Hotkey: F5 or in Specials menu [W]")
109 sub
.label(text
="") # General icon
111 text
="Quickly save and reload the current file (no warning!). "
112 "File menu or Ctrl+Shift+W")
114 text
="SMPTE Timecode and frames left/ahead on Timeline's header")
116 text
="Display extra stats for Scenes, Cameras, Meshlights (Cycles). Can be slow in heavy scenes")
118 text
="Save the set of layers that should be activated for a final render")
120 text
="Jump the amount of frames forward/backward that you've set as your framerate")
123 sub
.label(text
="") # Nodes
125 text
="When double-clicking an Image node, display it on the Image editor "
130 bpy
.utils
.register_class(AmaranthToolsetPreferences
)
134 bpy
.utils
.unregister_class(AmaranthToolsetPreferences
)