开发者

ERlang list Ctrl changing colors

Hi I am trying to change an individual item in a listCtrl in erlang.

I initialize listCtrl then I goto set the item as follows:

wxListCtrl:setItem(ListCtrl, Row, 1, io_lib:format("~.2f",[VolumeB + 0.00 ])),
    wxListCtrl:setItemBackgroundColour(ListCtrl, 1, ?wxRED),

Problem is the background color of t开发者_StackOverflow中文版he entire row is red, I only want one column in one row to change, not the entire row.

This is a tough one, at least for me, I haven't seen any simple straight forward docs.


wx is an Erlang port/wrapper of wxWidgets, so if you're having trouble with things like wxListCtrl:SetItemBackgroundColour(), you'll probably have more luck with the wxWidgets documentation than the (Erlang) wx documentation: listCtrl documentation at docs.wxwidgets.org

That said, a quick Google suggests that wxListCtrl doesn't provide a way to specify the background color of a column or a cell.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜