Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » problem in XY Layout-while creating scrollbar
problem in XY Layout-while creating scrollbar [message #247200] Mon, 09 February 2009 12:43 Go to next message
Debasis Mishra is currently offline Debasis MishraFriend
Messages: 36
Registered: July 2009
Member
I am having trouble getting scrollbars to work correctly. They just sit
there grayed-out and do nothing:


FigureCanvas canvas = new FigureCanvas(shell);
canvas.setScrollBarVisibility(FigureCanvas.ALWAYS);


IFigure figure = new Figure();
XYLayout layout = new XYLayout();
figure.setLayoutManager(layout);

Label label = new Label("Banana");
figure.add(label);
label.setSize(label.getPreferredSize());
label.setLocation(new Point(30, 30));

canvas.setContents(figure);

Could anybody please help me in solving this .

ThanksinAdvance
Debasis
Re: problem in XY Layout-while creating scrollbar [message #247222 is a reply to message #247200] Thu, 12 February 2009 01:40 Go to previous message
Anthony Hunter is currently offline Anthony HunterFriend
Messages: 446
Registered: July 2009
Senior Member
Hi Debasis

Check out the draw2d ScrollPaneExample

http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.gef/exa mples/org.eclipse.draw2d.examples/src/org/eclipse/draw2d/exa mples/scrollpane/ScrollPaneExample.java?root=Tools_Project&a mp;view=markup

Cheers...
Anthony

"Debasis Mishra" <debasis1982@gmail.com> wrote in message
news:5247dc4623b706b13322d363fce75e05$1@www.eclipse.org...
>I am having trouble getting scrollbars to work correctly. They just sit
>there grayed-out and do nothing:
>
>
> FigureCanvas canvas = new FigureCanvas(shell);
> canvas.setScrollBarVisibility(FigureCanvas.ALWAYS);
>
>
> IFigure figure = new Figure();
> XYLayout layout = new XYLayout();
> figure.setLayoutManager(layout);
>
> Label label = new Label("Banana");
> figure.add(label);
> label.setSize(label.getPreferredSize());
> label.setLocation(new Point(30, 30));
>
> canvas.setContents(figure);
>
> Could anybody please help me in solving this .
>
> ThanksinAdvance
> Debasis
>
>
>
Previous Topic:[Announce] GEF 3.5.0 I200902051436 is available
Next Topic:add border shape
Goto Forum:
  


Current Time: Mon Dec 30 17:14:27 GMT 2024

Powered by FUDForum. Page generated in 0.03137 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top