diff --git a/src/frontends/xforms/ChangeLog b/src/frontends/xforms/ChangeLog index bbef2c0bca..bb8bac6e05 100644 --- a/src/frontends/xforms/ChangeLog +++ b/src/frontends/xforms/ChangeLog @@ -1,3 +1,8 @@ +2001-02-21 Dekel Tsur + + * FormDocument.C (checkMarginValues): Activate "use geometry" button + if using custom paper size/margin. + 2001-02-21 Allan Rae * forms/form_preferences.fd: larger, bold font for outer tabfolder diff --git a/src/frontends/xforms/FormDocument.C b/src/frontends/xforms/FormDocument.C index dfd80357dd..2953743035 100644 --- a/src/frontends/xforms/FormDocument.C +++ b/src/frontends/xforms/FormDocument.C @@ -835,19 +835,18 @@ void FormDocument::checkReadOnly() void FormDocument::checkMarginValues() { -#if 0 - int const allEmpty = (!strlen(fl_get_input(paper_->input_top_margin)) && - !strlen(fl_get_input(paper_->input_bottom_margin)) && - !strlen(fl_get_input(paper_->input_left_margin)) && - !strlen(fl_get_input(paper_->input_right_margin)) && - !strlen(fl_get_input(paper_->input_head_height)) && - !strlen(fl_get_input(paper_->input_head_sep)) && - !strlen(fl_get_input(paper_->input_foot_skip)) && - !strlen(fl_get_input(paper_->input_custom_width)) && - !strlen(fl_get_input(paper_->input_custom_height))); - if (!allEmpty) - fl_set_button(paper_->push_use_geometry, 1); -#endif + bool const not_empty = + strlen(fl_get_input(paper_->input_top_margin)) || + strlen(fl_get_input(paper_->input_bottom_margin)) || + strlen(fl_get_input(paper_->input_left_margin)) || + strlen(fl_get_input(paper_->input_right_margin)) || + strlen(fl_get_input(paper_->input_head_height)) || + strlen(fl_get_input(paper_->input_head_sep)) || + strlen(fl_get_input(paper_->input_foot_skip)) || + strlen(fl_get_input(paper_->input_custom_width)) || + strlen(fl_get_input(paper_->input_custom_height)); + if (not_empty) + fl_set_button(paper_->push_use_geometry, 1); }