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
357f4810
Commit
357f4810
authored
Apr 21, 2016
by
Kliment Yanev
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:kliment/Printrun
parents
25ebd660
cd9cfc7c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
78 additions
and
26 deletions
+78
-26
plater.po
locale/ar/LC_MESSAGES/plater.po
+25
-24
controls.py
printrun/gui/controls.py
+38
-2
pronterface.py
printrun/pronterface.py
+15
-0
No files found.
locale/
plater.pot
→
locale/
ar/LC_MESSAGES/plater.po
View file @
357f4810
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR ORGANIZATION
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2012-08-04 21:53+CEST\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Project-Id-Version:Plater\n"
"POT-Creation-Date: 2012-01-09 15:07+CET\n"
"PO-Revision-Date: 2015-06-25 07:49+0300\n"
"Last-Translator: سـند <0sanad0@gmail.com>\n"
"Language-Team: < http://linuxac.org ســ <مجتمع لينكس العربي\n"
"Language: ar\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: ENCODING\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 "
"&& n%100<=10 ? 3 : n%100>=11 ? 4 : 5;\n"
"X-Generator: Virtaal 0.7.1\n"
"Generated-By: pygettext.py 1.5\n"
#: plater.py:246
msgid "Plate building tool"
msgstr ""
msgstr "
أداة بناء اللوحة
"
#: plater.py:252
msgid "Clear"
...
...
@@ -25,19 +25,19 @@ msgstr ""
#: plater.py:253
msgid "Load"
msgstr ""
msgstr "
تحميل
"
#: plater.py:255 plater.py:258
msgid "Export"
msgstr ""
msgstr "
تصدير
"
#: plater.py:260
msgid "Done"
msgstr ""
msgstr "
حرر؛ عمل
"
#: plater.py:262
msgid "Cancel"
msgstr ""
msgstr "
الغِ
"
#: plater.py:264
msgid "Snap to Z = 0"
...
...
@@ -49,15 +49,15 @@ msgstr ""
#: plater.py:266
msgid "Delete"
msgstr ""
msgstr "
حذف
"
#: plater.py:267
msgid "Auto"
msgstr ""
msgstr "
تلقائي
"
#: plater.py:291
msgid "Autoplating"
msgstr "
"
msgstr "
#: plater.py:319
msgid "Bed full, sorry sir :("
...
...
@@ -66,6 +66,8 @@ msgstr ""
#: plater.py:329
msgid "Are you sure you want to clear the grid? All unsaved changes will be lost."
msgstr ""
"هل أنت متأكد من أنك تريد مسح الشبكة؟ سيتم فقدان كافة التغييرات التي لم يتم "
"حفظها."
#: plater.py:329
msgid "Clear the grid?"
...
...
@@ -77,11 +79,11 @@ msgstr ""
#: plater.py:372
msgid "STL files (;*.stl;*.STL;)"
msgstr ""
msgstr "
ملفات STL (;*.stl;*.STL;)
"
#: plater.py:393
msgid "wrote %s"
msgstr ""
msgstr "
كتب %s
"
#: plater.py:396
msgid "Pick file to load"
...
...
@@ -89,5 +91,4 @@ msgstr ""
#: plater.py:397
msgid "STL files (;*.stl;*.STL;)|*.stl|OpenSCAD files (;*.scad;)|*.scad"
msgstr ""
msgstr "ملغات STL (;*.stl;*.STL;)|*.stl|OpenSCAD files (;*.scad;)|*.scad"
printrun/gui/controls.py
View file @
357f4810
...
...
@@ -41,9 +41,9 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None, mini_mode
if
standalone_mode
:
gauges_base_line
=
base_line
+
10
elif
mini_mode
and
root
.
display_graph
:
gauges_base_line
=
base_line
+
6
gauges_base_line
=
base_line
+
7
else
:
gauges_base_line
=
base_line
+
5
gauges_base_line
=
base_line
+
6
tempdisp_line
=
gauges_base_line
+
(
2
if
root
.
display_gauges
else
0
)
if
mini_mode
and
root
.
display_graph
:
e_base_line
=
base_line
+
3
...
...
@@ -62,6 +62,7 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None, mini_mode
"ebuttons"
:
(
e_base_line
+
0
,
0
),
"esettings"
:
(
e_base_line
+
1
,
0
),
"speedcontrol"
:
(
e_base_line
+
2
,
0
),
"flowcontrol"
:
(
e_base_line
+
3
,
0
),
"htemp_gauge"
:
(
gauges_base_line
+
0
,
0
),
"btemp_gauge"
:
(
gauges_base_line
+
1
,
0
),
"tempdisp"
:
(
tempdisp_line
,
0
),
...
...
@@ -81,6 +82,7 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None, mini_mode
"ebuttons"
:
(
1
,
5
if
root
.
display_graph
else
6
),
"esettings"
:
(
1
,
5
if
root
.
display_graph
else
6
),
"speedcontrol"
:
(
1
,
5
if
root
.
display_graph
else
6
),
"flowcontrol"
:
(
1
,
5
if
root
.
display_graph
else
6
),
"htemp_gauge"
:
(
1
,
5
if
mini_mode
else
6
),
"btemp_gauge"
:
(
1
,
5
if
mini_mode
else
6
),
"tempdisp"
:
(
1
,
5
if
mini_mode
else
6
),
...
...
@@ -218,6 +220,40 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None, mini_mode
root
.
speed_spin
.
SetValue
(
value
)
root
.
speed_slider
.
Bind
(
wx
.
EVT_SCROLL
,
speedslider_scroll
)
# Flow control #
flowpanel
=
root
.
newPanel
(
parentpanel
)
flowsizer
=
wx
.
BoxSizer
(
wx
.
HORIZONTAL
)
flowsizer
.
Add
(
wx
.
StaticText
(
flowpanel
,
-
1
,
_
(
"Print flow:"
)),
flag
=
wx
.
ALIGN_CENTER_VERTICAL
|
wx
.
ALIGN_RIGHT
)
root
.
flow_slider
=
wx
.
Slider
(
flowpanel
,
-
1
,
100
,
1
,
300
)
flowsizer
.
Add
(
root
.
flow_slider
,
1
,
flag
=
wx
.
EXPAND
)
root
.
flow_spin
=
FloatSpin
(
flowpanel
,
-
1
,
value
=
100
,
min_val
=
1
,
max_val
=
300
,
digits
=
0
,
style
=
wx
.
ALIGN_LEFT
,
size
=
(
60
,
-
1
))
flowsizer
.
Add
(
root
.
flow_spin
,
0
,
flag
=
wx
.
ALIGN_CENTER_VERTICAL
)
root
.
flow_label
=
wx
.
StaticText
(
flowpanel
,
-
1
,
_
(
"
%
"
))
flowsizer
.
Add
(
root
.
flow_label
,
flag
=
wx
.
ALIGN_CENTER_VERTICAL
|
wx
.
ALIGN_RIGHT
)
def
flowslider_set
(
event
):
root
.
do_setflow
()
root
.
flow_setbtn
.
SetBackgroundColour
(
wx
.
NullColour
)
root
.
flow_setbtn
=
make_button
(
flowpanel
,
_
(
"Set"
),
flowslider_set
,
_
(
"Set print flow factor"
),
size
=
(
38
,
-
1
),
style
=
wx
.
BU_EXACTFIT
)
root
.
printerControls
.
append
(
root
.
flow_setbtn
)
flowsizer
.
Add
(
root
.
flow_setbtn
,
flag
=
wx
.
ALIGN_CENTER
)
flowpanel
.
SetSizer
(
flowsizer
)
add
(
"flowcontrol"
,
flowpanel
,
flag
=
wx
.
EXPAND
)
def
flowslider_spin
(
event
):
value
=
root
.
flow_spin
.
GetValue
()
root
.
flow_setbtn
.
SetBackgroundColour
(
"red"
)
root
.
flow_slider
.
SetValue
(
value
)
root
.
flow_spin
.
Bind
(
wx
.
EVT_SPINCTRL
,
flowslider_spin
)
def
flowslider_scroll
(
event
):
value
=
root
.
flow_slider
.
GetValue
()
root
.
flow_setbtn
.
SetBackgroundColour
(
"red"
)
root
.
flow_spin
.
SetValue
(
value
)
root
.
flow_slider
.
Bind
(
wx
.
EVT_SCROLL
,
flowslider_scroll
)
# Temperature gauges #
if
root
.
display_gauges
:
...
...
printrun/pronterface.py
View file @
357f4810
...
...
@@ -438,6 +438,21 @@ class PronterWindow(MainWindow, pronsole.pronsole):
except
Exception
,
x
:
self
.
logError
(
_
(
"You must enter a speed. (
%
s)"
)
%
(
repr
(
x
),))
def
do_setflow
(
self
,
l
=
""
):
try
:
if
l
.
__class__
not
in
(
str
,
unicode
)
or
not
len
(
l
):
l
=
str
(
self
.
flow_slider
.
GetValue
())
else
:
l
=
l
.
lower
()
flow
=
int
(
l
)
if
self
.
p
.
online
:
self
.
p
.
send_now
(
"M221 S"
+
l
)
self
.
log
(
_
(
"Setting print flow factor to
%
d
%%
."
)
%
flow
)
else
:
self
.
logError
(
_
(
"Printer is not online."
))
except
Exception
,
x
:
self
.
logError
(
_
(
"You must enter a flow. (
%
s)"
)
%
(
repr
(
x
),))
def
setbedgui
(
self
,
f
):
self
.
bsetpoint
=
f
if
self
.
display_gauges
:
self
.
bedtgauge
.
SetTarget
(
int
(
f
))
...
...
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