Chauk-Mean P
2008-Nov-10 10:56 UTC
[wxruby-development] Documentation about ToolBar#add_item and Sizer#add_item
Hi Alex, It''s better late than never ... I''ve prepared the textile documentation for these 2 methods and this will be posted tonight. This documentation corresponds to the current implementation. I''m just wondering two things : - Unlike my proposal (http://rubyforge.org/pipermail/wxruby-development/2008-March/001249.html), a spacer is not currently supported by Sizer#add_item. Is this intentional ? In my proposal, if the first parameter is an array with 2 elements then it is detected as a spacer and Sizer#add and Sizer#insert can be used accordingly by extracting the width and height from the array. - ToolBar#add_item I understand that you kept the position of the bitmap parameter for consistency with ToolBar#add_tool and Toolbar#insert_tool methods. But for me, keyword arguments are optional arguments that may be specified in any order. This is the case for all existing methods (e.g. all window constructor) that support keyword arguments except ToolBar#add_item. In ToolBar#add_item, the bitmap parameter is a keyword parameter but is not optional ... This is a bit strange and inconsistent with above. I documented this subtle detail but I think it''s not a good thing. Cheers. Chauk-Mean.
Chauk-Mean P
2008-Nov-10 15:28 UTC
[wxruby-development] Documentation about ToolBar#add_item and Sizer#add_item
Alex, Will you accept code patches for the 2 things I mentioned in my previous post : - support of spacer in Sizer#add_item ? - make bitmap the first and mandatory parameter in ToolBar#add_item ? Cheers. Chauk-Mean.
Chauk-Mean P
2008-Nov-10 23:17 UTC
[wxruby-development] Documentation about ToolBar#add_item and Sizer#add_item
Hi, 2008/11/10 Chauk-Mean P <chauk.mean at gmail.com>:> > It''s better late than never ... > I''ve prepared the textile documentation for these 2 methods and this > will be posted tonight. > This documentation corresponds to the current implementation. >So here is the documentation patch (only for the current implementation). Cheers. Chauk-Mean. -------------- next part -------------- A non-text attachment was scrubbed... Name: toolbar_sizer_doc.patch Type: text/x-patch Size: 6684 bytes Desc: not available URL: <http://rubyforge.org/pipermail/wxruby-development/attachments/20081111/97511aaf/attachment-0001.bin>