I have been unable to input negative numbers into InputDialog::ask_double.
I am using the windows version of Klayout. The '-' shows up and no input is allowed beyond that.
you're right. That was not intended. The lower limit is 0 instead of allowing negative values too.
Fortunately there is a simple workaround. The "ask_double_ex" method allows specifying a longer and upper limit. Just set that to some useful values, i.e. -1000 to 1000, and the dialog will allow specification of negative values too:
Comments
Hi,
you're right. That was not intended. The lower limit is 0 instead of allowing negative values too.
Fortunately there is a simple workaround. The "ask_double_ex" method allows specifying a longer and upper limit. Just set that to some useful values, i.e. -1000 to 1000, and the dialog will allow specification of negative values too:
Matthias