mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 23:17:35 -06:00
New fill types (hilbertcurve, archimedeanchords, octagramspiral) and ability to use different patterns for solid layers. #20
This commit is contained in:
parent
041e9877a3
commit
038caddcda
22 changed files with 391 additions and 93 deletions
|
@ -3,7 +3,7 @@ use strict;
|
|||
use warnings;
|
||||
|
||||
use Wx qw(:sizer);
|
||||
use Wx::Event qw(EVT_TEXT EVT_CHECKBOX);
|
||||
use Wx::Event qw(EVT_TEXT EVT_CHECKBOX EVT_CHOICE);
|
||||
use base 'Wx::StaticBoxSizer';
|
||||
|
||||
# not very elegant, but this solution is temporary waiting for a better GUI
|
||||
|
@ -55,6 +55,14 @@ sub new {
|
|||
$x_field->SetValue($value->[0]);
|
||||
$y_field->SetValue($value->[1]);
|
||||
};
|
||||
} elsif ($opt->{type} eq 'select') {
|
||||
$field = Wx::Choice->new($parent, -1, Wx::wxDefaultPosition, Wx::wxDefaultSize, $opt->{values});
|
||||
EVT_CHOICE($parent, $field, sub { Slic3r::Config->set($opt_key, $opt->{values}[$field->GetSelection]) });
|
||||
push @reload_callbacks, sub {
|
||||
my $value = Slic3r::Config->get($opt_key);
|
||||
$field->SetSelection(grep $opt->{values}[$_] eq $value, 0..$#{$opt->{values}});
|
||||
};
|
||||
$reload_callbacks[-1]->();
|
||||
} else {
|
||||
die "Unsupported option type: " . $opt->{type};
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ sub new {
|
|||
),
|
||||
print => Slic3r::GUI::OptionsGroup->new($self,
|
||||
title => 'Print settings',
|
||||
options => [qw(perimeter_offsets solid_layers fill_density fill_angle)],
|
||||
options => [qw(perimeter_offsets solid_layers fill_density fill_angle fill_pattern solid_fill_pattern)],
|
||||
),
|
||||
retract => Slic3r::GUI::OptionsGroup->new($self,
|
||||
title => 'Retraction',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue