Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » help needed for StickyLabelFigure problem
help needed for StickyLabelFigure problem [message #130205] Mon, 03 May 2004 07:59 Go to next message
Eclipse UserFriend
Originally posted by: chengzhu.usc.edu

Hi All,

I implemented a class which is similar as the StickyLabelFigure in logic
example, with nearly all kind of necessary classes, e.g. DirectEditManager,
Policy, CellEditorLocator classes. And I set my TextCellEditor class with
SWT.MULTI | SWT.WRAP in the class inherited from DirectEditManager, but I
found my text input won't be either wrap and multi -- it is not like example
in StickyLabelFigure class, the outline of figure will expended vertically
if you type more words, and it is wrapped. My work doesn't. I nearly
implemented the same as StickyLabelFigure does, except I create my label
figure class from Figure directly. Can anyone give me some hints? or tell me
in which direction I should go for bug? Thx a lot.

regards
Kevin
Re: help needed for StickyLabelFigure problem [message #130219 is a reply to message #130205] Mon, 03 May 2004 14:50 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

Are you saying the Text control that comes up doesn't wrap or extend to
multiple lines - I assume this also means the figure that is behind the Text
control is staying the same size as the control? This is likely a problem
with your figure that is backing the Text Control. You said you create it
directly from figure - what are the contents of your figure class? Are you
using Label? It could also be a problem with your CellEditorLocator.

"flashk" <chengzhu@usc.edu> wrote in message
news:c74tlo$vfl$1@eclipse.org...
> Hi All,
>
> I implemented a class which is similar as the StickyLabelFigure in logic
> example, with nearly all kind of necessary classes, e.g.
DirectEditManager,
> Policy, CellEditorLocator classes. And I set my TextCellEditor class with
> SWT.MULTI | SWT.WRAP in the class inherited from DirectEditManager, but I
> found my text input won't be either wrap and multi -- it is not like
example
> in StickyLabelFigure class, the outline of figure will expended vertically
> if you type more words, and it is wrapped. My work doesn't. I nearly
> implemented the same as StickyLabelFigure does, except I create my label
> figure class from Figure directly. Can anyone give me some hints? or tell
me
> in which direction I should go for bug? Thx a lot.
>
> regards
> Kevin
>
>
Re: help needed for StickyLabelFigure problem [message #130233 is a reply to message #130219] Mon, 03 May 2004 18:52 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: chengzhu.usc.edu

"Whitney Sorenson" <none@us.ibm.com> wrote in message
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or extend to
> multiple lines - I assume this also means the figure that is behind the
Text
> control is staying the same size as the control? This is likely a problem
> with your figure that is backing the Text Control. You said you create it
> directly from figure - what are the contents of your figure class? Are you
> using Label? It could also be a problem with your CellEditorLocator.
>
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the StickyLabelFigure in logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my TextCellEditor class
with
> > SWT.MULTI | SWT.WRAP in the class inherited from DirectEditManager, but
I
> > found my text input won't be either wrap and multi -- it is not like
> example
> > in StickyLabelFigure class, the outline of figure will expended
vertically
> > if you type more words, and it is wrapped. My work doesn't. I nearly
> > implemented the same as StickyLabelFigure does, except I create my label
> > figure class from Figure directly. Can anyone give me some hints? or
tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>
>
Re: help needed for StickyLabelFigure problem [message #130245 is a reply to message #130219] Mon, 03 May 2004 18:58 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: chengzhu.usc.edu

This is a multi-part message in MIME format.

------=_NextPart_000_003C_01C43105.EC65AB60
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi Whitney,

My figure backing the Text control is directly inherited from Figure, =
not like StickyLabelFigure inherited from BentCornerFigure. In my =
figure's constructor,=20

{......
setBorder(new MarginBorder(5));

FlowPage flowPage =3D new FlowPage();

textFlow =3D new TextFlow();

textFlow.setLayoutManager(new ParagraphTextLayout(textFlow,

ParagraphTextLayout.WORD_WRAP_SOFT));

flowPage.add(textFlow);

setLayoutManager(new StackLayout());

add(flowPage);

}

And I am not using the Label. As to the CellEditorLocator, I think it is =
used to relocate the Text control boundary, and highlight your text =
selection, am I right?

Thank you very much for your help

Kevin


"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or extend =
to
> multiple lines - I assume this also means the figure that is behind =
the Text
> control is staying the same size as the control? This is likely a =
problem
> with your figure that is backing the Text Control. You said you create =
it
> directly from figure - what are the contents of your figure class? Are =
you
> using Label? It could also be a problem with your CellEditorLocator.
>=20
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the StickyLabelFigure in =
logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my TextCellEditor class =
with
> > SWT.MULTI | SWT.WRAP in the class inherited from DirectEditManager, =
but I
> > found my text input won't be either wrap and multi -- it is not like
> example
> > in StickyLabelFigure class, the outline of figure will expended =
vertically
> > if you type more words, and it is wrapped. My work doesn't. I nearly
> > implemented the same as StickyLabelFigure does, except I create my =
label
> > figure class from Figure directly. Can anyone give me some hints? or =
tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>=20
>
------=_NextPart_000_003C_01C43105.EC65AB60
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT face=3DArial size=3D2>Hi Whitney,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My figure backing the Text control is =
directly=20
inherited from Figure, not like StickyLabelFigure inherited from=20
BentCornerFigure. In my figure's constructor, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>{......</FONT></DIV>
<DIV>
<P><FONT face=3DArial size=3D2>setBorder(new =
MarginBorder(5));</FONT></P>
<P><FONT face=3DArial size=3D2>FlowPage flowPage =3D new =
FlowPage();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow =3D new TextFlow();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow.setLayoutManager(new=20
ParagraphTextLayout(textFlow,</FONT></P>
<P><FONT face=3DArial =
size=3D2>ParagraphTextLayout.WORD_WRAP_SOFT));</FONT></P>
<P><FONT face=3DArial size=3D2>flowPage.add(textFlow);</FONT></P>
<P><FONT face=3DArial size=3D2>setLayoutManager(new =
StackLayout());</FONT></P>
<P><FONT face=3DArial size=3D2>add(flowPage);</FONT></P></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And I am not using the Label. As to the =

CellEditorLocator, I think it is used to relocate the Text control =
boundary, and=20
highlight your text selection, am I right?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you very much for your =
help</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kevin</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>"Whitney Sorenson" &lt;</FONT><A=20
href=3D"mailto:none@us.ibm.com"><FONT face=3DArial=20
size=3D2>none@us.ibm.com</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in message=20
</FONT><A href=3D"news:c75iab$ocp$1@eclipse.org"><FONT face=3DArial=20
size=3D2>news:c75iab$ocp$1@eclipse.org</FONT></A><FONT face=3DArial=20
size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>&gt; Are you saying =
the Text=20
control that comes up doesn't wrap or extend to<BR>&gt; multiple lines - =
I=20
assume this also means the figure that is behind the Text<BR>&gt; =
control is=20
staying the same size as the control? This is likely a problem<BR>&gt; =
with your=20
figure that is backing the Text Control. You said you create it<BR>&gt; =
directly=20
from figure - what are the contents of your figure class? Are =
you<BR>&gt; using=20
Label? It could also be a problem with your CellEditorLocator.<BR>&gt; =
<BR>&gt;=20
"flashk" &lt;</FONT><A href=3D"mailto:chengzhu@usc.edu"><FONT =
face=3DArial=20
size=3D2>chengzhu@usc.edu</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in=20
message<BR>&gt; </FONT><A href=3D"news:c74tlo$vfl$1@eclipse.org"><FONT =
face=3DArial=20
size=3D2>news:c74tlo$vfl$1@eclipse.org</FONT></A><FONT face=3DArial=20
size=3D2>...<BR>&gt; &gt; Hi All,<BR>&gt; &gt;<BR>&gt; &gt; I =
implemented a class=20
which is similar as the StickyLabelFigure in logic<BR>&gt; &gt; example, =
with=20
nearly all kind of necessary classes, e.g.<BR>&gt; =
DirectEditManager,<BR>&gt;=20
&gt; Policy, CellEditorLocator classes. And I set my TextCellEditor =
class=20
with<BR>&gt; &gt; SWT.MULTI | SWT.WRAP in the class inherited from=20
DirectEditManager, but I<BR>&gt; &gt; found my text input won't be =
either wrap=20
and multi -- it is not like<BR>&gt; example<BR>&gt; &gt; in =
StickyLabelFigure=20
class, the outline of figure will expended vertically<BR>&gt; &gt; if =
you type=20
more words, and it is wrapped. My work doesn't. I nearly<BR>&gt; &gt;=20
implemented the same as StickyLabelFigure does, except I create my =
label<BR>&gt;=20
&gt; figure class from Figure directly. Can anyone give me some hints? =
or=20
tell<BR>&gt; me<BR>&gt; &gt; in which direction I should go for bug? Thx =
a=20
lot.<BR>&gt; &gt;<BR>&gt; &gt; regards<BR>&gt; &gt; Kevin<BR>&gt; =
&gt;<BR>&gt;=20
&gt;<BR>&gt; <BR>&gt; </FONT></BODY></HTML>

------=_NextPart_000_003C_01C43105.EC65AB60--
Re: help needed for StickyLabelFigure problem [message #130258 is a reply to message #130245] Mon, 03 May 2004 20:17 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

This is a multi-part message in MIME format.

------=_NextPart_000_0165_01C43121.B71428D0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

So does the figure size stay in sync with the text control - or does it =
grow in height?=20
"flashk" <chengzhu@usc.edu> wrote in message =
news:c7649g$gpd$1@eclipse.org...
Hi Whitney,

My figure backing the Text control is directly inherited from Figure, =
not like StickyLabelFigure inherited from BentCornerFigure. In my =
figure's constructor,=20

{......
setBorder(new MarginBorder(5));

FlowPage flowPage =3D new FlowPage();

textFlow =3D new TextFlow();

textFlow.setLayoutManager(new ParagraphTextLayout(textFlow,

ParagraphTextLayout.WORD_WRAP_SOFT));

flowPage.add(textFlow);

setLayoutManager(new StackLayout());

add(flowPage);

}

And I am not using the Label. As to the CellEditorLocator, I think it =
is used to relocate the Text control boundary, and highlight your text =
selection, am I right?

Thank you very much for your help

Kevin


"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or extend =
to
> multiple lines - I assume this also means the figure that is behind =
the Text
> control is staying the same size as the control? This is likely a =
problem
> with your figure that is backing the Text Control. You said you =
create it
> directly from figure - what are the contents of your figure class? =
Are you
> using Label? It could also be a problem with your CellEditorLocator.
>=20
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the StickyLabelFigure in =
logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my TextCellEditor =
class with
> > SWT.MULTI | SWT.WRAP in the class inherited from =
DirectEditManager, but I
> > found my text input won't be either wrap and multi -- it is not =
like
> example
> > in StickyLabelFigure class, the outline of figure will expended =
vertically
> > if you type more words, and it is wrapped. My work doesn't. I =
nearly
> > implemented the same as StickyLabelFigure does, except I create my =
label
> > figure class from Figure directly. Can anyone give me some hints? =
or tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>=20
>
------=_NextPart_000_0165_01C43121.B71428D0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>So does the figure size stay in sync =
with the text=20
control - or does it grow in height? </FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A =
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt;=20
wrote in message <A=20
=
href=3D"news:c7649g$gpd$1@eclipse.org">news:c7649g$gpd$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi Whitney,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My figure backing the Text control is =
directly=20
inherited from Figure, not like StickyLabelFigure inherited from=20
BentCornerFigure. In my figure's constructor, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>{......</FONT></DIV>
<DIV>
<P><FONT face=3DArial size=3D2>setBorder(new =
MarginBorder(5));</FONT></P>
<P><FONT face=3DArial size=3D2>FlowPage flowPage =3D new =
FlowPage();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow =3D new TextFlow();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow.setLayoutManager(new=20
ParagraphTextLayout(textFlow,</FONT></P>
<P><FONT face=3DArial =
size=3D2>ParagraphTextLayout.WORD_WRAP_SOFT));</FONT></P>
<P><FONT face=3DArial size=3D2>flowPage.add(textFlow);</FONT></P>
<P><FONT face=3DArial size=3D2>setLayoutManager(new =
StackLayout());</FONT></P>
<P><FONT face=3DArial size=3D2>add(flowPage);</FONT></P></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And I am not using the Label. As to =
the=20
CellEditorLocator, I think it is used to relocate the Text control =
boundary,=20
and highlight your text selection, am I right?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you very much for your =
help</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kevin</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>"Whitney Sorenson" &lt;</FONT><A=20
href=3D"mailto:none@us.ibm.com"><FONT face=3DArial=20
size=3D2>none@us.ibm.com</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in message=20
</FONT><A href=3D"news:c75iab$ocp$1@eclipse.org"><FONT face=3DArial=20
size=3D2>news:c75iab$ocp$1@eclipse.org</FONT></A><FONT face=3DArial=20
size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>&gt; Are you =
saying the Text=20
control that comes up doesn't wrap or extend to<BR>&gt; multiple lines =
- I=20
assume this also means the figure that is behind the Text<BR>&gt; =
control is=20
staying the same size as the control? This is likely a problem<BR>&gt; =
with=20
your figure that is backing the Text Control. You said you create =
it<BR>&gt;=20
directly from figure - what are the contents of your figure class? Are =

you<BR>&gt; using Label? It could also be a problem with your=20
CellEditorLocator.<BR>&gt; <BR>&gt; "flashk" &lt;</FONT><A=20
href=3D"mailto:chengzhu@usc.edu"><FONT face=3DArial=20
size=3D2>chengzhu@usc.edu</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in=20
message<BR>&gt; </FONT><A href=3D"news:c74tlo$vfl$1@eclipse.org"><FONT =

face=3DArial size=3D2>news:c74tlo$vfl$1@eclipse.org</FONT></A><FONT =
face=3DArial=20
size=3D2>...<BR>&gt; &gt; Hi All,<BR>&gt; &gt;<BR>&gt; &gt; I =
implemented a=20
class which is similar as the StickyLabelFigure in logic<BR>&gt; &gt; =
example,=20
with nearly all kind of necessary classes, e.g.<BR>&gt;=20
DirectEditManager,<BR>&gt; &gt; Policy, CellEditorLocator classes. And =
I set=20
my TextCellEditor class with<BR>&gt; &gt; SWT.MULTI | SWT.WRAP in the =
class=20
inherited from DirectEditManager, but I<BR>&gt; &gt; found my text =
input won't=20
be either wrap and multi -- it is not like<BR>&gt; example<BR>&gt; =
&gt; in=20
StickyLabelFigure class, the outline of figure will expended=20
vertically<BR>&gt; &gt; if you type more words, and it is wrapped. My =
work=20
doesn't. I nearly<BR>&gt; &gt; implemented the same as =
StickyLabelFigure does,=20
except I create my label<BR>&gt; &gt; figure class from Figure =
directly. Can=20
anyone give me some hints? or tell<BR>&gt; me<BR>&gt; &gt; in which =
direction=20
I should go for bug? Thx a lot.<BR>&gt; &gt;<BR>&gt; &gt; =
regards<BR>&gt; &gt;=20
Kevin<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; <BR>&gt;=20
</FONT></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0165_01C43121.B71428D0--
Re: help needed for StickyLabelFigure problem [message #130271 is a reply to message #130258] Mon, 03 May 2004 21:05 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: chengzhu.usc.edu

This is a multi-part message in MIME format.

------=_NextPart_000_007E_01C43117.A8AB6470
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

nope it doesn't grow in height, could you give me any hints how to make =
it and syncronize it with text control? thx a lot
"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c765e7$ig6$1@eclipse.org...
So does the figure size stay in sync with the text control - or does =
it grow in height?=20
"flashk" <chengzhu@usc.edu> wrote in message =
news:c7649g$gpd$1@eclipse.org...
Hi Whitney,

My figure backing the Text control is directly inherited from =
Figure, not like StickyLabelFigure inherited from BentCornerFigure. In =
my figure's constructor,=20

{......
setBorder(new MarginBorder(5));

FlowPage flowPage =3D new FlowPage();

textFlow =3D new TextFlow();

textFlow.setLayoutManager(new ParagraphTextLayout(textFlow,

ParagraphTextLayout.WORD_WRAP_SOFT));

flowPage.add(textFlow);

setLayoutManager(new StackLayout());

add(flowPage);

}

And I am not using the Label. As to the CellEditorLocator, I think =
it is used to relocate the Text control boundary, and highlight your =
text selection, am I right?

Thank you very much for your help

Kevin


"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or =
extend to
> multiple lines - I assume this also means the figure that is =
behind the Text
> control is staying the same size as the control? This is likely a =
problem
> with your figure that is backing the Text Control. You said you =
create it
> directly from figure - what are the contents of your figure class? =
Are you
> using Label? It could also be a problem with your =
CellEditorLocator.
>=20
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the StickyLabelFigure =
in logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my TextCellEditor =
class with
> > SWT.MULTI | SWT.WRAP in the class inherited from =
DirectEditManager, but I
> > found my text input won't be either wrap and multi -- it is not =
like
> example
> > in StickyLabelFigure class, the outline of figure will expended =
vertically
> > if you type more words, and it is wrapped. My work doesn't. I =
nearly
> > implemented the same as StickyLabelFigure does, except I create =
my label
> > figure class from Figure directly. Can anyone give me some =
hints? or tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>=20
>
------=_NextPart_000_007E_01C43117.A8AB6470
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>nope it doesn't grow in height, could =
you give me=20
any hints how to make it and syncronize it with text control? thx a=20
lot</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Whitney Sorenson" &lt;<A=20
href=3D"mailto:none@us.ibm.com">none@us.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:c765e7$ig6$1@eclipse.org">news:c765e7$ig6$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>So does the figure size stay in sync =
with the=20
text control - or does it grow in height? </FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A =
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt;=20
wrote in message <A=20
=
href=3D"news:c7649g$gpd$1@eclipse.org">news:c7649g$gpd$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi Whitney,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My figure backing the Text control =
is directly=20
inherited from Figure, not like StickyLabelFigure inherited from=20
BentCornerFigure. In my figure's constructor, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>{......</FONT></DIV>
<DIV>
<P><FONT face=3DArial size=3D2>setBorder(new =
MarginBorder(5));</FONT></P>
<P><FONT face=3DArial size=3D2>FlowPage flowPage =3D new =
FlowPage();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow =3D new =
TextFlow();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow.setLayoutManager(new=20
ParagraphTextLayout(textFlow,</FONT></P>
<P><FONT face=3DArial =
size=3D2>ParagraphTextLayout.WORD_WRAP_SOFT));</FONT></P>
<P><FONT face=3DArial size=3D2>flowPage.add(textFlow);</FONT></P>
<P><FONT face=3DArial size=3D2>setLayoutManager(new =
StackLayout());</FONT></P>
<P><FONT face=3DArial size=3D2>add(flowPage);</FONT></P></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And I am not using the Label. As to =
the=20
CellEditorLocator, I think it is used to relocate the Text control =
boundary,=20
and highlight your text selection, am I right?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you very much for your =
help</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kevin</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>"Whitney Sorenson" &lt;</FONT><A=20
href=3D"mailto:none@us.ibm.com"><FONT face=3DArial=20
size=3D2>none@us.ibm.com</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in=20
message </FONT><A href=3D"news:c75iab$ocp$1@eclipse.org"><FONT =
face=3DArial=20
size=3D2>news:c75iab$ocp$1@eclipse.org</FONT></A><FONT face=3DArial=20
size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>&gt; Are you =
saying the Text=20
control that comes up doesn't wrap or extend to<BR>&gt; multiple =
lines - I=20
assume this also means the figure that is behind the Text<BR>&gt; =
control is=20
staying the same size as the control? This is likely a =
problem<BR>&gt; with=20
your figure that is backing the Text Control. You said you create =
it<BR>&gt;=20
directly from figure - what are the contents of your figure class? =
Are=20
you<BR>&gt; using Label? It could also be a problem with your=20
CellEditorLocator.<BR>&gt; <BR>&gt; "flashk" &lt;</FONT><A=20
href=3D"mailto:chengzhu@usc.edu"><FONT face=3DArial=20
size=3D2>chengzhu@usc.edu</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in=20
message<BR>&gt; </FONT><A =
href=3D"news:c74tlo$vfl$1@eclipse.org"><FONT=20
face=3DArial size=3D2>news:c74tlo$vfl$1@eclipse.org</FONT></A><FONT =
face=3DArial=20
size=3D2>...<BR>&gt; &gt; Hi All,<BR>&gt; &gt;<BR>&gt; &gt; I =
implemented a=20
class which is similar as the StickyLabelFigure in logic<BR>&gt; =
&gt;=20
example, with nearly all kind of necessary classes, e.g.<BR>&gt;=20
DirectEditManager,<BR>&gt; &gt; Policy, CellEditorLocator classes. =
And I set=20
my TextCellEditor class with<BR>&gt; &gt; SWT.MULTI | SWT.WRAP in =
the class=20
inherited from DirectEditManager, but I<BR>&gt; &gt; found my text =
input=20
won't be either wrap and multi -- it is not like<BR>&gt; =
example<BR>&gt;=20
&gt; in StickyLabelFigure class, the outline of figure will expended =

vertically<BR>&gt; &gt; if you type more words, and it is wrapped. =
My work=20
doesn't. I nearly<BR>&gt; &gt; implemented the same as =
StickyLabelFigure=20
does, except I create my label<BR>&gt; &gt; figure class from Figure =

directly. Can anyone give me some hints? or tell<BR>&gt; me<BR>&gt; =
&gt; in=20
which direction I should go for bug? Thx a lot.<BR>&gt; &gt;<BR>&gt; =
&gt;=20
regards<BR>&gt; &gt; Kevin<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; =
<BR>&gt;=20
</FONT></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_007E_01C43117.A8AB6470--
Re: help needed for StickyLabelFigure problem [message #130282 is a reply to message #130258] Mon, 03 May 2004 21:12 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: chengzhu.usc.edu

This is a multi-part message in MIME format.

------=_NextPart_000_0089_01C43118.BD07AEF0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

btw, i didnt find any sync method or method to change figure height in =
the StickyLabelFigure example.=20
"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c765e7$ig6$1@eclipse.org...
So does the figure size stay in sync with the text control - or does =
it grow in height?=20
"flashk" <chengzhu@usc.edu> wrote in message =
news:c7649g$gpd$1@eclipse.org...
Hi Whitney,

My figure backing the Text control is directly inherited from =
Figure, not like StickyLabelFigure inherited from BentCornerFigure. In =
my figure's constructor,=20

{......
setBorder(new MarginBorder(5));

FlowPage flowPage =3D new FlowPage();

textFlow =3D new TextFlow();

textFlow.setLayoutManager(new ParagraphTextLayout(textFlow,

ParagraphTextLayout.WORD_WRAP_SOFT));

flowPage.add(textFlow);

setLayoutManager(new StackLayout());

add(flowPage);

}

And I am not using the Label. As to the CellEditorLocator, I think =
it is used to relocate the Text control boundary, and highlight your =
text selection, am I right?

Thank you very much for your help

Kevin


"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or =
extend to
> multiple lines - I assume this also means the figure that is =
behind the Text
> control is staying the same size as the control? This is likely a =
problem
> with your figure that is backing the Text Control. You said you =
create it
> directly from figure - what are the contents of your figure class? =
Are you
> using Label? It could also be a problem with your =
CellEditorLocator.
>=20
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the StickyLabelFigure =
in logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my TextCellEditor =
class with
> > SWT.MULTI | SWT.WRAP in the class inherited from =
DirectEditManager, but I
> > found my text input won't be either wrap and multi -- it is not =
like
> example
> > in StickyLabelFigure class, the outline of figure will expended =
vertically
> > if you type more words, and it is wrapped. My work doesn't. I =
nearly
> > implemented the same as StickyLabelFigure does, except I create =
my label
> > figure class from Figure directly. Can anyone give me some =
hints? or tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>=20
>
------=_NextPart_000_0089_01C43118.BD07AEF0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>btw, i didnt find any sync method or =
method to=20
change figure height in the StickyLabelFigure example. </FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Whitney Sorenson" &lt;<A=20
href=3D"mailto:none@us.ibm.com">none@us.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:c765e7$ig6$1@eclipse.org">news:c765e7$ig6$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>So does the figure size stay in sync =
with the=20
text control - or does it grow in height? </FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A =
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt;=20
wrote in message <A=20
=
href=3D"news:c7649g$gpd$1@eclipse.org">news:c7649g$gpd$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi Whitney,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My figure backing the Text control =
is directly=20
inherited from Figure, not like StickyLabelFigure inherited from=20
BentCornerFigure. In my figure's constructor, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>{......</FONT></DIV>
<DIV>
<P><FONT face=3DArial size=3D2>setBorder(new =
MarginBorder(5));</FONT></P>
<P><FONT face=3DArial size=3D2>FlowPage flowPage =3D new =
FlowPage();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow =3D new =
TextFlow();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow.setLayoutManager(new=20
ParagraphTextLayout(textFlow,</FONT></P>
<P><FONT face=3DArial =
size=3D2>ParagraphTextLayout.WORD_WRAP_SOFT));</FONT></P>
<P><FONT face=3DArial size=3D2>flowPage.add(textFlow);</FONT></P>
<P><FONT face=3DArial size=3D2>setLayoutManager(new =
StackLayout());</FONT></P>
<P><FONT face=3DArial size=3D2>add(flowPage);</FONT></P></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And I am not using the Label. As to =
the=20
CellEditorLocator, I think it is used to relocate the Text control =
boundary,=20
and highlight your text selection, am I right?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you very much for your =
help</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kevin</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>"Whitney Sorenson" &lt;</FONT><A=20
href=3D"mailto:none@us.ibm.com"><FONT face=3DArial=20
size=3D2>none@us.ibm.com</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in=20
message </FONT><A href=3D"news:c75iab$ocp$1@eclipse.org"><FONT =
face=3DArial=20
size=3D2>news:c75iab$ocp$1@eclipse.org</FONT></A><FONT face=3DArial=20
size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>&gt; Are you =
saying the Text=20
control that comes up doesn't wrap or extend to<BR>&gt; multiple =
lines - I=20
assume this also means the figure that is behind the Text<BR>&gt; =
control is=20
staying the same size as the control? This is likely a =
problem<BR>&gt; with=20
your figure that is backing the Text Control. You said you create =
it<BR>&gt;=20
directly from figure - what are the contents of your figure class? =
Are=20
you<BR>&gt; using Label? It could also be a problem with your=20
CellEditorLocator.<BR>&gt; <BR>&gt; "flashk" &lt;</FONT><A=20
href=3D"mailto:chengzhu@usc.edu"><FONT face=3DArial=20
size=3D2>chengzhu@usc.edu</FONT></A><FONT face=3DArial size=3D2>&gt; =
wrote in=20
message<BR>&gt; </FONT><A =
href=3D"news:c74tlo$vfl$1@eclipse.org"><FONT=20
face=3DArial size=3D2>news:c74tlo$vfl$1@eclipse.org</FONT></A><FONT =
face=3DArial=20
size=3D2>...<BR>&gt; &gt; Hi All,<BR>&gt; &gt;<BR>&gt; &gt; I =
implemented a=20
class which is similar as the StickyLabelFigure in logic<BR>&gt; =
&gt;=20
example, with nearly all kind of necessary classes, e.g.<BR>&gt;=20
DirectEditManager,<BR>&gt; &gt; Policy, CellEditorLocator classes. =
And I set=20
my TextCellEditor class with<BR>&gt; &gt; SWT.MULTI | SWT.WRAP in =
the class=20
inherited from DirectEditManager, but I<BR>&gt; &gt; found my text =
input=20
won't be either wrap and multi -- it is not like<BR>&gt; =
example<BR>&gt;=20
&gt; in StickyLabelFigure class, the outline of figure will expended =

vertically<BR>&gt; &gt; if you type more words, and it is wrapped. =
My work=20
doesn't. I nearly<BR>&gt; &gt; implemented the same as =
StickyLabelFigure=20
does, except I create my label<BR>&gt; &gt; figure class from Figure =

directly. Can anyone give me some hints? or tell<BR>&gt; me<BR>&gt; =
&gt; in=20
which direction I should go for bug? Thx a lot.<BR>&gt; &gt;<BR>&gt; =
&gt;=20
regards<BR>&gt; &gt; Kevin<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; =
<BR>&gt;=20
</FONT></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0089_01C43118.BD07AEF0--
Re: help needed for StickyLabelFigure problem [message #130309 is a reply to message #130282] Mon, 03 May 2004 23:12 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

This is a multi-part message in MIME format.

------=_NextPart_000_0013_01C4313A.3C5C4280
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Everytime you set text on the StickyNoteFigure, it revalidates. This =
should cause it to grow in size. The CellEditorLocator keeps the Text =
control up to date with the Figure. Does your figure call set text on =
the text flow every time the text changes?
"flashk" <chengzhu@usc.edu> wrote in message =
news:c76c5q$r86$1@eclipse.org...
btw, i didnt find any sync method or method to change figure height in =
the StickyLabelFigure example.=20
"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c765e7$ig6$1@eclipse.org...
So does the figure size stay in sync with the text control - or does =
it grow in height?=20
"flashk" <chengzhu@usc.edu> wrote in message =
news:c7649g$gpd$1@eclipse.org...
Hi Whitney,

My figure backing the Text control is directly inherited from =
Figure, not like StickyLabelFigure inherited from BentCornerFigure. In =
my figure's constructor,=20

{......
setBorder(new MarginBorder(5));

FlowPage flowPage =3D new FlowPage();

textFlow =3D new TextFlow();

textFlow.setLayoutManager(new ParagraphTextLayout(textFlow,

ParagraphTextLayout.WORD_WRAP_SOFT));

flowPage.add(textFlow);

setLayoutManager(new StackLayout());

add(flowPage);

}

And I am not using the Label. As to the CellEditorLocator, I think =
it is used to relocate the Text control boundary, and highlight your =
text selection, am I right?

Thank you very much for your help

Kevin


"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or =
extend to
> multiple lines - I assume this also means the figure that is =
behind the Text
> control is staying the same size as the control? This is likely =
a problem
> with your figure that is backing the Text Control. You said you =
create it
> directly from figure - what are the contents of your figure =
class? Are you
> using Label? It could also be a problem with your =
CellEditorLocator.
>=20
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the =
StickyLabelFigure in logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my TextCellEditor =
class with
> > SWT.MULTI | SWT.WRAP in the class inherited from =
DirectEditManager, but I
> > found my text input won't be either wrap and multi -- it is =
not like
> example
> > in StickyLabelFigure class, the outline of figure will =
expended vertically
> > if you type more words, and it is wrapped. My work doesn't. I =
nearly
> > implemented the same as StickyLabelFigure does, except I =
create my label
> > figure class from Figure directly. Can anyone give me some =
hints? or tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>=20
>
------=_NextPart_000_0013_01C4313A.3C5C4280
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Everytime you set text on the =
StickyNoteFigure, it=20
revalidates. This should cause it to grow in size. The CellEditorLocator =
keeps=20
the Text control up to date with the Figure. Does your figure call set =
text on=20
the text flow every time the text changes?</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A =
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt;=20
wrote in message <A=20
=
href=3D"news:c76c5q$r86$1@eclipse.org">news:c76c5q$r86$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>btw, i didnt find any sync method or =
method to=20
change figure height in the StickyLabelFigure example. </FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Whitney Sorenson" &lt;<A=20
href=3D"mailto:none@us.ibm.com">none@us.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:c765e7$ig6$1@eclipse.org">news:c765e7$ig6$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>So does the figure size stay in =
sync with the=20
text control - or does it grow in height? </FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A=20
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt; wrote in =
message=20
<A=20
=
href=3D"news:c7649g$gpd$1@eclipse.org">news:c7649g$gpd$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi Whitney,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My figure backing the Text =
control is=20
directly inherited from Figure, not like StickyLabelFigure =
inherited from=20
BentCornerFigure. In my figure's constructor, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>{......</FONT></DIV>
<DIV>
<P><FONT face=3DArial size=3D2>setBorder(new =
MarginBorder(5));</FONT></P>
<P><FONT face=3DArial size=3D2>FlowPage flowPage =3D new =
FlowPage();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow =3D new =
TextFlow();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow.setLayoutManager(new=20
ParagraphTextLayout(textFlow,</FONT></P>
<P><FONT face=3DArial=20
size=3D2>ParagraphTextLayout.WORD_WRAP_SOFT));</FONT></P>
<P><FONT face=3DArial size=3D2>flowPage.add(textFlow);</FONT></P>
<P><FONT face=3DArial size=3D2>setLayoutManager(new =
StackLayout());</FONT></P>
<P><FONT face=3DArial size=3D2>add(flowPage);</FONT></P></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And I am not using the Label. As =
to the=20
CellEditorLocator, I think it is used to relocate the Text control =

boundary, and highlight your text selection, am I =
right?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you very much for your=20
help</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kevin</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>"Whitney Sorenson" &lt;</FONT><A=20
href=3D"mailto:none@us.ibm.com"><FONT face=3DArial=20
size=3D2>none@us.ibm.com</FONT></A><FONT face=3DArial =
size=3D2>&gt; wrote in=20
message </FONT><A href=3D"news:c75iab$ocp$1@eclipse.org"><FONT =
face=3DArial=20
size=3D2>news:c75iab$ocp$1@eclipse.org</FONT></A><FONT =
face=3DArial=20
size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>&gt; Are you =
saying the=20
Text control that comes up doesn't wrap or extend to<BR>&gt; =
multiple=20
lines - I assume this also means the figure that is behind the=20
Text<BR>&gt; control is staying the same size as the control? This =
is=20
likely a problem<BR>&gt; with your figure that is backing the Text =

Control. You said you create it<BR>&gt; directly from figure - =
what are=20
the contents of your figure class? Are you<BR>&gt; using Label? It =
could=20
also be a problem with your CellEditorLocator.<BR>&gt; <BR>&gt; =
"flashk"=20
&lt;</FONT><A href=3D"mailto:chengzhu@usc.edu"><FONT face=3DArial=20
size=3D2>chengzhu@usc.edu</FONT></A><FONT face=3DArial =
size=3D2>&gt; wrote in=20
message<BR>&gt; </FONT><A =
href=3D"news:c74tlo$vfl$1@eclipse.org"><FONT=20
face=3DArial =
size=3D2>news:c74tlo$vfl$1@eclipse.org</FONT></A><FONT face=3DArial=20
size=3D2>...<BR>&gt; &gt; Hi All,<BR>&gt; &gt;<BR>&gt; &gt; I =
implemented a=20
class which is similar as the StickyLabelFigure in logic<BR>&gt; =
&gt;=20
example, with nearly all kind of necessary classes, e.g.<BR>&gt;=20
DirectEditManager,<BR>&gt; &gt; Policy, CellEditorLocator classes. =
And I=20
set my TextCellEditor class with<BR>&gt; &gt; SWT.MULTI | SWT.WRAP =
in the=20
class inherited from DirectEditManager, but I<BR>&gt; &gt; found =
my text=20
input won't be either wrap and multi -- it is not like<BR>&gt;=20
example<BR>&gt; &gt; in StickyLabelFigure class, the outline of =
figure=20
will expended vertically<BR>&gt; &gt; if you type more words, and =
it is=20
wrapped. My work doesn't. I nearly<BR>&gt; &gt; implemented the =
same as=20
StickyLabelFigure does, except I create my label<BR>&gt; &gt; =
figure class=20
from Figure directly. Can anyone give me some hints? or =
tell<BR>&gt;=20
me<BR>&gt; &gt; in which direction I should go for bug? Thx a =
lot.<BR>&gt;=20
&gt;<BR>&gt; &gt; regards<BR>&gt; &gt; Kevin<BR>&gt; &gt;<BR>&gt;=20
&gt;<BR>&gt; <BR>&gt;=20
</FONT></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML >

------=_NextPart_000_0013_01C4313A.3C5C4280--
Re: help needed for StickyLabelFigure problem [message #130643 is a reply to message #130309] Tue, 04 May 2004 20:12 Go to previous message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

This is a multi-part message in MIME format.

------=_NextPart_000_0067_01C431F2.8DA47AF0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

The figure's constraint needs to have a width specified, but height set =
to -1
This allows the height to grow as needed based on the width.
"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c76fmu$v80$1@eclipse.org...
Everytime you set text on the StickyNoteFigure, it revalidates. This =
should cause it to grow in size. The CellEditorLocator keeps the Text =
control up to date with the Figure. Does your figure call set text on =
the text flow every time the text changes?
"flashk" <chengzhu@usc.edu> wrote in message =
news:c76c5q$r86$1@eclipse.org...
btw, i didnt find any sync method or method to change figure height =
in the StickyLabelFigure example.=20
"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c765e7$ig6$1@eclipse.org...
So does the figure size stay in sync with the text control - or =
does it grow in height?=20
"flashk" <chengzhu@usc.edu> wrote in message =
news:c7649g$gpd$1@eclipse.org...
Hi Whitney,

My figure backing the Text control is directly inherited from =
Figure, not like StickyLabelFigure inherited from BentCornerFigure. In =
my figure's constructor,=20

{......
setBorder(new MarginBorder(5));

FlowPage flowPage =3D new FlowPage();

textFlow =3D new TextFlow();

textFlow.setLayoutManager(new ParagraphTextLayout(textFlow,

ParagraphTextLayout.WORD_WRAP_SOFT));

flowPage.add(textFlow);

setLayoutManager(new StackLayout());

add(flowPage);

}

And I am not using the Label. As to the CellEditorLocator, I =
think it is used to relocate the Text control boundary, and highlight =
your text selection, am I right?

Thank you very much for your help

Kevin


"Whitney Sorenson" <none@us.ibm.com> wrote in message =
news:c75iab$ocp$1@eclipse.org...
> Are you saying the Text control that comes up doesn't wrap or =
extend to
> multiple lines - I assume this also means the figure that is =
behind the Text
> control is staying the same size as the control? This is =
likely a problem
> with your figure that is backing the Text Control. You said =
you create it
> directly from figure - what are the contents of your figure =
class? Are you
> using Label? It could also be a problem with your =
CellEditorLocator.
>=20
> "flashk" <chengzhu@usc.edu> wrote in message
> news:c74tlo$vfl$1@eclipse.org...
> > Hi All,
> >
> > I implemented a class which is similar as the =
StickyLabelFigure in logic
> > example, with nearly all kind of necessary classes, e.g.
> DirectEditManager,
> > Policy, CellEditorLocator classes. And I set my =
TextCellEditor class with
> > SWT.MULTI | SWT.WRAP in the class inherited from =
DirectEditManager, but I
> > found my text input won't be either wrap and multi -- it is =
not like
> example
> > in StickyLabelFigure class, the outline of figure will =
expended vertically
> > if you type more words, and it is wrapped. My work doesn't. =
I nearly
> > implemented the same as StickyLabelFigure does, except I =
create my label
> > figure class from Figure directly. Can anyone give me some =
hints? or tell
> me
> > in which direction I should go for bug? Thx a lot.
> >
> > regards
> > Kevin
> >
> >
>=20
>
------=_NextPart_000_0067_01C431F2.8DA47AF0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>The figure's constraint needs to have a =
width=20
specified, but height set to -1</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>This allows the height to grow as =
needed based on=20
the width.</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Whitney Sorenson" &lt;<A=20
href=3D"mailto:none@us.ibm.com">none@us.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:c76fmu$v80$1@eclipse.org">news:c76fmu$v80$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>Everytime you set text on the =
StickyNoteFigure,=20
it revalidates. This should cause it to grow in size. The =
CellEditorLocator=20
keeps the Text control up to date with the Figure. Does your figure =
call set=20
text on the text flow every time the text changes?</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A =
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt;=20
wrote in message <A=20
=
href=3D"news:c76c5q$r86$1@eclipse.org">news:c76c5q$r86$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>btw, i didnt find any sync method =
or method to=20
change figure height in the StickyLabelFigure example. </FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Whitney Sorenson" &lt;<A=20
href=3D"mailto:none@us.ibm.com">none@us.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:c765e7$ig6$1@eclipse.org">news:c765e7$ig6$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>So does the figure size stay in =
sync with the=20
text control - or does it grow in height? </FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"flashk" &lt;<A=20
href=3D"mailto:chengzhu@usc.edu">chengzhu@usc.edu</A>&gt; wrote =
in message=20
<A=20
=
href=3D"news:c7649g$gpd$1@eclipse.org">news:c7649g$gpd$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi Whitney,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My figure backing the Text =
control is=20
directly inherited from Figure, not like StickyLabelFigure =
inherited=20
from BentCornerFigure. In my figure's constructor, </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>{......</FONT></DIV>
<DIV>
<P><FONT face=3DArial size=3D2>setBorder(new =
MarginBorder(5));</FONT></P>
<P><FONT face=3DArial size=3D2>FlowPage flowPage =3D new=20
FlowPage();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow =3D new =
TextFlow();</FONT></P>
<P><FONT face=3DArial size=3D2>textFlow.setLayoutManager(new=20
ParagraphTextLayout(textFlow,</FONT></P>
<P><FONT face=3DArial=20
size=3D2>ParagraphTextLayout.WORD_WRAP_SOFT));</FONT></P>
<P><FONT face=3DArial =
size=3D2>flowPage.add(textFlow);</FONT></P>
<P><FONT face=3DArial size=3D2>setLayoutManager(new=20
StackLayout());</FONT></P>
<P><FONT face=3DArial size=3D2>add(flowPage);</FONT></P></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And I am not using the Label. =
As to the=20
CellEditorLocator, I think it is used to relocate the Text =
control=20
boundary, and highlight your text selection, am I =
right?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you very much for your=20
help</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kevin</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>"Whitney Sorenson" =
&lt;</FONT><A=20
href=3D"mailto:none@us.ibm.com"><FONT face=3DArial=20
size=3D2>none@us.ibm.com</FONT></A><FONT face=3DArial =
size=3D2>&gt; wrote in=20
message </FONT><A href=3D"news:c75iab$ocp$1@eclipse.org"><FONT =
face=3DArial=20
size=3D2>news:c75iab$ocp$1@eclipse.org</FONT></A><FONT =
face=3DArial=20
size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>&gt; Are =
you saying the=20
Text control that comes up doesn't wrap or extend to<BR>&gt; =
multiple=20
lines - I assume this also means the figure that is behind the=20
Text<BR>&gt; control is staying the same size as the control? =
This is=20
likely a problem<BR>&gt; with your figure that is backing the =
Text=20
Control. You said you create it<BR>&gt; directly from figure - =
what are=20
the contents of your figure class? Are you<BR>&gt; using Label? =
It could=20
also be a problem with your CellEditorLocator.<BR>&gt; <BR>&gt; =
"flashk"=20
&lt;</FONT><A href=3D"mailto:chengzhu@usc.edu"><FONT =
face=3DArial=20
size=3D2>chengzhu@usc.edu</FONT></A><FONT face=3DArial =
size=3D2>&gt; wrote in=20
message<BR>&gt; </FONT><A =
href=3D"news:c74tlo$vfl$1@eclipse.org"><FONT=20
face=3DArial =
size=3D2>news:c74tlo$vfl$1@eclipse.org</FONT></A><FONT=20
face=3DArial size=3D2>...<BR>&gt; &gt; Hi All,<BR>&gt; =
&gt;<BR>&gt; &gt; I=20
implemented a class which is similar as the StickyLabelFigure in =

logic<BR>&gt; &gt; example, with nearly all kind of necessary =
classes,=20
e.g.<BR>&gt; DirectEditManager,<BR>&gt; &gt; Policy, =
CellEditorLocator=20
classes. And I set my TextCellEditor class with<BR>&gt; &gt; =
SWT.MULTI |=20
SWT.WRAP in the class inherited from DirectEditManager, but =
I<BR>&gt;=20
&gt; found my text input won't be either wrap and multi -- it is =
not=20
like<BR>&gt; example<BR>&gt; &gt; in StickyLabelFigure class, =
the=20
outline of figure will expended vertically<BR>&gt; &gt; if you =
type more=20
words, and it is wrapped. My work doesn't. I nearly<BR>&gt; &gt; =

implemented the same as StickyLabelFigure does, except I create =
my=20
label<BR>&gt; &gt; figure class from Figure directly. Can anyone =
give me=20
some hints? or tell<BR>&gt; me<BR>&gt; &gt; in which direction I =
should=20
go for bug? Thx a lot.<BR>&gt; &gt;<BR>&gt; &gt; regards<BR>&gt; =
&gt;=20
Kevin<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; <BR>&gt;=20
=
</FONT></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE ></BODY></HTML>=


------=_NextPart_000_0067_01C431F2.8DA47AF0--
Previous Topic:Running a project as a workbench
Next Topic:Suggestions regarding creating an EMF-GEF based XML editor
Goto Forum:
  


Current Time: Sat Apr 20 00:01:55 GMT 2024

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

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

Back to the top