Re: Checkbox tree component

2007-11-16 Thread dstruck

Doug, thanks for putting this together.

David


Doug Leeper wrote:
 
 Ok here it is.  I have also included my use of it.  While it won't compile
 for you...you will at least see how I have used it.
 
  http://www.nabble.com/file/p13439520/CheckBoxIconPanel.html
 CheckBoxIconPanel.html 
  http://www.nabble.com/file/p13439520/CheckBoxIconPanel.java
 CheckBoxIconPanel.java 
  http://www.nabble.com/file/p13439520/CheckBoxTree.java CheckBoxTree.java 
 
 My use of CheckBoxTree...
 
  http://www.nabble.com/file/p13439520/ProductCategoriesPanel.html
 ProductCategoriesPanel.html 
  http://www.nabble.com/file/p13439520/ProductCategoriesPanel.java
 ProductCategoriesPanel.java 
 
 

-- 
View this message in context: 
http://www.nabble.com/Checkbox-tree-component-tf4699092.html#a13804534
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Configuring AJAX tree

2007-10-26 Thread dstruck

Thanks for the advice, Matej. I've upgraded to Wicket 1.3 and the LinkTree
lays out much nicer.

That said, I actually was able to adjust the width by using CSS:

1. Create a CSS file in the same package as the HTML file.
2. Use a span tag in the HTML for the tree (when the HTML is generated by
Wicket, the span tag will become a div tag and get a class of
wicket-tree).
3. In the CSS file, make a setting for the width for the wicket-tree
class.
4. In the Java code, add this line:
tree.add(HeaderContributor.forCss(TreePage.class, cssFilename));

This is obviously not ideal since I had to look in the generated HTML to see
the wicket-tree class. Also, if you use a div tag (instead of a span tag),
the class doesn't show up.

David


Matej Knopp-2 wrote:
 
 Hi, unfortunately the Tree class is not able to grow horizontally,
 neither it is possible for it to have a horizontal scrollbar. If you
 need this features, you have to use the new LinkTree (or it's
 superclass BaseTree) from wicket 1.3.
 
 -Matej
 
 On 10/24/07, David Struck [EMAIL PROTECTED] wrote:
 I've been able to get an AJAX tree up and running and I'm very happy
 with how simple it was. My HTML is:

   html
   body
   
   /body
   /html

 and my Java is:

   ...
   public TreePage() {
 DefaultMutableTreeNode root = ...
 TreeModel treeModel = new DefaultTreeModel(root);
 Tree tree = new Tree(myTree, treeModel);
 tree.getTreeState().collapseAll();
 add(tree);
   }
   ...

 Now I'd like to improve the layout and I'm not sure how to do it. First
 of all, the tree view seems to have a preset width that doesn't grow
 when one of the tree nodes goes outside the width. How can I modify the
 width of the tree view? Should I use CSS? And, if so, how do I hook my
 CSS settings in?

 Second, can I move/remove the floating debugger link? And can anyone
 provide a link to a tutorial/guide that explains how to tweak pre-built
 components? Hopefully that will get me moving in the right direction.

 Thanks,

 David

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Configuring-AJAX-tree-tf4687105.html#a13430342
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Checkbox tree component

2007-10-26 Thread dstruck

Has anyone put together a checkbox tree component? I've done some searches
but haven't turned anything up. Basically, I'd like a tree with a checkbox
leading each node that when checked also selects all child nodes. I'm
thinking of something like the tree you see when you do software updates in
Eclipse:

http://www.nabble.com/file/p13433102/Clipboard01.jpg 

The component would provide a method for getting all the selected nodes.

Thanks,

David
-- 
View this message in context: 
http://www.nabble.com/Checkbox-tree-component-tf4699092.html#a13433102
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]