mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-10 20:04:46 +00:00
J�rgen Spitzm�ller's changes to the graphics dialog.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2916 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
c0ef23bc2a
commit
cb5c32cbb0
@ -32,7 +32,28 @@
|
||||
|
||||
using std::endl;
|
||||
|
||||
static double const tol = 1.0e-08;
|
||||
namespace {
|
||||
|
||||
// Zero test for double precision numbers
|
||||
double const tol = 1.0e-08;
|
||||
|
||||
// The maximum digits for the image scale
|
||||
int const SCALE_MAXDIGITS = 3;
|
||||
|
||||
// The maximum digits for the image width
|
||||
int const WIDTH_MAXDIGITS = 3;
|
||||
|
||||
// The maximum digits for the image height
|
||||
int const HEIGHT_MAXDIGITS = 3;
|
||||
|
||||
// The max characters in the rotation angle (minus sign and 3 digits)
|
||||
int const ROTATE_MAXCHARS = 4;
|
||||
|
||||
// The maximum characters in a filename.
|
||||
int const FILENAME_MAXCHARS = 1024;
|
||||
|
||||
} // namespace anon
|
||||
|
||||
|
||||
typedef FormCB<ControlGraphics, FormDB<FD_form_graphics> > base_class;
|
||||
|
||||
|
@ -42,23 +42,11 @@ private:
|
||||
/// Filter the inputs on callback from xforms
|
||||
virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
|
||||
|
||||
/// The maximum digits for the image scale
|
||||
static const int SCALE_MAXDIGITS = 3;
|
||||
/// The maximum digits for the image width
|
||||
static const int WIDTH_MAXDIGITS = 3;
|
||||
/// The maximum digits for the image height
|
||||
static const int HEIGHT_MAXDIGITS = 3;
|
||||
/// The max characters in the rotation angle (minus sign and 3 digits)
|
||||
static const int ROTATE_MAXCHARS = 4;
|
||||
/// The maximum characters in a filename.
|
||||
static const int FILENAME_MAXCHARS = 1024;
|
||||
|
||||
/// Verify that the input is correct. If not disable ok/apply buttons.
|
||||
ButtonPolicy::SMInput checkInput();
|
||||
|
||||
/// Fdesign generated method
|
||||
FD_form_graphics * build_graphics();
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
@ -47,7 +47,8 @@ FD_form_graphics * FormGraphics::build_graphics()
|
||||
}
|
||||
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, 180, 80, 65, 30, "");
|
||||
fdui->choice_width_units = obj = fl_add_choice(FL_NORMAL_CHOICE, 180, 80, 65, 30, "");
|
||||
fl_set_object_boxtype(obj, FL_FRAME_BOX);
|
||||
fl_set_object_callback(obj, C_FormBaseInputCB, 0);
|
||||
{
|
||||
char const * const dummy = N_("Height|#H");
|
||||
@ -56,7 +57,8 @@ FD_form_graphics * FormGraphics::build_graphics()
|
||||
}
|
||||
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_CHOICE2, 180, 120, 65, 30, "");
|
||||
fdui->choice_height_units = obj = fl_add_choice(FL_NORMAL_CHOICE, 180, 120, 65, 30, "");
|
||||
fl_set_object_boxtype(obj, FL_FRAME_BOX);
|
||||
fl_set_object_callback(obj, C_FormBaseInputCB, 0);
|
||||
{
|
||||
char const * const dummy = N_("Scale|#S");
|
||||
|
@ -104,9 +104,9 @@ argument: 0
|
||||
|
||||
--------------------
|
||||
class: FL_CHOICE
|
||||
type: NORMAL_CHOICE2
|
||||
type: NORMAL_CHOICE
|
||||
box: 180 80 65 30
|
||||
boxtype: FL_UP_BOX
|
||||
boxtype: FL_FRAME_BOX
|
||||
colors: FL_COL1 FL_BLACK
|
||||
alignment: FL_ALIGN_LEFT
|
||||
style: FL_NORMAL_STYLE
|
||||
@ -140,9 +140,9 @@ argument: 0
|
||||
|
||||
--------------------
|
||||
class: FL_CHOICE
|
||||
type: NORMAL_CHOICE2
|
||||
type: NORMAL_CHOICE
|
||||
box: 180 120 65 30
|
||||
boxtype: FL_UP_BOX
|
||||
boxtype: FL_FRAME_BOX
|
||||
colors: FL_COL1 FL_BLACK
|
||||
alignment: FL_ALIGN_LEFT
|
||||
style: FL_NORMAL_STYLE
|
||||
|
Loading…
Reference in New Issue
Block a user