Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
Printrun
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
machinery
Printrun
Commits
0e37eee7
Commit
0e37eee7
authored
Mar 19, 2014
by
Guillaume Seguin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add length/speed labels to extrusion controls
parent
b0683bb9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
gui.py
printrun/gui.py
+7
-5
No files found.
printrun/gui.py
View file @
0e37eee7
...
@@ -167,14 +167,15 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None):
...
@@ -167,14 +167,15 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None):
self
.
Add
(
ebuttonspanel
,
pos
=
(
base_line
+
2
,
0
),
span
=
(
1
,
5
),
flag
=
wx
.
EXPAND
)
self
.
Add
(
ebuttonspanel
,
pos
=
(
base_line
+
2
,
0
),
span
=
(
1
,
5
),
flag
=
wx
.
EXPAND
)
esettingspanel
=
root
.
newPanel
(
parentpanel
)
esettingspanel
=
root
.
newPanel
(
parentpanel
)
esettingssizer
=
wx
.
BoxSizer
(
wx
.
HORIZONTAL
)
esettingssizer
=
wx
.
GridBagSizer
(
)
root
.
edist
=
FloatSpin
(
esettingspanel
,
-
1
,
value
=
root
.
settings
.
last_extrusion
,
min_val
=
0
,
max_val
=
1000
,
size
=
(
70
,
-
1
),
digits
=
1
)
root
.
edist
=
FloatSpin
(
esettingspanel
,
-
1
,
value
=
root
.
settings
.
last_extrusion
,
min_val
=
0
,
max_val
=
1000
,
size
=
(
70
,
-
1
),
digits
=
1
)
root
.
edist
.
SetBackgroundColour
((
225
,
200
,
200
))
root
.
edist
.
SetBackgroundColour
((
225
,
200
,
200
))
root
.
edist
.
SetForegroundColour
(
"black"
)
root
.
edist
.
SetForegroundColour
(
"black"
)
root
.
edist
.
Bind
(
wx
.
EVT_SPINCTRL
,
root
.
setfeeds
)
root
.
edist
.
Bind
(
wx
.
EVT_SPINCTRL
,
root
.
setfeeds
)
root
.
edist
.
Bind
(
wx
.
EVT_TEXT
,
root
.
setfeeds
)
root
.
edist
.
Bind
(
wx
.
EVT_TEXT
,
root
.
setfeeds
)
esettingssizer
.
Add
(
root
.
edist
,
flag
=
wx
.
ALIGN_CENTER
|
wx
.
RIGHT
,
border
=
5
)
esettingssizer
.
Add
(
root
.
edist
,
pos
=
(
1
,
0
),
flag
=
wx
.
ALIGN_CENTER
|
wx
.
RIGHT
,
border
=
5
)
esettingssizer
.
Add
(
wx
.
StaticText
(
esettingspanel
,
-
1
,
_
(
"mm @"
)),
flag
=
wx
.
ALIGN_CENTER
|
wx
.
RIGHT
,
border
=
5
)
esettingssizer
.
Add
(
wx
.
StaticText
(
esettingspanel
,
-
1
,
_
(
"Length:"
)),
pos
=
(
0
,
0
),
flag
=
wx
.
ALIGN_LEFT
)
esettingssizer
.
Add
(
wx
.
StaticText
(
esettingspanel
,
-
1
,
_
(
"mm @"
)),
pos
=
(
1
,
1
),
flag
=
wx
.
ALIGN_CENTER
|
wx
.
RIGHT
,
border
=
5
)
root
.
edist
.
SetToolTip
(
wx
.
ToolTip
(
_
(
"Amount to Extrude or Retract (mm)"
)))
root
.
edist
.
SetToolTip
(
wx
.
ToolTip
(
_
(
"Amount to Extrude or Retract (mm)"
)))
root
.
efeedc
=
FloatSpin
(
esettingspanel
,
-
1
,
value
=
root
.
settings
.
e_feedrate
,
min_val
=
0
,
max_val
=
50000
,
size
=
(
70
,
-
1
),
digits
=
1
)
root
.
efeedc
=
FloatSpin
(
esettingspanel
,
-
1
,
value
=
root
.
settings
.
e_feedrate
,
min_val
=
0
,
max_val
=
50000
,
size
=
(
70
,
-
1
),
digits
=
1
)
root
.
efeedc
.
SetToolTip
(
wx
.
ToolTip
(
_
(
"Extrude / Retract speed (mm/min)"
)))
root
.
efeedc
.
SetToolTip
(
wx
.
ToolTip
(
_
(
"Extrude / Retract speed (mm/min)"
)))
...
@@ -182,8 +183,9 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None):
...
@@ -182,8 +183,9 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None):
root
.
efeedc
.
SetForegroundColour
(
"black"
)
root
.
efeedc
.
SetForegroundColour
(
"black"
)
root
.
efeedc
.
Bind
(
wx
.
EVT_SPINCTRL
,
root
.
setfeeds
)
root
.
efeedc
.
Bind
(
wx
.
EVT_SPINCTRL
,
root
.
setfeeds
)
root
.
efeedc
.
Bind
(
wx
.
EVT_TEXT
,
root
.
setfeeds
)
root
.
efeedc
.
Bind
(
wx
.
EVT_TEXT
,
root
.
setfeeds
)
esettingssizer
.
Add
(
root
.
efeedc
,
flag
=
wx
.
ALIGN_CENTER
|
wx
.
RIGHT
,
border
=
5
)
esettingssizer
.
Add
(
root
.
efeedc
,
pos
=
(
1
,
2
),
flag
=
wx
.
ALIGN_CENTER
|
wx
.
RIGHT
,
border
=
5
)
esettingssizer
.
Add
(
wx
.
StaticText
(
esettingspanel
,
-
1
,
_
(
"mm/
\n
min"
)),
flag
=
wx
.
ALIGN_CENTER
)
esettingssizer
.
Add
(
wx
.
StaticText
(
esettingspanel
,
-
1
,
_
(
"Speed:"
)),
pos
=
(
0
,
2
),
flag
=
wx
.
ALIGN_LEFT
)
esettingssizer
.
Add
(
wx
.
StaticText
(
esettingspanel
,
-
1
,
_
(
"mm/
\n
min"
)),
pos
=
(
1
,
3
),
flag
=
wx
.
ALIGN_CENTER
)
esettingspanel
.
SetSizer
(
esettingssizer
)
esettingspanel
.
SetSizer
(
esettingssizer
)
self
.
Add
(
esettingspanel
,
pos
=
(
base_line
+
3
,
0
),
span
=
(
1
,
5
))
self
.
Add
(
esettingspanel
,
pos
=
(
base_line
+
3
,
0
),
span
=
(
1
,
5
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment