Results 1 to 2 of 2
  1. #1
    steve.hookway is offline Member
    Join Date
    Nov 2009
    Rep Power

    Default CheckBoxTreeViewer and Scroll

    I'm having some difficulties setting the visible portion of the Tree. I'm trying to do something like:

    Java Code:
    tv = new CheckboxTreeViewer(composite);
    tv.getTree().setLayout(new GridData(GridData.FILL_BOTH));
    ... //set content and label providers
    //now scroll to a spot in the tree!
    TreeItem[] ta = tv.getTree().getItems();
    TreeItem ti = ta[2];
    Rectangle r = ti.getBounds();
    Item i = tv.scrollDown(r.x,r.y);
    I've searched around some and can't seem to find the right way to get this working. The goal is to be able to change which part of the tree is visible in the scroll panel. I have to admit, I'm new to SWT so it could be I'm missing something simple here. Hopefully you'll be able to help out!

    Thanks in advance!

  2. #2
    steve.hookway is offline Member
    Join Date
    Nov 2009
    Rep Power

Similar Threads

  1. smooth-scroll
    By designer in forum Java Applets
    Replies: 1
    Last Post: 07-21-2009, 08:10 PM
  2. JFACE CheckboxTreeViewer
    By pele in forum SWT / JFace
    Replies: 0
    Last Post: 07-14-2009, 09:11 AM
  3. problem with scroll bar
    By r.gnanaprakasam in forum AWT / Swing
    Replies: 0
    Last Post: 04-22-2009, 02:24 PM
  4. CheckboxTreeViewer Demonstration
    By Java Tip in forum SWT Tips
    Replies: 0
    Last Post: 07-07-2008, 05:53 PM
  5. Jtextarea and scroll
    By ziniestro in forum AWT / Swing
    Replies: 2
    Last Post: 06-01-2007, 04:59 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts