X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ffrontends%2Fxforms%2Fform_minipage.C;h=a4cc039bba8097e4c9d6fb06b45decf0a68659e0;hb=b9d61343fc76a681b0264d65703ef2119647df56;hp=25c0ab0fbd4295c56ed8c81d931e33ee405b6049;hpb=3de10d0174eb3859b0080026fbf39e9467da8b26;p=lyx.git diff --git a/src/frontends/xforms/form_minipage.C b/src/frontends/xforms/form_minipage.C index 25c0ab0fbd..a4cc039bba 100644 --- a/src/frontends/xforms/form_minipage.C +++ b/src/frontends/xforms/form_minipage.C @@ -25,33 +25,17 @@ FD_form_minipage * FormMinipage::build_minipage() fdui->form = fl_bgn_form(FL_NO_BOX, 430, 170); fdui->form->u_vdata = this; obj = fl_add_box(FL_FLAT_BOX, 0, 0, 430, 170, ""); - obj = fl_add_frame(FL_ENGRAVED_FRAME, 230, 20, 190, 100, ""); - fl_set_object_color(obj, FL_COL1, FL_COL1); - obj = fl_add_frame(FL_ENGRAVED_FRAME, 20, 20, 200, 100, ""); - fl_set_object_color(obj, FL_COL1, FL_COL1); - { - char const * const dummy = N_("Length|#L"); - fdui->input_width = obj = fl_add_input(FL_NORMAL_INPUT, 100, 30, 110, 30, idex(_(dummy))); - fl_set_button_shortcut(obj, scex(_(dummy)), 1); - } + obj = fl_add_labelframe(FL_ENGRAVED_FRAME, 20, 20, 200, 60, _("Width")); fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedInputCB, 0); - { - // xgettext:no-c-format - char const * const dummy = N_("or %|#o"); - fdui->input_widthp = obj = fl_add_input(FL_INT_INPUT, 100, 70, 110, 30, idex(_(dummy))); - fl_set_button_shortcut(obj, scex(_(dummy)), 1); - } - fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedInputCB, 0); - obj = fl_add_text(FL_NORMAL_TEXT, 30, 10, 100, 20, _("Width")); - fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE); fl_set_object_lstyle(obj, FL_BOLD_STYLE); - obj = fl_add_text(FL_NORMAL_TEXT, 240, 10, 140, 20, _("Alignment")); + obj = fl_add_labelframe(FL_ENGRAVED_FRAME, 240, 20, 180, 100, _("Alignment")); fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE); fl_set_object_lstyle(obj, FL_BOLD_STYLE); + fdui->input_width = obj = fl_add_input(FL_NORMAL_INPUT, 30, 30, 110, 30, ""); + fl_set_object_lsize(obj, FL_NORMAL_SIZE); + fl_set_object_callback(obj, C_FormBaseInputCB, 0); + fdui->choice_width_units = obj = fl_add_choice(FL_NORMAL_CHOICE2, 150, 30, 60, 30, ""); + fl_set_object_callback(obj, C_FormBaseInputCB, 0); fdui->group_alignment = fl_bgn_group(); { @@ -60,21 +44,21 @@ FD_form_minipage * FormMinipage::build_minipage() fl_set_button_shortcut(obj, scex(_(dummy)), 1); } fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedInputCB, 0); + fl_set_object_callback(obj, C_FormBaseInputCB, 0); { char const * const dummy = N_("Middle|#d"); fdui->radio_middle = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 249, 60, 152, 30, idex(_(dummy))); fl_set_button_shortcut(obj, scex(_(dummy)), 1); } fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedInputCB, 0); + fl_set_object_callback(obj, C_FormBaseInputCB, 0); { char const * const dummy = N_("Bottom|#B"); fdui->radio_bottom = obj = fl_add_checkbutton(FL_RADIO_BUTTON, 249, 90, 152, 30, idex(_(dummy))); fl_set_button_shortcut(obj, scex(_(dummy)), 1); } fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedInputCB, 0); + fl_set_object_callback(obj, C_FormBaseInputCB, 0); fl_end_group(); { @@ -83,24 +67,24 @@ FD_form_minipage * FormMinipage::build_minipage() fl_set_button_shortcut(obj, scex(_(dummy)), 1); } fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedCancelCB, 0); + fl_set_object_callback(obj, C_FormBaseCancelCB, 0); { char const * const dummy = N_("Apply|#A"); fdui->button_apply = obj = fl_add_button(FL_NORMAL_BUTTON, 230, 130, 90, 30, idex(_(dummy))); fl_set_button_shortcut(obj, scex(_(dummy)), 1); } fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedApplyCB, 0); + fl_set_object_callback(obj, C_FormBaseApplyCB, 0); fdui->button_ok = obj = fl_add_button(FL_RETURN_BUTTON, 130, 130, 90, 30, _("OK")); fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedOKCB, 0); + fl_set_object_callback(obj, C_FormBaseOKCB, 0); { char const * const dummy = N_("Restore|#R"); fdui->button_restore = obj = fl_add_button(FL_NORMAL_BUTTON, 10, 130, 90, 30, idex(_(dummy))); fl_set_button_shortcut(obj, scex(_(dummy)), 1); } fl_set_object_lsize(obj, FL_NORMAL_SIZE); - fl_set_object_callback(obj, C_FormBaseDeprecatedRestoreCB, 0); + fl_set_object_callback(obj, C_FormBaseRestoreCB, 0); fl_end_form(); fdui->form->fdui = fdui;