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
a94bf324
Commit
a94bf324
authored
Apr 05, 2014
by
Guillaume Seguin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remember sash positon #467
parent
1798313f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
2 deletions
+15
-2
__init__.py
printrun/gui/__init__.py
+4
-2
pronterface.py
printrun/pronterface.py
+11
-0
No files found.
printrun/gui/__init__.py
View file @
a94bf324
...
@@ -166,7 +166,8 @@ class MainWindow(wx.Frame):
...
@@ -166,7 +166,8 @@ class MainWindow(wx.Frame):
page2panel2
.
SetSizer
(
page2sizer2
)
page2panel2
.
SetSizer
(
page2sizer2
)
self
.
splitterwindow
.
SetMinimumPaneSize
(
1
)
self
.
splitterwindow
.
SetMinimumPaneSize
(
1
)
self
.
splitterwindow
.
SetSashGravity
(
0.5
)
self
.
splitterwindow
.
SetSashGravity
(
0.5
)
self
.
splitterwindow
.
SplitVertically
(
page2panel1
,
page2panel2
,
0
)
self
.
splitterwindow
.
SplitVertically
(
page2panel1
,
page2panel2
,
self
.
settings
.
last_sash_position
)
self
.
mainsizer
.
Add
(
self
.
splitterwindow
,
1
,
wx
.
EXPAND
)
self
.
mainsizer
.
Add
(
self
.
splitterwindow
,
1
,
wx
.
EXPAND
)
page1panel
.
SetSizer
(
self
.
mainsizer_page1
)
page1panel
.
SetSizer
(
self
.
mainsizer_page1
)
page2panel
.
SetSizer
(
self
.
mainsizer
)
page2panel
.
SetSizer
(
self
.
mainsizer
)
...
@@ -223,7 +224,8 @@ class MainWindow(wx.Frame):
...
@@ -223,7 +224,8 @@ class MainWindow(wx.Frame):
rightsizer
.
Add
(
self
.
splitterwindow
,
1
,
wx
.
EXPAND
)
rightsizer
.
Add
(
self
.
splitterwindow
,
1
,
wx
.
EXPAND
)
vizpanel
=
self
.
newPanel
(
self
.
splitterwindow
)
vizpanel
=
self
.
newPanel
(
self
.
splitterwindow
)
logpanel
=
self
.
newPanel
(
self
.
splitterwindow
)
logpanel
=
self
.
newPanel
(
self
.
splitterwindow
)
self
.
splitterwindow
.
SplitVertically
(
vizpanel
,
logpanel
,
0
)
self
.
splitterwindow
.
SplitVertically
(
vizpanel
,
logpanel
,
self
.
settings
.
last_sash_position
)
self
.
splitterwindow
.
shrinked
=
False
self
.
splitterwindow
.
shrinked
=
False
else
:
else
:
vizpanel
=
self
.
newPanel
(
lowerpanel
)
vizpanel
=
self
.
newPanel
(
lowerpanel
)
...
...
printrun/pronterface.py
View file @
a94bf324
...
@@ -276,6 +276,16 @@ class PronterWindow(MainWindow, pronsole.pronsole):
...
@@ -276,6 +276,16 @@ class PronterWindow(MainWindow, pronsole.pronsole):
self
.
createGui
(
self
.
settings
.
uimode
==
"Compact"
,
self
.
createGui
(
self
.
settings
.
uimode
==
"Compact"
,
self
.
settings
.
controlsmode
==
"Mini"
)
self
.
settings
.
controlsmode
==
"Mini"
)
if
hasattr
(
self
,
"splitterwindow"
):
def
splitter_resize
(
event
):
self
.
splitterwindow
.
UpdateSize
()
self
.
splitterwindow
.
Bind
(
wx
.
EVT_SIZE
,
splitter_resize
)
def
sash_position_changed
(
event
):
self
.
set
(
"last_sash_position"
,
self
.
splitterwindow
.
GetSashPosition
())
self
.
splitterwindow
.
Bind
(
wx
.
EVT_SPLITTER_SASH_POS_CHANGED
,
sash_position_changed
)
# Set gcview parameters here as they don't get set when viewers are
# Set gcview parameters here as they don't get set when viewers are
# created
# created
self
.
update_gcview_params
()
self
.
update_gcview_params
()
...
@@ -830,6 +840,7 @@ Printrun. If not, see <http://www.gnu.org/licenses/>."""
...
@@ -830,6 +840,7 @@ Printrun. If not, see <http://www.gnu.org/licenses/>."""
self
.
settings
.
_add
(
HiddenSetting
(
"last_window_width"
,
size
[
0
]))
self
.
settings
.
_add
(
HiddenSetting
(
"last_window_width"
,
size
[
0
]))
self
.
settings
.
_add
(
HiddenSetting
(
"last_window_height"
,
size
[
1
]))
self
.
settings
.
_add
(
HiddenSetting
(
"last_window_height"
,
size
[
1
]))
self
.
settings
.
_add
(
HiddenSetting
(
"last_window_maximized"
,
False
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_window_maximized"
,
False
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_sash_position"
,
-
1
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_bed_temperature"
,
0.0
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_bed_temperature"
,
0.0
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_file_path"
,
u""
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_file_path"
,
u""
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_temperature"
,
0.0
))
self
.
settings
.
_add
(
HiddenSetting
(
"last_temperature"
,
0.0
))
...
...
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