[wxruby-users] TE_CENTRE not defined in Windows
Alex Fenton
alex at pressure.to
Wed Nov 12 09:46:08 EST 2008
Hi
Eric Rubin wrote:
>
> When I try to create a TextCtrl with the TE_CENTRE style I get the
> message “uninitialized constant Wxruby2::TE_CENTRE”. I have the same
> problem with TE_RIGHT, but TE_LEFT and all the other TE_* styles seem
> to work fine. I am running Windows XP, Ruby 1.8.6 and WxRuby 1.9.9.
>
Thanks for the report. It's strange. The constants are definitely there
in the source files, but I also find TE_RIGHT and TE_CENTRE to be
undefined (1.9.9, SVN HEAD on OS X).
To work round it for now, you can use the following constants which have
the same value (in the C++ source, the TE_ constants are just aliases
for these).
Wx::TE_RIGHT = Wx::ALIGN_RIGHT
Wx::TE_CENTRE = Wx::ALIGN_CENTER_HORIZONTAL
alex
More information about the wxruby-users
mailing list