MacArthur, Ian (SELEX) (UK) wrote:
>>> hi all,
>>>      i am using fltk 1.1.7 and using fl_check_browser. to add 
>>> a entry we need to use "add". Looks like no function is 
>>> available for removing an entry in the browser. Any help is 
>>> greatly appreciated.
>> 
>> I imagine that remove() would work? Presumably (and I have not checked
>> this) the check browser should inherit a remove method from it base
>> class?

        Yes Fl_Browser::remove() should work if you pass it the
        index number of the line in the browser you want to remove.

        Note that the browser's line numbers are '1' based, not '0'.
        So if you want to remove the first line, use remove(1), not remove(0).

>> Hmm, looking at the src, it's not obvious to me this would work... I
>> wonder if you can cast it to an Fl_Browser and use its remove(int)
>> method instead?

> Answer: no, that is a Bad Idea.

        Right, not good because you only want to pass line numbers
        as an argument to Fl_Browser::remove().
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to