Skip to main content



      Home
Home » Eclipse Projects » GEF » Resizing labels
Resizing labels [message #233425] Tue, 24 April 2007 11:44 Go to next message
Eclipse UserFriend
Hello,

I want to be able to create an external label that can be resized, i.e. I
can drag
its bounding box and the text will wrap within it. However, I can't seem to
find
a way to do this. I've tried calling setTextWrap(true) (see below), but no
luck.
Has anyone managed to do this?

Thanks,

Andy

public class ElementNameFigure extends WrapLabel {

/**

* @generated

*/

public ElementNameFigure() {

this.setText("<...>");

this.setTextWrap(true);

}


}
Re: Resizing labels [message #233441 is a reply to message #233425] Tue, 24 April 2007 13:02 Go to previous message
Eclipse UserFriend
Hi,

I think you need an editpart for your label to accomplish what you're
asking. Resizing is triggered first by the resize handles and resize drag
tracker installed on them and second by a resize edit policy installed on
your label edit part that will create a command for the request created by
the resize drag tracker.
Hope this helps.

Cheers,
Alex
Previous Topic:GEF Update site
Next Topic:Resize only in north and south directions
Goto Forum:
  


Current Time: Fri Jul 04 02:39:39 EDT 2025

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

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

Back to the top