From: Angus Leeming Date: Mon, 25 Mar 2002 11:16:15 +0000 (+0000) Subject: Change the name of some methods and some widgets. X-Git-Tag: 1.6.10~19579 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=67fbbc0fb2030284834ba1fe37c899769e96ec88;p=features.git Change the name of some methods and some widgets. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@3822 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/xforms/ChangeLog b/src/frontends/xforms/ChangeLog index 9dc43817a8..d0f220596f 100644 --- a/src/frontends/xforms/ChangeLog +++ b/src/frontends/xforms/ChangeLog @@ -4,6 +4,13 @@ * xforms_helpers.C: rearrange #includes. + * RadioButtonGroup.[Ch]: rename some of the methods. Remove #if 0 code. + + * FormPrint.C: changes associated with changes to RadioButtonGroup. + + * FormGraphics.C: + * forms/form_graphics.fd: rename some of the widgets. + 2002-03-22 Angus Leeming * FormGraphics.C (input): don't activate the Ok, Apply buttons if the diff --git a/src/frontends/xforms/FormGraphics.C b/src/frontends/xforms/FormGraphics.C index 75112a4f85..7c056de5d2 100644 --- a/src/frontends/xforms/FormGraphics.C +++ b/src/frontends/xforms/FormGraphics.C @@ -118,8 +118,8 @@ void FormGraphics::build() setPrehandler(lyxview_->input_lyxheight); setPrehandler(lyxview_->input_lyxscale); - fl_addto_choice(lyxview_->choice_width_lyxwidth, choice_Length_WithUnit.c_str()); - fl_addto_choice(lyxview_->choice_width_lyxheight, choice_Length_WithUnit.c_str()); + fl_addto_choice(lyxview_->choice_lyxwidth, choice_Length_WithUnit.c_str()); + fl_addto_choice(lyxview_->choice_lyxheight, choice_Length_WithUnit.c_str()); bc().addReadOnly(lyxview_->radio_pref); bc().addReadOnly(lyxview_->radio_mono); @@ -144,8 +144,8 @@ void FormGraphics::build() fl_set_input_filter(size_->input_scale, fl_unsigned_float_filter); - fl_addto_choice(size_->choice_width_units, choice_Length_All.c_str()); - fl_addto_choice(size_->choice_height_units, choice_Length_All.c_str()); + fl_addto_choice(size_->choice_width, choice_Length_All.c_str()); + fl_addto_choice(size_->choice_height, choice_Length_All.c_str()); bc().addReadOnly(size_->radio_asis); bc().addReadOnly(size_->radio_wh); @@ -238,10 +238,10 @@ void FormGraphics::apply() igp.lyxsize_type = InsetGraphicsParams::SCALE; igp.lyxwidth = getLyXLengthFromWidgets(lyxview_->input_lyxwidth, - lyxview_->choice_width_lyxwidth); + lyxview_->choice_lyxwidth); igp.lyxheight = getLyXLengthFromWidgets(lyxview_->input_lyxheight, - lyxview_->choice_width_lyxheight); + lyxview_->choice_lyxheight); igp.lyxscale = strToInt(getStringFromInput(lyxview_->input_lyxscale)); @@ -254,10 +254,10 @@ void FormGraphics::apply() igp.size_type = InsetGraphicsParams::SCALE; igp.width = getLyXLengthFromWidgets(size_->input_width, - size_->choice_width_units); + size_->choice_width); igp.height = getLyXLengthFromWidgets(size_->input_height, - size_->choice_height_units); + size_->choice_height); igp.scale = strToInt(getStringFromInput(size_->input_scale)); igp.keepAspectRatio = fl_get_button(size_->check_aspectratio); @@ -339,35 +339,35 @@ void FormGraphics::update() { break; } updateWidgetsFromLength(lyxview_->input_lyxwidth, - lyxview_->choice_width_lyxwidth, igp.lyxwidth, defaultUnit); + lyxview_->choice_lyxwidth, igp.lyxwidth, defaultUnit); updateWidgetsFromLength(lyxview_->input_lyxheight, - lyxview_->choice_width_lyxheight, igp.lyxheight, defaultUnit); + lyxview_->choice_lyxheight, igp.lyxheight, defaultUnit); fl_set_input(lyxview_->input_lyxscale, tostr(igp.lyxscale).c_str()); switch (igp.lyxsize_type) { case InsetGraphicsParams::DEFAULT_SIZE: { fl_set_button(lyxview_->radio_lyxasis,1); setEnabled(lyxview_->input_lyxwidth, 0); - setEnabled(lyxview_->choice_width_lyxwidth, 0); + setEnabled(lyxview_->choice_lyxwidth, 0); setEnabled(lyxview_->input_lyxheight, 0); - setEnabled(lyxview_->choice_width_lyxheight, 0); + setEnabled(lyxview_->choice_lyxheight, 0); setEnabled(lyxview_->input_lyxscale, 0); break; } case InsetGraphicsParams::WH: { fl_set_button(lyxview_->radio_lyxwh, 1); setEnabled(lyxview_->input_lyxwidth, 1); - setEnabled(lyxview_->choice_width_lyxwidth, 1); + setEnabled(lyxview_->choice_lyxwidth, 1); setEnabled(lyxview_->input_lyxheight, 1); - setEnabled(lyxview_->choice_width_lyxheight, 1); + setEnabled(lyxview_->choice_lyxheight, 1); setEnabled(lyxview_->input_lyxscale, 0); break; } case InsetGraphicsParams::SCALE: { fl_set_button(lyxview_->radio_lyxscale, 1); setEnabled(lyxview_->input_lyxwidth, 0); - setEnabled(lyxview_->choice_width_lyxwidth, 0); + setEnabled(lyxview_->choice_lyxwidth, 0); setEnabled(lyxview_->input_lyxheight, 0); - setEnabled(lyxview_->choice_width_lyxheight, 0); + setEnabled(lyxview_->choice_lyxheight, 0); setEnabled(lyxview_->input_lyxscale, 1); break; } @@ -376,17 +376,17 @@ void FormGraphics::update() { // the size section // Update the draft and clip mode updateWidgetsFromLength(size_->input_width, - size_->choice_width_units, igp.width, defaultUnit); + size_->choice_width, igp.width, defaultUnit); updateWidgetsFromLength(size_->input_height, - size_->choice_height_units, igp.height, defaultUnit); + size_->choice_height, igp.height, defaultUnit); fl_set_input(size_->input_scale, tostr(igp.scale).c_str()); switch (igp.size_type) { case InsetGraphicsParams::DEFAULT_SIZE: { fl_set_button(size_->radio_asis,1); setEnabled(size_->input_width, 0); - setEnabled(size_->choice_width_units, 0); + setEnabled(size_->choice_width, 0); setEnabled(size_->input_height, 0); - setEnabled(size_->choice_height_units, 0); + setEnabled(size_->choice_height, 0); setEnabled(size_->check_aspectratio, 0); setEnabled(size_->input_scale, 0); break; @@ -394,9 +394,9 @@ void FormGraphics::update() { case InsetGraphicsParams::WH: { fl_set_button(size_->radio_wh, 1); setEnabled(size_->input_width, 1); - setEnabled(size_->choice_width_units, 1); + setEnabled(size_->choice_width, 1); setEnabled(size_->input_height, 1); - setEnabled(size_->choice_height_units, 1); + setEnabled(size_->choice_height, 1); setEnabled(size_->check_aspectratio, 1); setEnabled(size_->input_scale, 0); break; @@ -404,9 +404,9 @@ void FormGraphics::update() { case InsetGraphicsParams::SCALE: { fl_set_button(size_->radio_scale, 1); setEnabled(size_->input_width, 0); - setEnabled(size_->choice_width_units, 0); + setEnabled(size_->choice_width, 0); setEnabled(size_->input_height, 0); - setEnabled(size_->choice_height_units, 0); + setEnabled(size_->choice_height, 0); setEnabled(size_->check_aspectratio, 0); setEnabled(size_->input_scale, 1); break; @@ -503,62 +503,62 @@ ButtonPolicy::SMInput FormGraphics::input(FL_OBJECT * ob, long) // the lyxview section } else if (ob == lyxview_->radio_lyxasis) { setEnabled(lyxview_->input_lyxwidth, 0); - setEnabled(lyxview_->choice_width_lyxwidth, 0); + setEnabled(lyxview_->choice_lyxwidth, 0); setEnabled(lyxview_->input_lyxheight, 0); - setEnabled(lyxview_->choice_width_lyxheight, 0); + setEnabled(lyxview_->choice_lyxheight, 0); setEnabled(lyxview_->input_lyxscale, 0); } else if (ob == lyxview_->radio_lyxwh) { setEnabled(lyxview_->input_lyxwidth, 1); - setEnabled(lyxview_->choice_width_lyxwidth, 1); + setEnabled(lyxview_->choice_lyxwidth, 1); setEnabled(lyxview_->input_lyxheight, 1); - setEnabled(lyxview_->choice_width_lyxheight, 1); + setEnabled(lyxview_->choice_lyxheight, 1); setEnabled(lyxview_->input_lyxscale, 0); } else if (ob == lyxview_->radio_lyxscale) { setEnabled(lyxview_->input_lyxwidth, 0); - setEnabled(lyxview_->choice_width_lyxwidth, 0); + setEnabled(lyxview_->choice_lyxwidth, 0); setEnabled(lyxview_->input_lyxheight, 0); - setEnabled(lyxview_->choice_width_lyxheight, 0); + setEnabled(lyxview_->choice_lyxheight, 0); setEnabled(lyxview_->input_lyxscale, 1); } else if (ob == lyxview_->button_latex_values) { - if (contains(fl_get_choice_text(size_->choice_width_units),'%')) + if (contains(fl_get_choice_text(size_->choice_width),'%')) Alert::alert(_("Warning!"), _("The units t%, p%, c% and l% are not allowed here."), _("Cannot use the values from LaTeX size!")); else { LyXLength dummy = getLyXLengthFromWidgets(size_->input_width, - size_->choice_width_units); + size_->choice_width); updateWidgetsFromLength(lyxview_->input_lyxwidth, - lyxview_->choice_width_lyxwidth, + lyxview_->choice_lyxwidth, dummy, defaultUnit); dummy = getLyXLengthFromWidgets(size_->input_height, - size_->choice_height_units); + size_->choice_height); updateWidgetsFromLength(lyxview_->input_lyxheight, - lyxview_->choice_width_lyxheight, + lyxview_->choice_lyxheight, dummy, defaultUnit); string const scale = getStringFromInput(size_->input_scale); fl_set_input(lyxview_->input_lyxscale, scale.c_str()); if (fl_get_button (size_->radio_asis) == 1) { fl_set_button (lyxview_->radio_lyxasis, 1); setEnabled(lyxview_->input_lyxwidth, 0); - setEnabled(lyxview_->choice_width_lyxwidth, 0); + setEnabled(lyxview_->choice_lyxwidth, 0); setEnabled(lyxview_->input_lyxheight, 0); - setEnabled(lyxview_->choice_width_lyxheight, 0); + setEnabled(lyxview_->choice_lyxheight, 0); setEnabled(lyxview_->input_lyxscale, 0); } else if (fl_get_button (size_->radio_wh) == 1) { fl_set_button (lyxview_->radio_lyxwh, 1); setEnabled(lyxview_->input_lyxwidth, 1); - setEnabled(lyxview_->choice_width_lyxwidth, 1); + setEnabled(lyxview_->choice_lyxwidth, 1); setEnabled(lyxview_->input_lyxheight, 1); - setEnabled(lyxview_->choice_width_lyxheight, 1); + setEnabled(lyxview_->choice_lyxheight, 1); setEnabled(lyxview_->input_lyxscale, 0); } else if (fl_get_button (size_->radio_scale) ==1) { fl_set_button (lyxview_->radio_lyxscale, 1); setEnabled(lyxview_->input_lyxwidth, 0); - setEnabled(lyxview_->choice_width_lyxwidth, 0); + setEnabled(lyxview_->choice_lyxwidth, 0); setEnabled(lyxview_->input_lyxheight, 0); - setEnabled(lyxview_->choice_width_lyxheight, 0); + setEnabled(lyxview_->choice_lyxheight, 0); setEnabled(lyxview_->input_lyxscale, 1); } } @@ -594,60 +594,60 @@ ButtonPolicy::SMInput FormGraphics::input(FL_OBJECT * ob, long) // the size section } else if (ob == size_->radio_asis) { setEnabled(size_->input_width, 0); - setEnabled(size_->choice_width_units, 0); + setEnabled(size_->choice_width, 0); setEnabled(size_->input_height, 0); - setEnabled(size_->choice_height_units, 0); + setEnabled(size_->choice_height, 0); setEnabled(size_->check_aspectratio, 0); setEnabled(size_->input_scale, 0); } else if (ob == size_->radio_wh) { setEnabled(size_->input_width, 1); - setEnabled(size_->choice_width_units, 1); + setEnabled(size_->choice_width, 1); setEnabled(size_->input_height, 1); - setEnabled(size_->choice_height_units, 1); + setEnabled(size_->choice_height, 1); setEnabled(size_->check_aspectratio, 1); setEnabled(size_->input_scale, 0); } else if (ob == size_->radio_scale) { setEnabled(size_->input_width, 0); - setEnabled(size_->choice_width_units, 0); + setEnabled(size_->choice_width, 0); setEnabled(size_->input_height, 0); - setEnabled(size_->choice_height_units, 0); + setEnabled(size_->choice_height, 0); setEnabled(size_->check_aspectratio, 0); setEnabled(size_->input_scale, 1); } else if (ob == size_->button_lyx_values) { LyXLength dummy = getLyXLengthFromWidgets(lyxview_->input_lyxwidth, - lyxview_->choice_width_lyxwidth); + lyxview_->choice_lyxwidth); updateWidgetsFromLength(size_->input_width, - size_->choice_width_units, + size_->choice_width, dummy, defaultUnit); dummy = getLyXLengthFromWidgets(lyxview_->input_lyxheight, - lyxview_->choice_width_lyxheight); + lyxview_->choice_lyxheight); updateWidgetsFromLength(size_->input_height, - size_->choice_height_units, + size_->choice_height, dummy, defaultUnit); string const scale = getStringFromInput(lyxview_->input_lyxscale); fl_set_input(size_->input_scale, scale.c_str()); if (fl_get_button (lyxview_->radio_lyxasis) == 1) { fl_set_button (size_->radio_asis, 1); setEnabled(size_->input_width, 0); - setEnabled(size_->choice_width_units, 0); + setEnabled(size_->choice_width, 0); setEnabled(size_->input_height, 0); - setEnabled(size_->choice_height_units, 0); + setEnabled(size_->choice_height, 0); setEnabled(size_->check_aspectratio, 0); setEnabled(size_->input_scale, 0); } else if (fl_get_button (lyxview_->radio_lyxwh) == 1) { fl_set_button (size_->radio_wh, 1); setEnabled(size_->input_width, 1); - setEnabled(size_->choice_width_units, 1); + setEnabled(size_->choice_width, 1); setEnabled(size_->input_height, 1); - setEnabled(size_->choice_height_units, 1); + setEnabled(size_->choice_height, 1); setEnabled(size_->check_aspectratio, 1); setEnabled(size_->input_scale, 0); } else if (fl_get_button (lyxview_->radio_lyxscale) ==1) { fl_set_button (size_->radio_scale, 1); setEnabled(size_->input_width, 0); - setEnabled(size_->choice_width_units, 0); + setEnabled(size_->choice_width, 0); setEnabled(size_->input_height, 0); - setEnabled(size_->choice_height_units, 0); + setEnabled(size_->choice_height, 0); setEnabled(size_->check_aspectratio, 0); setEnabled(size_->input_scale, 1); } diff --git a/src/frontends/xforms/FormPrint.C b/src/frontends/xforms/FormPrint.C index 5343c22d4f..340424dfbc 100644 --- a/src/frontends/xforms/FormPrint.C +++ b/src/frontends/xforms/FormPrint.C @@ -80,29 +80,22 @@ void FormPrint::build() fl_set_input_maxchars(dialog_->input_count, 4); // 9999 target_.reset(); - target_.registerRadioButton(dialog_->radio_printer, - PrinterParams::PRINTER); - target_.registerRadioButton(dialog_->radio_file, - PrinterParams::FILE); + target_.init(dialog_->radio_printer, PrinterParams::PRINTER); + target_.init(dialog_->radio_file, PrinterParams::FILE); order_.reset(); - order_.registerRadioButton(dialog_->radio_order_reverse, - true); - order_.registerRadioButton(dialog_->radio_order_normal, - false); + order_.init(dialog_->radio_order_reverse, true); + order_.init(dialog_->radio_order_normal, false); which_.reset(); - which_.registerRadioButton(dialog_->radio_odd_pages, - PrinterParams::ODD); - which_.registerRadioButton(dialog_->radio_even_pages, - PrinterParams::EVEN); - which_.registerRadioButton(dialog_->radio_all_pages, - PrinterParams::ALL); + which_.init(dialog_->radio_odd_pages, PrinterParams::ODD); + which_.init(dialog_->radio_even_pages, PrinterParams::EVEN); + which_.init(dialog_->radio_all_pages, PrinterParams::ALL); } void FormPrint::apply() { PrinterParams::WhichPages - wp(static_cast(which_.getButton())); + wp(static_cast(which_.get())); string from; int to(0); @@ -116,13 +109,13 @@ void FormPrint::apply() } PrinterParams::Target - t(static_cast(target_.getButton())); + t(static_cast(target_.get())); PrinterParams const pp(t, string(fl_get_input(dialog_->input_printer)), string(fl_get_input(dialog_->input_file)), wp, from, to, - static_cast(order_.getButton()), + static_cast(order_.get()), !static_cast(fl_get_button(dialog_->check_collated)), strToInt(fl_get_input(dialog_->input_count))); @@ -137,9 +130,9 @@ void FormPrint::update() fl_set_input(dialog_->input_printer, pp.printer_name.c_str()); fl_set_input(dialog_->input_file, pp.file_name.c_str()); - target_.setButton(pp.target); - order_.setButton(pp.reverse_order); - which_.setButton(pp.which_pages); + target_.set(pp.target); + order_.set(pp.reverse_order); + which_.set(pp.which_pages); // hmmm... maybe a bit weird but maybe not // we might just be remembering the last diff --git a/src/frontends/xforms/RadioButtonGroup.C b/src/frontends/xforms/RadioButtonGroup.C index 4e0868db7d..e572c3a631 100644 --- a/src/frontends/xforms/RadioButtonGroup.C +++ b/src/frontends/xforms/RadioButtonGroup.C @@ -28,7 +28,7 @@ using std::find_if; using std::endl; -void RadioButtonGroup::registerRadioButton(FL_OBJECT *button, int value) +void RadioButtonGroup::init(FL_OBJECT *button, size_type value) { map.push_back(ButtonValuePair(button, value)); } @@ -40,43 +40,11 @@ void RadioButtonGroup::reset() } -#if 0 -// Functor to help us in our work, we should try to find how to achieve -// this with only STL predicates, but its easier to write this than to -// dig. If you can find the equivalent STL predicate combination, let me -// know. -// -// The idea is to take a pair and a value and return true when the second -// element in the pair equals the value. -template < typename T > -struct equal_to_second_in_pair +void RadioButtonGroup::set(size_type value) { - typedef bool result_type; - typedef T first_argument_type; - typedef typename T::second_type second_argument_type; - - bool operator() ( - pair < typename T::first_type, typename T::second_type > const & left, - typename T::second_type const & right) const - { - return left.second == right; - } -}; -#endif - - -void RadioButtonGroup::setButton(int value) -{ -#if 0 - ButtonValueMap::const_iterator it = - find_if(map.begin(), map.end(), - bind2nd(equal_to_second_in_pair(), - value)); -#else ButtonValueMap::const_iterator it = find_if(map.begin(), map.end(), lyx::equal_2nd_in_pair(value)); -#endif // If we found nothing, report it and return if (it == map.end()) { @@ -99,10 +67,10 @@ struct is_set_button { }; -int RadioButtonGroup::getButton() +RadioButtonGroup::size_type RadioButtonGroup::get() const { // Find the first button that is active - ButtonValueMap::iterator it = + ButtonValueMap::const_iterator it = find_if(map.begin(), map.end(), is_set_button ()); diff --git a/src/frontends/xforms/RadioButtonGroup.h b/src/frontends/xforms/RadioButtonGroup.h index 533035be1f..682f344430 100644 --- a/src/frontends/xforms/RadioButtonGroup.h +++ b/src/frontends/xforms/RadioButtonGroup.h @@ -12,15 +12,14 @@ #ifndef RADIOBUTTONGROUP_H #define RADIOBUTTONGROUP_H -#include -#include - -#include FORMS_H_LOCATION - #ifdef __GNUG__ #pragma interface #endif +#include "support/types.h" +#include +#include +#include FORMS_H_LOCATION /** This class simplifies the work with a group of radio buttons, * the idea is that you register a bunch of radio buttons with the accompanying @@ -29,23 +28,26 @@ */ class RadioButtonGroup { public: + /// + typedef lyx::size_type size_type; + /// Constructor. Allocate space for 'n' items in the group. RadioButtonGroup(unsigned n = 5) : map(n) {}; /// Register a radio button with it's corresponding value. - void registerRadioButton(FL_OBJECT * button, int value); + void init(FL_OBJECT * button, size_type value); /// Reset registrations. void reset(); // Set the active button. - void setButton(int value); + void set(size_type value); // Get the active button. - int getButton(); + size_type get() const; private: /// - typedef std::pair ButtonValuePair; + typedef std::pair ButtonValuePair; /// typedef std::vector ButtonValueMap; /// diff --git a/src/frontends/xforms/form_graphics.C b/src/frontends/xforms/form_graphics.C index 61dcd9ca66..1ad1866030 100644 --- a/src/frontends/xforms/form_graphics.C +++ b/src/frontends/xforms/form_graphics.C @@ -234,7 +234,7 @@ FD_form_size * FormGraphics::build_size() } 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_CHOICE, 290, 130, 60, 30, ""); + fdui->choice_width = obj = fl_add_choice(FL_NORMAL_CHOICE, 290, 130, 60, 30, ""); fl_set_object_boxtype(obj, FL_FRAME_BOX); fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); @@ -245,7 +245,7 @@ FD_form_size * FormGraphics::build_size() } fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); - fdui->choice_height_units = obj = fl_add_choice(FL_NORMAL_CHOICE, 290, 165, 60, 30, ""); + fdui->choice_height = obj = fl_add_choice(FL_NORMAL_CHOICE, 290, 165, 60, 30, ""); fl_set_object_boxtype(obj, FL_FRAME_BOX); fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); @@ -494,7 +494,7 @@ FD_form_lyxview * FormGraphics::build_lyxview() } fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); - fdui->choice_width_lyxwidth = obj = fl_add_choice(FL_NORMAL_CHOICE, 425, 155, 50, 30, ""); + fdui->choice_lyxwidth = obj = fl_add_choice(FL_NORMAL_CHOICE, 425, 155, 50, 30, ""); fl_set_object_boxtype(obj, FL_FRAME_BOX); fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); @@ -505,7 +505,7 @@ FD_form_lyxview * FormGraphics::build_lyxview() } fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); - fdui->choice_width_lyxheight = obj = fl_add_choice(FL_NORMAL_CHOICE, 425, 190, 50, 30, ""); + fdui->choice_lyxheight = obj = fl_add_choice(FL_NORMAL_CHOICE, 425, 190, 50, 30, ""); fl_set_object_boxtype(obj, FL_FRAME_BOX); fl_set_object_lsize(obj, FL_NORMAL_SIZE); fl_set_object_callback(obj, C_FormBaseInputCB, 0); diff --git a/src/frontends/xforms/form_graphics.h b/src/frontends/xforms/form_graphics.h index e2d4330b00..ea3af23e98 100644 --- a/src/frontends/xforms/form_graphics.h +++ b/src/frontends/xforms/form_graphics.h @@ -57,9 +57,9 @@ struct FD_form_size { FL_OBJECT *radio_wh; FL_OBJECT *input_scale; FL_OBJECT *input_width; - FL_OBJECT *choice_width_units; + FL_OBJECT *choice_width; FL_OBJECT *input_height; - FL_OBJECT *choice_height_units; + FL_OBJECT *choice_height; FL_OBJECT *check_aspectratio; FL_OBJECT *button_lyx_values; }; @@ -95,9 +95,9 @@ struct FD_form_lyxview { FL_OBJECT *radio_color; FL_OBJECT *radio_nodisplay; FL_OBJECT *input_lyxwidth; - FL_OBJECT *choice_width_lyxwidth; + FL_OBJECT *choice_lyxwidth; FL_OBJECT *input_lyxheight; - FL_OBJECT *choice_width_lyxheight; + FL_OBJECT *choice_lyxheight; FL_OBJECT *button_latex_values; }; diff --git a/src/frontends/xforms/forms/form_graphics.fd b/src/frontends/xforms/forms/form_graphics.fd index 3814b66336..4b3942c47e 100644 --- a/src/frontends/xforms/forms/form_graphics.fd +++ b/src/frontends/xforms/forms/form_graphics.fd @@ -597,7 +597,7 @@ label: shortcut: resize: FL_RESIZE_ALL gravity: FL_NoGravity FL_NoGravity -name: choice_width_units +name: choice_width callback: C_FormBaseInputCB argument: 0 @@ -633,7 +633,7 @@ label: shortcut: resize: FL_RESIZE_ALL gravity: FL_NoGravity FL_NoGravity -name: choice_height_units +name: choice_height callback: C_FormBaseInputCB argument: 0 @@ -1281,7 +1281,7 @@ label: shortcut: resize: FL_RESIZE_ALL gravity: FL_NoGravity FL_NoGravity -name: choice_width_lyxwidth +name: choice_lyxwidth callback: C_FormBaseInputCB argument: 0 @@ -1317,7 +1317,7 @@ label: shortcut: resize: FL_RESIZE_ALL gravity: FL_NoGravity FL_NoGravity -name: choice_width_lyxheight +name: choice_lyxheight callback: C_FormBaseInputCB argument: 0