I have a working custompanel.xml page with with some <SPINBOX> like :
<spinbox> <halpin>"Diam-outil"</halpin> <min_>0</min_> <max_>10</max_> <initval>3.00</initval> <resolution>0.05</resolution> <format>"2.2f"</format> <font>("Arial",14)</font> </spinbox>
If I modify the value by mouse using UP/DOWN arrows, it works, the variable take it correctly. But if I enter directly a numeric value, validating with enter the read value is the one before change. I need to make a + then - to have it taken un account, otherwise only the screen value is changed, not the value copied int the variable at the MDI_COMMAND = G10 L20 P0 Z#5399 for exemple.
Solution
For some reason a Return key press is not triggering the command() method of the class
Adding a specific return_pressed() method and binding to the return key does return the value in the line edit and it is processed as expected in the
update() method of the class
Last edit: schooner 2014-04-02
Previous patch did not get formatted properly
New one attached
I try to find the way to apply the patch and will tell U if it works...
I've modify by hand the /usr/share/pyshared/pyvcp_widgets.py with your modifications (git was not working due to directories name). Then copy it to /usr/lib/pymodules/python2.6.
Magic, it's working :o)
Thank U
Jerome
Deleted - not intended for bug tracker - please close
Last edit: schooner 2014-04-03
Fixed in 2.6 (d17419a04594e9e78dc4dd6350675a4a58131d90) and master (00f3419a0d6d84e543f1bd52a23a0d03adc62d1f)