API doc update coming?

I’ve upgraded from 1.9.0 to 1.9.2 and am finding that
the errors I’m getting don’t match the docs. For example,
in Wx::ListCtrl:

  • The doc makes no mention of on_get_item_column_image(),
    but without this method I get NoMethodError.

  • The doc says on_get_item_attr() may be overloaded,
    but if I don’t define it, I get NoMethodError.

The API doc appears to be rife with inconsistencies like
this. Is anyone working on updating it? Sorry to whine,
but newbies like me need all the hand-holding we can get!

Also, the Wx::Sizer page has a broken link to “Sizer
overview”. Oh how I need that overview – I don’t have
any idea how layouts work in GUIs and trying to figure
out how to use the Sizer classes is proving quite a
challenge. (The sample programs are a big help, but an
overview would give me a leg up on the learning curve.)

Thanks,
Peralta

Hi Peralta,

2007/10/24, [email protected] [email protected]:

Also, the Wx::Sizer page has a broken link to “Sizer
overview”. Oh how I need that overview – I don’t have
any idea how layouts work in GUIs and trying to figure
out how to use the Sizer classes is proving quite a
challenge.

Indeed, the link is broken. Meanwhile, there is a page on the wxRuby
wiki that explains Sizer concepts.

http://wxruby.rubyforge.org/wiki/wiki.pl?Using_Sizers_For_Layout

I can’t help you for the other questions related with ListCtrl.

Cheers.

Chauk-Mean.

Hi Peralta

[email protected] wrote:

I’ve upgraded from 1.9.0 to 1.9.2 and am finding that
the errors I’m getting don’t match the docs. For example,
in Wx::ListCtrl:

  • The doc makes no mention of on_get_item_column_image(),
    but without this method I get NoMethodError.

  • The doc says on_get_item_attr() may be overloaded,
    but if I don’t define it, I get NoMethodError.

Thanks for the report; the docs are right and the library is wrong. I
had meant to check in a patch for this a while back but forgot. It
should be fixed now for 1.9.3. The changed file is here:
http://wxruby.rubyforge.org/svn/trunk/wxruby2/lib/wx/classes/listctrl.rb

The API doc appears to be rife with inconsistencies like
this. Is anyone working on updating it?

No-one is working on it, in the same sense as no-one is working on
wxRuby as a whole. There is a small team of volunteers who, in their
spare time, make additions and corrections to the docs with each
release, as well as developing the library, providing binary builds, and
helping on the mailing lists. And, even, occasionally working on their
own projects.

Sorry if this sounds bad-tempered, but there is no way that a small dev
team can stop and work through several hundred pages worth of docs. This
is partly why many Ruby GUI projects don’t have dedicated Ruby docs. I
don’t think wxRuby’s are “rife” with errors, but because of the scale of
the docs we’re reliant on users helping us and each other by pointing
them out.

Patches to fix the docs are great
(http://wxruby.rubyforge.org/wiki/wiki.pl?DocumentingWxRuby) but a
simple list of references to all the mistakes you’ve found would be a
massive help, and gratefully received.

Also, the Wx::Sizer page has a broken link to “Sizer
overview”. Oh how I need that overview
Sizers are powerful, but not intuitive at first glance. You might have a
look at:
http://wxruby.rubyforge.org/wiki/wiki.pl?Using_Sizers_For_Layout
http://www.wxwidgets.org/manuals/stable/wx_sizeroverview.html

Alternatively, you might consider using XRC (XML layouts, designed in a
visual editor) or the ‘layout’ library from WxSugar. Both of these
enable you to get the benefits of Sizer-based layout, without having to
deal with the slightly clumsy API.

cheers
alex

Alex wrote:

Sorry if this sounds bad-tempered, but there is no way that a small dev
team can stop and work through several hundred pages worth of docs…

No, no – I apologize for sounding so snippy. I realize
it’s a lot of work. (I’d pitch in if I didn’t have my own
deadlines). Besides, the reponsiveness of this list more
than makes up for the lag.

Thanks for the pointers to other docs.

Peralta