Andre Arpin <ar...@...> writes:

> Odd but it might be explained. Look at the definition of wxSpinCtrl in 
> Reference Manual. There are two versions for set.
> 
> void SetValue(const wxString& text)
> void SetValue(int iValue)
> 
> If you look in wxWidgets there is only one definition namely the string 
> version. I don't know why the numeric version was added in wxlua probably so 
> you do not have to do SetValue(tostring(value)) for a number. This was 
> probably a mistake.

also interesting is that the definition for GetValue is that it return an int 
but in reality it returns a string.

I think spin control is very poorly defined. It should only accept numbers. 
This string think is probably because someone uses spinbutton with a text 
control and was too lazy to add the proper check. So compatibility does not 
exist and all the programmers have to add check in there code to use it 
properly.

Poor definition and lousy implementation is the cause of most the porting 
problems.



------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
wxlua-users mailing list
wxlua-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wxlua-users

Reply via email to