Home » Eclipse Projects » GEF » Weird problem with ICellValidator
Weird problem with ICellValidator [message #159406] |
Sat, 27 November 2004 12:15  |
Eclipse User |
|
|
|
Originally posted by: pavan.podila.gmail.com
This is a multi-part message in MIME format.
--------------040005080201050304060805
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Hi,
I have attached a CellValidator for the TextCellEditor of my label.
When I type my text in the TextCellEditor, the label size automatically
grows. However when the isValid() of the CellValidator returns a string
error message, the label size stops growing and resizes just big enough
to fit one character. I am attaching the screenshots below for the two
cases. What could be the problem?
thanks in advance,
Pavan
--------------040005080201050304060805
Content-Type: image/gif;
name="invalid.gif"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="invalid.gif"
R0lGODlhyQCGAIcAAAAAAAMDAwQEBAcHBwgICAsLCwwMDA8PDxAQEBMTExcX FxgYGBsbGxwc
HAAAKysAACsAKyAgICQkJCcnJygoKCsrKywsLC8vLzAwMDMzMzg4ODs7Ozw8 PAAAVSsAVSsr
VStVVVUAAFUAK1UrAFUrK1UAVUBAQENDQ0hISEtLS0xMTE9PT1BQUFNTU1RU VFdXV1hYWFtb
W1xcXF9fX2BgYGRkZGhoaGtra3BwcHNzc3R0dHx8fAArgCsrgABVqitVqjFq xVVVqiuA1FWA
gFWqqlWq1FWq/4ArAIArK6pVANSAK9SqVf+qVYCAgIODg4SEhIeHh4iIiIyM jJCQkJGRkZSU
lJiYmJqampubm5ycnICqgKCgoKOjo6SkpKioqKysrLCwsLS0tLi4uLy8vKrU gIDU/7Tc3Kr/
/9TUgNT/qv/UgP//qsDAwMTExMjIyMzMzNDQ0NTU1NjY2Nzc3NT/////1ODg 4OTk5Ojo6Ozs
7PDw8PT09Pj4+Pz8/P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAA
AA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pyEJkv/JasoAAJPU50SeaAIxWFAD K2vAAqgWQgBk
IJwSaMIK1GcCmTWBiS17GUbfcDwdpMAtFRVIFiBHEBQwD4hMjJkfstYAGUxh C1UYWxMMMIEd
WKCbCqTpDEBKhZRmlImeuxtCm6DQQw6EpS6FKRt9ajumPi4BOsDBAbxGUJ5F RAwSfIsN6PcW
BCzAb3l0ixUEQsLtWY2Dn6yfH2QpPOxxjm4EacAA8nA+tfoBCuoTHtLccAAD uAUFl+SrX/N6
vaahFaRy8SpYD4LXtwRgC2j1pFyo1r8AQMGCk6WIGGDWvDdIwQ1SWNli8bAy 8wlkD12IghhE
R86MklOlfniD2jYLWz94cAAA6owtAFogudfqDA6hzcLr3NCEKLihDwMhbhdU 1gQq+NZ2r13Z
FT4b2iYsFiHAbYJwodta7sJMZ26IghTa512rLkUMtuRaKlHWkCmQ9w1jZa98 50vf+tr3vvjN
r373y9/++ve/AA6wgAdM4AIb+MAITrCChRMQADs=
--------------040005080201050304060805
Content-Type: image/gif;
name="valid.gif"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="valid.gif"
R0lGODlhswCKAIcAAAAAAAMDAwQEBAcHBwgICAsLCwwMDA8PDxAQEBMTExcX FxgYGBsbGxwc
HAAAKysAACsAKyAgICQkJCcnJygoKCsrKywsLC8vLzAwMDMzMzg4ODs7Ozw8 PAAAVSsAVSsr
VStVVVUAAFUAK1UrAFUrK1UAVUBAQENDQ0hISEtLS0xMTE9PT1BQUFNTU1RU VFdXV1hYWFtb
W1xcXF9fX2BgYGRkZGhoaGtra3BwcHNzc3R0dHx8fAArgCsrgABVqitVqjFq xVVVqiuA1FWA
gFWqqlWq1FWq/4ArAIArK6pVANSAK9SqVf+qVYCAgIODg4SEhIeHh4iIiIyM jJCQkJGRkZSU
lJiYmJqampubm5ycnICqgKCgoKSkpKioqKysrLCwsLS0tLi4uLy8vKrUgIDU /7Tc3Kr//9TU
gNT/qv/UgP//qsDAwMTExMjIyMzMzNDQ0NTU1NjY2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oM0ZoK 8jCQJzymCh60
WyY3KUlKrlEHmXxjHOdYR68BAJTRS2UH1UjIrMGvDjWgAQ1iUIADnDB7BVgA 6PpghQEMYAM5
oMAqQ3i+KACgkX1Q5EAOCMqB1AAANVQIK6UAABbwrAli2OQeoiCHTQowgcR8 3thgKUta2tKU
4ExnAIepSVYOxHkmCIMHNXCzBiyAbCkEQAYEQv9NCTRhBf0zgc+aIMWc7ayg btCeDlJQGIEK
JAukIwgKvndEKUotbQ2QwRS2UIW5NcEAE9iBBaB5N5DOoKFUsKhBpSg7xtGz CfbU5DtZ2red
mbShAy2o8gjat+QJJAwDSIwNDmgYBCxgcncsjBXiF9TCvA9sJBQnAvtAzeqt D3aJI0gDBoAH
/U21D1DoX/Ww1oYDGKAwKKBkWc8qVvV1LaoNTYxRkWoQuIJtrf4zW1TBmRhN hoFn4HODFNog
hZvR9Q43y59A9MCFKIQBeTwz6DWT54a//dWnHABAN/uQ0BaYbrJGe0NhszC8 NjQhCm3gw0BM
ywWbNYEKoN3pZJtwhcFDFrYJdCXebKXGWtcO9JqSBe5PwgAATPahbXakGUGm AEDOLlW50I2u
dKdL3epa97rYza52t8vd7nr3u+ANr3jHG7GAAAA7
--------------040005080201050304060805--
|
|
| |
Re: Weird problem with ICellValidator [message #159502 is a reply to message #159485] |
Sun, 28 November 2004 13:52   |
Eclipse User |
|
|
|
Originally posted by: pavan.podila.gmail.com
This is a multi-part message in MIME format.
--------------040204000104090206010401
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Thanks, that answers a part of my query. I still don't understand how
the text of my label is getting set when I change the value inside the
TextCellEditor. I haven't written any explicit code to do that. Can you
tell me how that is happening.
I am using the schema editor code (Database schema editor article) and
over there the label is getting resized irrespective of the validity of
the string entered.
news.eclipse.org wrote:
>The label grows as you're typing because its text is set to what you're
>entering in the TextCellEditor. The answer to your query is in the javadoc
>of CellEditor's getValue() method. It will return null if the value is not
>valid.
>
>
>"Pavan Podila" <pavan.podila@gmail.com> wrote in message
>news:coacnp$5t8$1@www.eclipse.org...
>
>
>>Hi,
>> I have attached a CellValidator for the TextCellEditor of my label.
>>When I type my text in the TextCellEditor, the label size automatically
>>grows. However when the isValid() of the CellValidator returns a string
>>error message, the label size stops growing and resizes just big enough
>>to fit one character. I am attaching the screenshots below for the two
>>cases. What could be the problem?
>>
>>thanks in advance,
>>Pavan
>>
>>
>>
>
>
> ------------------------------------------------------------ ----------------
>----
>
>
>
>
>
>
> ------------------------------------------------------------ ----------------
>----
>
>
>
>
>
>
>
>
--------------040204000104090206010401
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
<tt>Thanks, that answers a part of my query. I still don't understand
how the text of my label is getting set when I change the value inside
the TextCellEditor. I haven't written any explicit code to do that. Can
you tell me how that is happening.<br>
I am using the schema editor code (Database schema editor article) and
over there the label is getting resized irrespective of the validity of
the string entered.</tt><br>
<br>
<br>
news.eclipse.org wrote:
<blockquote cite="midcoasg3$o9q$1@www.eclipse.org" type="cite">
<pre wrap="">The label grows as you're typing because its text is set to what you're
entering in the TextCellEditor. The answer to your query is in the javadoc
of CellEditor's getValue() method. It will return null if the value is not
valid.
"Pavan Podila" <a class="moz-txt-link-rfc2396E" href="mailto:pavan.podila@gmail.com"><pavan.podila@gmail.com></a> wrote in message
<a class="moz-txt-link-freetext" href="news:coacnp$5t8$1@www.eclipse.org">news:coacnp$5t8$1@www.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Hi,
I have attached a CellValidator for the TextCellEditor of my label.
When I type my text in the TextCellEditor, the label size automatically
grows. However when the isValid() of the CellValidator returns a string
error message, the label size stops growing and resizes just big enough
to fit one character. I am attaching the screenshots below for the two
cases. What could be the problem?
thanks in advance,
Pavan
</pre>
</blockquote>
<pre wrap=""><!---->
------------------------------------------------------------ ----------------
----
------------------------------------------------------------ ----------------
----
</pre>
</blockquote>
</body>
</html>
--------------040204000104090206010401--
|
|
|
Re: Weird problem with ICellValidator [message #159903 is a reply to message #159502] |
Tue, 30 November 2004 17:57   |
Eclipse User |
|
|
|
Originally posted by: none.us.ibm.com
This is a multi-part message in MIME format.
------=_NextPart_000_0099_01C4D706.102D5B00
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
A DirectEditPolicy will show feedback in the editpart's figure. I'm not =
sure that anything different happens when isValid returns a message. =
Also, see CellEditorManager to see how it responds to celleditor's =
firing value changed. It should always do the same thing regarding =
feedback and sizing of the celleditor.
"Pavan Podila" <pavan.podila@gmail.com> wrote in message =
news:41AA1E7C.1020703@gmail.com...
Thanks, that answers a part of my query. I still don't understand how =
the text of my label is getting set when I change the value inside the =
TextCellEditor. I haven't written any explicit code to do that. Can you =
tell me how that is happening.
I am using the schema editor code (Database schema editor article) and =
over there the label is getting resized irrespective of the validity of =
the string entered.
news.eclipse.org wrote:=20
The label grows as you're typing because its text is set to what you're
entering in the TextCellEditor. The answer to your query is in the =
javadoc
of CellEditor's getValue() method. It will return null if the value is =
not
valid.
"Pavan Podila" <pavan.podila@gmail.com> wrote in message
news:coacnp$5t8$1@www.eclipse.org...
Hi,
I have attached a CellValidator for the TextCellEditor of my label.
When I type my text in the TextCellEditor, the label size automatically
grows. However when the isValid() of the CellValidator returns a string
error message, the label size stops growing and resizes just big enough
to fit one character. I am attaching the screenshots below for the two
cases. What could be the problem?
thanks in advance,
Pavan
=20
------------------------------------------------------------ -------------=
---
----
------------------------------------------------------------ -------------=
---
----
------=_NextPart_000_0099_01C4D706.102D5B00
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><TITLE></TITLE>
<META http-equiv=3DContent-Type =
content=3Dtext/html;charset=3DISO-8859-1>
<META content=3D"MSHTML 6.00.2800.1476" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY text=3D#000000 bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>A DirectEditPolicy will show feedback =
in the=20
editpart's figure. I'm not sure that anything different happens =
when=20
isValid returns a message. Also, see CellEditorManager to see how =
it=20
responds to celleditor's firing value changed. It should always do =
the=20
same thing regarding feedback and sizing of the celleditor.</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>"Pavan Podila" <<A=20
href=3D"mailto:pavan.podila@gmail.com">pavan.podila@gmail.com</A>> =
wrote in=20
message <A=20
=
href=3D"news:41AA1E7C.1020703@gmail.com">news:41AA1E7C.1020703@gmail.com<=
/A>...</DIV><TT>Thanks,=20
that answers a part of my query. I still don't understand how the text =
of my=20
label is getting set when I change the value inside the =
TextCellEditor. I=20
haven't written any explicit code to do that. Can you tell me how that =
is=20
happening.<BR>I am using the schema editor code (Database schema =
editor=20
article) and over there the label is getting resized irrespective of =
the=20
validity of the string entered.</TT><BR><BR><BR>news.eclipse.org =
wrote:=20
<BLOCKQUOTE cite=3Dmidcoasg3$o9q$1@www.eclipse.org type=3D"cite"><PRE =
wrap=3D"">The label grows as you're typing because its text is set to =
what you're
entering in the TextCellEditor. The answer to your query is in the =
javadoc
of CellEditor's getValue() method. It will return null if the value is =
not
valid.
"Pavan Podila" <A class=3Dmoz-txt-link-rfc2396E =
href=3D"mailto:pavan.podila@gmail.com"><pavan.podila@gmail.com></A>=
wrote in message
<A class=3Dmoz-txt-link-freetext =
href=3D"news:coacnp$5t8$1@www.eclipse.org">news:coacnp$5t8$1@www.eclipse.=
org</A>...
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Hi,
I have attached a CellValidator for the TextCellEditor of my label.
When I type my text in the TextCellEditor, the label size automatically
grows. However when the isValid() of the CellValidator returns a string
error message, the label size stops growing and resizes just big enough
to fit one character. I am attaching the screenshots below for the two
cases. What could be the problem?
thanks in advance,
Pavan
</PRE></BLOCKQUOTE><PRE wrap=3D""><!---->
------------------------------------------------------------ -------------=
---
----
------------------------------------------------------------ -------------=
---
----
</PRE></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>
------=_NextPart_000_0099_01C4D706.102D5B00--
|
|
|
Re: Weird problem with ICellValidator [message #160041 is a reply to message #159903] |
Wed, 01 December 2004 12:36  |
Eclipse User |
|
|
|
Originally posted by: pavan.podila.gmail.com
This is a multi-part message in MIME format.
--------------040802000508020505040405
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Hi Randy,
That really helped. I found the problem was in the
showCurrentEditValue() method of the DirectEditPolicy. I was directly
picking up value from the CellEditor and showing it in the Editpart's
figure. Obviously for invalid values, CellEditor.getValue() returns
null, causing my label figure to become small. Cool, I guess making
mistakes is the only way to understand GEF better!!!
Randy Hudson wrote:
> A DirectEditPolicy will show feedback in the editpart's figure. I'm
> not sure that anything different happens when isValid returns a
> message. Also, see CellEditorManager to see how it responds to
> celleditor's firing value changed. It should always do the same thing
> regarding feedback and sizing of the celleditor.
>
> "Pavan Podila" <pavan.podila@gmail.com
> <mailto:pavan.podila@gmail.com>> wrote in message
> news:41AA1E7C.1020703@gmail.com...
> Thanks, that answers a part of my query. I still don't understand
> how the text of my label is getting set when I change the value
> inside the TextCellEditor. I haven't written any explicit code to
> do that. Can you tell me how that is happening.
> I am using the schema editor code (Database schema editor article)
> and over there the label is getting resized irrespective of the
> validity of the string entered.
>
>
> news.eclipse.org wrote:
>
>>The label grows as you're typing because its text is set to what you're
>>entering in the TextCellEditor. The answer to your query is in the javadoc
>>of CellEditor's getValue() method. It will return null if the value is not
>>valid.
>>
>>
>>"Pavan Podila" <pavan.podila@gmail.com> wrote in message
>>news:coacnp$5t8$1@www.eclipse.org...
>>
>>
>>>Hi,
>>> I have attached a CellValidator for the TextCellEditor of my label.
>>>When I type my text in the TextCellEditor, the label size automatically
>>>grows. However when the isValid() of the CellValidator returns a string
>>>error message, the label size stops growing and resizes just big enough
>>>to fit one character. I am attaching the screenshots below for the two
>>>cases. What could be the problem?
>>>
>>>thanks in advance,
>>>Pavan
>>>
>>>
>>>
>>
>>
>> ------------------------------------------------------------ ----------------
>>----
>>
>>
>>
>>
>>
>>
>> ------------------------------------------------------------ ----------------
>>----
>>
>>
>>
>>
>>
>>
>>
>>
--------------040802000508020505040405
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
<tt>Hi Randy,<br>
That really helped. I found the problem was in the
showCurrentEditValue() method of the DirectEditPolicy. I was directly
picking up value from the CellEditor and showing it in the Editpart's
figure. Obviously for invalid values, CellEditor.getValue() returns
null, causing my label figure to become small. Cool, I guess making
mistakes is the only way to understand GEF better!!!<br>
<br>
<br>
</tt><br>
Randy Hudson wrote:
<blockquote cite="midcoitsr$caf$1@www.eclipse.org" type="cite">
<title></title>
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
<meta content="MSHTML 6.00.2800.1476" name="GENERATOR">
<style></style>
<div><font face="Arial" size="2">A DirectEditPolicy will show
feedback in the editpart's figure. I'm not sure that anything
different happens when isValid returns a message. Also, see
CellEditorManager to see how it responds to celleditor's firing value
changed. It should always do the same thing regarding feedback and
sizing of the celleditor.</font></div>
<blockquote
style="border-left: 2px solid rgb(0, 0, 0); padding-right: 0px; padding-left: 5px; margin-left: 5px; margin-right: 0px;"
dir="ltr">
<div>"Pavan Podila" <<a href="mailto:pavan.podila@gmail.com">pavan.podila@gmail.com</a>>
wrote in message <a href="news:41AA1E7C.1020703@gmail.com">news:41AA1E7C.1020703@gmail.com</a>...</div>
<tt>Thanks, that answers a part of my query. I still don't
understand how the text of my label is getting set when I change the
value inside the TextCellEditor. I haven't written any explicit code to
do that. Can you tell me how that is happening.<br>
I am using the schema editor code (Database schema editor article) and
over there the label is getting resized irrespective of the validity of
the string entered.</tt><br>
<br>
<br>
news.eclipse.org wrote:
<blockquote cite="midcoasg3$o9q$1@www.eclipse.org" type="cite">
<pre wrap="">The label grows as you're typing because its text is set to what you're
entering in the TextCellEditor. The answer to your query is in the javadoc
of CellEditor's getValue() method. It will return null if the value is not
valid.
"Pavan Podila" <a class="moz-txt-link-rfc2396E"
href="mailto:pavan.podila@gmail.com"><pavan.podila@gmail.com></a> wrote in message
<a class="moz-txt-link-freetext"
href="news:coacnp$5t8$1@www.eclipse.org">news:coacnp$5t8$1@www.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Hi,
I have attached a CellValidator for the TextCellEditor of my label.
When I type my text in the TextCellEditor, the label size automatically
grows. However when the isValid() of the CellValidator returns a string
error message, the label size stops growing and resizes just big enough
to fit one character. I am attaching the screenshots below for the two
cases. What could be the problem?
thanks in advance,
Pavan
</pre>
</blockquote>
<pre wrap=""><!---->
------------------------------------------------------------ ----------------
----
------------------------------------------------------------ ----------------
----
</pre>
</blockquote>
</blockquote>
</blockquote>
</body>
</html>
--------------040802000508020505040405--
|
|
|
Goto Forum:
Current Time: Sun Jul 27 13:55:45 EDT 2025
Powered by FUDForum. Page generated in 0.25305 seconds
|