chiark / gitweb /
Add back the ultimaker platform, and made the platform mesh simpler.
[cura.git] / Cura / slice / cura_sf / skeinforge_application / skeinforge_plugins / profile_plugins / extrusion.py
1 """
2 This page is in the table of contents.
3 Extrusion is a script to set the extrusion profile for the skeinforge chain.
4
5 The displayed craft sequence is the sequence in which the tools craft the model and export the output.
6
7 On the extrusion dialog, clicking the 'Add Profile' button will duplicate the selected profile and give it the name in the input field.  For example, if ABS is selected and the name ABS_black is in the input field, clicking the 'Add Profile' button will duplicate ABS and save it as ABS_black.  The 'Delete Profile' button deletes the selected profile.
8
9 The profile selection is the setting.  If you hit 'Save and Close' the selection will be saved, if you hit 'Cancel' the selection will not be saved.  However; adding and deleting a profile is a permanent action, for example 'Cancel' will not bring back any deleted profiles.
10
11 To change the extrusion profile, in a shell in the profile_plugins folder type:
12 > python extrusion.py
13
14 """
15
16
17 from __future__ import absolute_import
18
19 from fabmetheus_utilities import settings
20 from skeinforge_application.skeinforge_utilities import skeinforge_profile
21 import sys
22
23
24 __author__ = 'Enrique Perez (perez_enrique@yahoo.com)'
25 __date__ = '$Date: 2008/21/04 $'
26 __license__ = 'GNU Affero General Public License http://www.gnu.org/licenses/agpl.html'
27
28
29 def getCraftSequence():
30         'Get the extrusion craft sequence.'
31         return 'carve scale bottom preface widen inset fill multiply speed temperature raft skirt chamber tower jitter clip smooth stretch skin joris comb cool hop wipe oozebane dwindle splodge home lash fillet limit unpause dimension alteration export'.split()
32
33 def getNewRepository():
34         'Get new repository.'
35         return ExtrusionRepository()
36
37
38 class ExtrusionRepository(object):
39         'A class to handle the export settings.'
40         def __init__(self):
41                 'Set the default settings, execute title & settings fileName.'
42                 skeinforge_profile.addListsSetCraftProfile( getCraftSequence(), 'ABS', self, 'skeinforge_application.skeinforge_plugins.profile_plugins.extrusion.html')
43
44
45 def main():
46         'Display the export dialog.'
47         if len(sys.argv) > 1:
48                 writeOutput(' '.join(sys.argv[1 :]))
49         else:
50                 settings.startMainLoopFromConstructor(getNewRepository())
51
52 if __name__ == '__main__':
53         main()