Domingo Alvarez Duarte wrote:
> Can you make availlable your Fl_Tree with keyboard navigation ?
Here's an updated patch for r7680 with several keynav improvements:
http://seriss.com/people/erco/fltk/tmp/Fl_Tree-add-keyboard-nav-to-r7680-08-11-10--11am.patch
The above patch is against a clean fltk1.3.x r7680 (ie. previous patch NOT
applied).
In this patch:
Keyboard navigation:
Up/Down -- moves focus
Left/Right -- closes/opens tree item in focus
Spacebar -- toggle selection state of item in focus
Enter -- selects the item in focus, deselecting all
others
Tab/Shift-Tab -- change widget focus
All Fl_Tree select() and deselect() methods now return a value
that indicates if the item's state was changed.
Fl_Tree::handle() simplified, heavily reworked.
Fixed focus box drawing (focus box resides more precisely within item's
box)
Callback handling for selection states was improved.
Method docs improved.
Fixed a problem with invisible focus traversal into items that are
closed.
TODO:
o Need method to provide scroller positioning to show items at
top/middle/bottom (vis a vis Fl_Browser)
o Need a callback system invoked when items are open/closed
o Need to allow keyboard nav to move focus to/from child FLTK
widgets
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk