| [ Return to Bugs & Features | Roadmap 1.1 | SVN ⇄ GIT ]
STR #730
Application: | FLTK Library |
Status: | 1 - Closed w/Resolution |
Priority: | 2 - Low, e.g. a documentation error or undocumented side-effect |
Scope: | 3 - Applies to all machines and operating systems |
Subsystem: | Documentation |
Summary: | Fl_Browser_ documentation clarifications |
Version: | 1.1.6 |
Created By: | wilson.afn |
Assigned To: | mike |
Fix Version: | 1.1.7 (SVN: v4065) |
Update Notification: | |
Trouble Report Files:
No files
Trouble Report Comments:
|
#1 | wilson.afn 17:06 Feb 24, 2005 |
| Fl_Browser_ has saved me a *bunch* of work. If the docs were clearer, I bet a lot more people would use it too.
For Fl_Browser_::inserting(void *a, void *b), it isn't clear why there are two parameters when only one is inserted. We believe "a" is in the list already and "b" is being inserted either before or after "a". It seems more appropriate names for the parameters might be "insertion_point" and "new_item".
Similarly, in Fl_Browser_::replacing(void *a, void *b), a simple rename of the parmeters to "old" and "new" would make the derived-class author feel better (even if it doesn't make any difference).
Although I don't use the following methods, I found their descriptions a mite confusing:
Fl_Browser_::hposition() and ::hposition(int h) are said to "get or set the horizontal scrolling position of the list." I presume this is the offset from the left of the "list canvas" to Fl_Browser_::leftedge(), but I could be wrong. There has to be a better way to say it so that even I can understand.
Fl_Browser_::position() and ::position(int v) (the Y-axis equivalents of hposition()?) could also use a better description. | |
|
#2 | wilson.afn 06:48 Mar 03, 2005 |
| A little more info:
It seems Fl_Browser_.H describes Fl_Inserting(...):
void inserting(void *a,void *b); // insert a before b
But this is almost certainly wrong. In the only two examples of its use (in Fl_Browser.cxx), b is inserted before a (which is already present).
The first parameter seems to only be tested to see if it is displayed, and redraw_lines() is called if it is. If all the action takes place outside the confines of the Widget, no update is required. I believe the description could be relaxed to:
void inserting(void *a,void *b); // insert b as a neighbor of a
| |
|
#3 | mike 11:32 Mar 05, 2005 |
| Fixed in Subversion repository.
| |
[ Return to Bugs & Features ]
|
| |