New guide type "Frame" for aiding in cropping dark photos against a dark preview background. Issue 1391
This commit is contained in:
parent
8c3347cd87
commit
c24f37258f
@ -838,6 +838,7 @@ TP_COLORSHIFT_LABEL;Color Shift
|
||||
TP_CROP_FIXRATIO;Fix Ratio:
|
||||
TP_CROP_GTDIAGONALS;Rule of diagonals
|
||||
TP_CROP_GTEPASSPORT;Biometric Passport
|
||||
TP_CROP_GTFRAME;Frame
|
||||
TP_CROP_GTGRID;Grid
|
||||
TP_CROP_GTHARMMEANS1;Harmonic means 1
|
||||
TP_CROP_GTHARMMEANS2;Harmonic means 2
|
||||
|
@ -186,6 +186,7 @@ Crop::Crop (): Gtk::VBox(), FoldableToolPanel(this) {
|
||||
guide->append_text (M("TP_CROP_GTHARMMEANS4"));
|
||||
guide->append_text (M("TP_CROP_GTGRID"));
|
||||
guide->append_text (M("TP_CROP_GTEPASSPORT"));
|
||||
guide->append_text (M("TP_CROP_GTFRAME"));
|
||||
guide->set_active (0);
|
||||
|
||||
w->set_range (0, maxw);
|
||||
@ -294,6 +295,8 @@ void Crop::read (const ProcParams* pp, const ParamsEdited* pedited) {
|
||||
guide->set_active (7);
|
||||
else if (pp->crop.guide == "ePassport")
|
||||
guide->set_active (8);
|
||||
else if (pp->crop.guide == "Frame")
|
||||
guide->set_active (9);
|
||||
|
||||
x->set_value (pp->crop.x);
|
||||
y->set_value (pp->crop.y);
|
||||
@ -376,12 +379,14 @@ void Crop::write (ProcParams* pp, ParamsEdited* pedited) {
|
||||
pp->crop.guide = "Grid";
|
||||
else if (guide->get_active_row_number()==8)
|
||||
pp->crop.guide = "ePassport";
|
||||
else if (guide->get_active_row_number()==9)
|
||||
pp->crop.guide = "Frame";
|
||||
|
||||
if (pedited) {
|
||||
pedited->crop.enabled = !enabled->get_inconsistent();
|
||||
pedited->crop.ratio = ratio->get_active_row_number() != 8;
|
||||
pedited->crop.ratio = ratio->get_active_row_number() != 9;
|
||||
pedited->crop.orientation = orientation->get_active_row_number() != 2;
|
||||
pedited->crop.guide = guide->get_active_row_number() != 8;
|
||||
pedited->crop.guide = guide->get_active_row_number() != 9;
|
||||
pedited->crop.fixratio = !fixr->get_inconsistent();
|
||||
pedited->crop.w = wDirty;
|
||||
pedited->crop.h = hDirty;
|
||||
|
Loading…
x
Reference in New Issue
Block a user