printrun-src/printrun/pronterface.py

changeset 29
c96f20e95029
parent 25
0e3e7fbf0bc6
child 31
92035ebc4743
equal deleted inserted replaced
28:23efe2c53872 29:c96f20e95029
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 2
3 # FILE MODIFIED BY NEOSOFT - MALTE BAYER 3 # FILE MODIFIED BY NEOSOFT - MALTE DI DONATO
4 # Embed Lasercut functions from laser.py 4 # Embed Lasercut functions from laser.py
5 import laser 5 import laser
6 try:
7 from module_watcher import ModuleWatcher
8 mw = ModuleWatcher()
9 mw.watch_module('laser')
10 mw.start_watching()
6 11
7 # This file is part of the Printrun suite. 12 # This file is part of the Printrun suite.
8 # 13 #
9 # Printrun is free software: you can redistribute it and/or modify 14 # Printrun is free software: you can redistribute it and/or modify
10 # it under the terms of the GNU General Public License as published by 15 # it under the terms of the GNU General Public License as published by
851 856
852 def _add_settings(self, size): 857 def _add_settings(self, size):
853 858
854 # first add the lasercutter options 859 # first add the lasercutter options
855 self.settings._add(StaticTextSetting("separator_lc_general", "General laser settings", "", group = "Laser")) 860 self.settings._add(StaticTextSetting("separator_lc_general", "General laser settings", "", group = "Laser"))
856 self.settings._add(SpinSetting("lc_travel_speed", 120, 10, 300, "Travel speed in mm/s", "", "Laser"), self.update_lc_settings) 861 self.settings._add(SpinSetting("lc_travel_speed", 120, 1, 300, "Travel speed in mm/s", "", "Laser"), self.update_lc_settings)
857 self.settings._add(SpinSetting("lc_engrave_speed", 10, 10, 300, "Engrave speed in mm/s", "", "Laser"), self.update_lc_settings) 862 self.settings._add(SpinSetting("lc_engrave_speed", 10, 1, 300, "Engrave speed in mm/s", "", "Laser"), self.update_lc_settings)
858 863
859 self.settings._add(StaticTextSetting("separator_lc_bitmap", "PNG Bitmap processing", "", group = "Laser")) 864 self.settings._add(StaticTextSetting("separator_lc_bitmap", "PNG Bitmap processing", "", group = "Laser"))
860 self.settings._add(FloatSpinSetting("lc_bitmap_speed_factor", 1.0, 0.1, 2.0, "Engrave speed factor", "", "Laser"), self.update_lc_settings) 865 self.settings._add(FloatSpinSetting("lc_bitmap_speed_factor", 1.0, 0.1, 2.0, "Engrave speed factor", "", "Laser"), self.update_lc_settings)
861 self.settings._add(SpinSetting("lc_dpi", 300, 25, 300, "Image DPI", "Image resolution for scaling", "Laser"), self.update_lc_settings) 866 self.settings._add(SpinSetting("lc_dpi", 300, 25, 300, "Image DPI", "Image resolution for scaling", "Laser"), self.update_lc_settings)
862 self.settings._add(SpinSetting("lc_grey_threshold", 0, 0, 255, "Grey threshold value for RGB", "", "Laser"), self.update_lc_settings) 867 self.settings._add(SpinSetting("lc_grey_threshold", 0, 0, 255, "Grey threshold value for RGB", "", "Laser"), self.update_lc_settings)
867 self.settings._add(FloatSpinSetting("lc_hpgl_speed_factor", 1.0, 0.1, 2.0, "Engrave speed factor", "", "Laser"), self.update_lc_settings) 872 self.settings._add(FloatSpinSetting("lc_hpgl_speed_factor", 1.0, 0.1, 2.0, "Engrave speed factor", "", "Laser"), self.update_lc_settings)
868 873
869 self.settings._add(StaticTextSetting("separator_lc_svg", "SVG processing", "", group = "Laser")) 874 self.settings._add(StaticTextSetting("separator_lc_svg", "SVG processing", "", group = "Laser"))
870 self.settings._add(FloatSpinSetting("lc_svg_speed_factor", 1.0, 0.1, 2.0, "Engrave speed factor", "", "Laser"), self.update_lc_settings) 875 self.settings._add(FloatSpinSetting("lc_svg_speed_factor", 1.0, 0.1, 2.0, "Engrave speed factor", "", "Laser"), self.update_lc_settings)
871 self.settings._add(FloatSpinSetting("lc_svg_smoothness", 0.2, 0.1, 10.0, "Smoothness", "Smoothness of curves (smaller value = smoother curve)", "Laser"), self.update_lc_settings) 876 self.settings._add(FloatSpinSetting("lc_svg_smoothness", 0.2, 0.1, 10.0, "Smoothness", "Smoothness of curves (smaller value = smoother curve)", "Laser"), self.update_lc_settings)
872 self.settings._add(SpinSetting("lc_svg_width", 50, 1, 200, "Width (mm)", "Image width", "Laser"), self.update_lc_settings) 877 self.settings._add(SpinSetting("lc_svg_width", 50, 1, 250, "Width (mm)", "Image width", "Laser"), self.update_lc_settings)
873 self.settings._add(SpinSetting("lc_svg_height", 50, 1, 200, "Height (mm)", "Image height", "Laser"), self.update_lc_settings) 878 self.settings._add(SpinSetting("lc_svg_height", 50, 1, 250, "Height (mm)", "Image height", "Laser"), self.update_lc_settings)
874 self.settings._add(ComboSetting("lc_svg_scalemode", "scale", ["scale", "stretch"], "Scaling mode", "scale to dimensions / stretch to dimensions", "Laser"), self.update_lc_settings) 879 self.settings._add(ComboSetting("lc_svg_scalemode", "scale", ["scale", "stretch"], "Scaling mode", "scale to dimensions / stretch to dimensions", "Laser"), self.update_lc_settings)
875 880
876 881
877 self.settings._add(BooleanSetting("monitor", True, _("Monitor printer status"), _("Regularly monitor printer temperatures (required to have functional temperature graph or gauges)"), "Printer"), self.update_monitor) 882 self.settings._add(BooleanSetting("monitor", True, _("Monitor printer status"), _("Regularly monitor printer temperatures (required to have functional temperature graph or gauges)"), "Printer"), self.update_monitor)
878 self.settings._add(StringSetting("simarrange_path", "", _("Simarrange command"), _("Path to the simarrange binary to use in the STL plater"), "External")) 883 self.settings._add(StringSetting("simarrange_path", "", _("Simarrange command"), _("Path to the simarrange binary to use in the STL plater"), "External"))

mercurial