Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » problem with images
problem with images [message #70943] Mon, 21 January 2008 15:36 Go to next message
Eclipse UserFriend
Originally posted by: wen.ai.gillardon.de

Hi all rap committers and developers,

I have a Problem with Images. I would like to create an image-object
from an external data resource programmatically, just like this code:
InputStream is = ...;
Image image = Graphics.getImage("test", is);
label.setImage(image);pThis image-object "image" should be deleted
after viewing it.

My problem:
1. How can I dispose this "image"?
2. The Image-Object "image" would finally be saved in a HashMap "images"
(in ResourceFactory.java). Would the HashMap "images" completely be
stored in cache? If so, can I delete such an image-object "image" from
the HashMap "images"? Otherwise, more and more images will be saved in it.
3. How can I change the size of the image-object, if I change the size
of the outside window?

Thank you for your help in advance.

Greetings

Wen
Re: problem with images [message #71136 is a reply to message #70943] Wed, 23 January 2008 08:47 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wen.ai.gillardon.de

Can anyone help me to fix the problem?

Thanks a lot:-))

Wen

Wen Ai schrieb:
> Hi all rap committers and developers,
>
> I have a Problem with Images. I would like to create an image-object
> from an external data resource programmatically, just like this code:
> InputStream is = ...;
> Image image = Graphics.getImage("test", is);
> label.setImage(image);

> This image-object "image" should be deleted
> after viewing it.
>
> My problem:
> 1. How can I dispose this "image"?
> 2. The Image-Object "image" would finally be saved in a HashMap "images"
> (in ResourceFactory.java). Would the HashMap "images" completely be
> stored in cache? If so, can I delete such an image-object "image" from
> the HashMap "images"? Otherwise, more and more images will be saved in it.
> 3. How can I change the size of the image-object, if I change the size
> of the outside window?
>
> Thank you for your help in advance.
>
> Greetings
>
> Wen
Re: problem with images [message #71156 is a reply to message #70943] Wed, 23 January 2008 09:30 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Wen,

It's common practice to use something like JFace's ImageRegistry for
caching reusable images. But it's also reasonable to have a dispose
listener on your control (perhaps on the label, on the composite holding
the label, or specializing the dispose method of a higher level part)
and disposing the image then. I don't think images are normally resized
since that doesn't generally produce pretty results.


Wen Ai wrote:
> Hi all rap committers and developers,
>
> I have a Problem with Images. I would like to create an image-object
> from an external data resource programmatically, just like this code:
> InputStream is = ...;
> Image image = Graphics.getImage("test", is);
> label.setImage(image);pThis image-object "image" should be deleted
> after viewing it.
>
> My problem:
> 1. How can I dispose this "image"?
> 2. The Image-Object "image" would finally be saved in a HashMap
> "images" (in ResourceFactory.java). Would the HashMap "images"
> completely be stored in cache? If so, can I delete such an
> image-object "image" from the HashMap "images"? Otherwise, more and
> more images will be saved in it.
> 3. How can I change the size of the image-object, if I change the size
> of the outside window?
>
> Thank you for your help in advance.
>
> Greetings
>
> Wen
Re: problem with images [message #71858 is a reply to message #71156] Mon, 28 January 2008 09:17 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wen.ai.gillardon.de

Hi,

in our application birt chart works for the graphical representation. If
RAP has offered such a mechanism for cleaning up the images (without
reusing them) from ResourceFactory, please let me know, or resizing the
image without rendering again, or RAP + Birt work already together......

Thanks a lot.

Regards
Wen


Ed Merks schrieb:
> Wen,
>
> It's common practice to use something like JFace's ImageRegistry for
> caching reusable images. But it's also reasonable to have a dispose
> listener on your control (perhaps on the label, on the composite holding
> the label, or specializing the dispose method of a higher level part)
> and disposing the image then. I don't think images are normally resized
> since that doesn't generally produce pretty results.
>
>
> Wen Ai wrote:
>> Hi all rap committers and developers,
>>
>> I have a Problem with Images. I would like to create an image-object
>> from an external data resource programmatically, just like this code:
>> InputStream is = ...;
>> Image image = Graphics.getImage("test", is);
>> label.setImage(image);
>> This image-object "image" should be deleted
>> after viewing it.
>>
>> My problem:
>> 1. How can I dispose this "image"?
>> 2. The Image-Object "image" would finally be saved in a HashMap
>> "images" (in ResourceFactory.java). Would the HashMap "images"
>> completely be stored in cache? If so, can I delete such an
>> image-object "image" from the HashMap "images"? Otherwise, more and
>> more images will be saved in it.
>> 3. How can I change the size of the image-object, if I change the size
>> of the outside window?
>>
>> Thank you for your help in advance.
>>
>> Greetings
>>
>> Wen
Re: problem with images [message #72610 is a reply to message #71858] Fri, 01 February 2008 12:41 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: fappel.innoopract.com

Hi,

as RAP shares images between user sessions, it is currently not possible to
dispose of a single image instance. But RAP stores the images on disk and
does not buffer the images in memory. The registry only contains a link
where the file is located. So memory inpact is pretty low.

Ciao
Frank


"Wen Ai" <wen.ai@gillardon.de> schrieb im Newsbeitrag
news:fnk6jp$p2j$1@build.eclipse.org...
> Hi,
>
> in our application birt chart works for the graphical representation. If
> RAP has offered such a mechanism for cleaning up the images (without
> reusing them) from ResourceFactory, please let me know, or resizing the
> image without rendering again, or RAP + Birt work already together......
>
> Thanks a lot.
>
> Regards
> Wen
>
>
> Ed Merks schrieb:
>> Wen,
>>
>> It's common practice to use something like JFace's ImageRegistry for
>> caching reusable images. But it's also reasonable to have a dispose
>> listener on your control (perhaps on the label, on the composite holding
>> the label, or specializing the dispose method of a higher level part) and
>> disposing the image then. I don't think images are normally resized
>> since that doesn't generally produce pretty results.
>>
>>
>> Wen Ai wrote:
>>> Hi all rap committers and developers,
>>>
>>> I have a Problem with Images. I would like to create an image-object
>>> from an external data resource programmatically, just like this code:
>>> InputStream is = ...;
>>> Image image = Graphics.getImage("test", is);
>>> label.setImage(image);
>>> This image-object "image" should be deleted after viewing it.
>>>
>>> My problem:
>>> 1. How can I dispose this "image"?
>>> 2. The Image-Object "image" would finally be saved in a HashMap "images"
>>> (in ResourceFactory.java). Would the HashMap "images" completely be
>>> stored in cache? If so, can I delete such an image-object "image" from
>>> the HashMap "images"? Otherwise, more and more images will be saved in
>>> it.
>>> 3. How can I change the size of the image-object, if I change the size
>>> of the outside window?
>>>
>>> Thank you for your help in advance.
>>>
>>> Greetings
>>>
>>> Wen
Re: problem with images [message #72638 is a reply to message #72610] Fri, 01 February 2008 12:58 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

This is a multi-part message in MIME format.
--------------050300020701040906060500
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Frank,

I see! I've had problems building up composed images with transparent
overlays. Is that a know problem?


Frank Appel wrote:
> Hi,
>
> as RAP shares images between user sessions, it is currently not possible to
> dispose of a single image instance. But RAP stores the images on disk and
> does not buffer the images in memory. The registry only contains a link
> where the file is located. So memory inpact is pretty low.
>
> Ciao
> Frank
>
>
> "Wen Ai" <wen.ai@gillardon.de> schrieb im Newsbeitrag
> news:fnk6jp$p2j$1@build.eclipse.org...
>
>> Hi,
>>
>> in our application birt chart works for the graphical representation. If
>> RAP has offered such a mechanism for cleaning up the images (without
>> reusing them) from ResourceFactory, please let me know, or resizing the
>> image without rendering again, or RAP + Birt work already together......
>>
>> Thanks a lot.
>>
>> Regards
>> Wen
>>
>>
>> Ed Merks schrieb:
>>
>>> Wen,
>>>
>>> It's common practice to use something like JFace's ImageRegistry for
>>> caching reusable images. But it's also reasonable to have a dispose
>>> listener on your control (perhaps on the label, on the composite holding
>>> the label, or specializing the dispose method of a higher level part) and
>>> disposing the image then. I don't think images are normally resized
>>> since that doesn't generally produce pretty results.
>>>
>>>
>>> Wen Ai wrote:
>>>
>>>> Hi all rap committers and developers,
>>>>
>>>> I have a Problem with Images. I would like to create an image-object
>>>> from an external data resource programmatically, just like this code:
>>>> InputStream is = ...;
>>>> Image image = Graphics.getImage("test", is);
>>>> label.setImage(image);
>>>> This image-object "image" should be deleted after viewing it.
>>>>
>>>> My problem:
>>>> 1. How can I dispose this "image"?
>>>> 2. The Image-Object "image" would finally be saved in a HashMap "images"
>>>> (in ResourceFactory.java). Would the HashMap "images" completely be
>>>> stored in cache? If so, can I delete such an image-object "image" from
>>>> the HashMap "images"? Otherwise, more and more images will be saved in
>>>> it.
>>>> 3. How can I change the size of the image-object, if I change the size
>>>> of the outside window?
>>>>
>>>> Thank you for your help in advance.
>>>>
>>>> Greetings
>>>>
>>>> Wen
>>>>
>
>
>


--------------050300020701040906060500
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">
</head>
<body bgcolor="#ffffff" text="#000000">
Frank,<br>
<br>
I see!&nbsp; I've had problems building up composed images with transparent
overlays.&nbsp; Is that a know problem?<br>
<br>
<br>
Frank Appel wrote:
<blockquote cite="mid:fnv42d$ql4$1@build.eclipse.org" type="cite">
<pre wrap="">Hi,

as RAP shares images between user sessions, it is currently not possible to
dispose of a single image instance. But RAP stores the images on disk and
does not buffer the images in memory. The registry only contains a link
where the file is located. So memory inpact is pretty low.

Ciao
Frank


"Wen Ai" <a class="moz-txt-link-rfc2396E" href="mailto:wen.ai@gillardon.de">&lt;wen.ai@gillardon.de&gt;</a> schrieb im Newsbeitrag
<a class="moz-txt-link-freetext" href="news:fnk6jp$p2j$1@build.eclipse.org">news:fnk6jp$p2j$1@build.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Hi,

in our application birt chart works for the graphical representation. If
RAP has offered such a mechanism for cleaning up the images (without
reusing them) from ResourceFactory, please let me know, or resizing the
image without rendering again, or RAP + Birt work already together......

Thanks a lot.

Regards
Wen


Ed Merks schrieb:
</pre>
<blockquote type="cite">
<pre wrap="">Wen,

It's common practice to use something like JFace's ImageRegistry for
caching reusable images. But it's also reasonable to have a dispose
listener on your control (perhaps on the label, on the composite holding
the label, or specializing the dispose method of a higher level part) and
disposing the image then. I don't think images are normally resized
since that doesn't generally produce pretty results.


Wen Ai wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hi all rap committers and developers,

I have a Problem with Images. I would like to create an image-object
from an external data resource programmatically, just like this code:
InputStream is = ...;
Image image = Graphics.getImage("test", is);
label.setImage(image);
This image-object "image" should be deleted after viewing it.

My problem:
1. How can I dispose this "image"?
2. The Image-Object "image" would finally be saved in a HashMap "images"
(in ResourceFactory.java). Would the HashMap "images" completely be
stored in cache? If so, can I delete such an image-object "image" from
the HashMap "images"? Otherwise, more and more images will be saved in
it.
3. How can I change the size of the image-object, if I change the size
of the outside window?

Thank you for your help in advance.

Greetings

Wen
</pre>
</blockquote>
</blockquote>
</blockquote>
<pre wrap=""><!---->

</pre>
</blockquote>
<br>
</body>
</html>

--------------050300020701040906060500--
Re: problem with images [message #72691 is a reply to message #72638] Fri, 01 February 2008 13:17 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: fappel.innoopract.com

This is a multi-part message in MIME format.

------=_NextPart_000_01BB_01C864DD.2CDB03C0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Yes this should be difficult with the current possibilities. But =
hopefully there will be a solution to this available soon, since we have =
to provide image decorators and if I'm not mistaken this is based on =
composed images.

"Ed Merks" <merks@ca.ibm.com> schrieb im Newsbeitrag =
news:fnv52d$uq6$2@build.eclipse.org...
Frank,

I see! I've had problems building up composed images with transparent =
overlays. Is that a know problem?


Frank Appel wrote:=20
Hi,

as RAP shares images between user sessions, it is currently not possible =
to=20
dispose of a single image instance. But RAP stores the images on disk =
and=20
does not buffer the images in memory. The registry only contains a link=20
where the file is located. So memory inpact is pretty low.

Ciao
Frank


"Wen Ai" <wen.ai@gillardon.de> schrieb im Newsbeitrag=20
news:fnk6jp$p2j$1@build.eclipse.org...
Hi,

in our application birt chart works for the graphical representation. If =

RAP has offered such a mechanism for cleaning up the images (without=20
reusing them) from ResourceFactory, please let me know, or resizing the=20
image without rendering again, or RAP + Birt work already together......

Thanks a lot.

Regards
Wen


Ed Merks schrieb:
Wen,

It's common practice to use something like JFace's ImageRegistry for=20
caching reusable images. But it's also reasonable to have a dispose=20
listener on your control (perhaps on the label, on the composite holding =

the label, or specializing the dispose method of a higher level part) =
and=20
disposing the image then. I don't think images are normally resized=20
since that doesn't generally produce pretty results.


Wen Ai wrote:
Hi all rap committers and developers,

I have a Problem with Images. I would like to create an image-object=20
from an external data resource programmatically, just like this code:
InputStream is =3D ...;
Image image =3D Graphics.getImage("test", is);
label.setImage(image);
This image-object "image" should be deleted after viewing it.

My problem:
1. How can I dispose this "image"?
2. The Image-Object "image" would finally be saved in a HashMap "images" =

(in ResourceFactory.java). Would the HashMap "images" completely be=20
stored in cache? If so, can I delete such an image-object "image" from=20
the HashMap "images"? Otherwise, more and more images will be saved in=20
it.
3. How can I change the size of the image-object, if I change the size=20
of the outside window?

Thank you for your help in advance.

Greetings

Wen=20
=20

=20

------=_NextPart_000_01BB_01C864DD.2CDB03C0
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=3Dtext/html;charset=3DISO-8859-1>
<META content=3D"MSHTML 6.00.6000.16587" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY text=3D#000000 bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Yes this should be difficult with the =
current=20
possibilities. But&nbsp;hopefully there will be a solution to this =
available=20
soon, since we have to provide image decorators and if I'm not=20
mistaken&nbsp;this is based on&nbsp;composed images.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A =
href=3D"mailto:merks@ca.ibm.com">merks@ca.ibm.com</A>&gt;=20
schrieb im Newsbeitrag <A=20
=
href=3D"news:fnv52d$uq6$2@build.eclipse.org">news:fnv52d$uq6$2@build.ecli=
pse.org</A>...</DIV>Frank,<BR><BR>I=20
see!&nbsp; I've had problems building up composed images with =
transparent=20
overlays.&nbsp; Is that a know problem?<BR><BR><BR>Frank Appel wrote:=20
<BLOCKQUOTE cite=3Dmid:fnv42d$ql4$1@build.eclipse.org =
type=3D"cite"><PRE wrap=3D"">Hi,

as RAP shares images between user sessions, it is currently not possible =
to=20
dispose of a single image instance. But RAP stores the images on disk =
and=20
does not buffer the images in memory. The registry only contains a link=20
where the file is located. So memory inpact is pretty low.

Ciao
Frank


"Wen Ai" <A class=3Dmoz-txt-link-rfc2396E =
href=3D"mailto:wen.ai@gillardon.de">&lt;wen.ai@gillardon.de&gt;</A> =
schrieb im Newsbeitrag=20
<A class=3Dmoz-txt-link-freetext =
href=3D"news:fnk6jp$p2j$1@build.eclipse.org">news:fnk6jp$p2j$1@build.ecli=
pse.org</A>...
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Hi,

in our application birt chart works for the graphical representation. If =

RAP has offered such a mechanism for cleaning up the images (without=20
reusing them) from ResourceFactory, please let me know, or resizing the=20
image without rendering again, or RAP + Birt work already together......

Thanks a lot.

Regards
Wen


Ed Merks schrieb:
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Wen,

It's common practice to use something like JFace's ImageRegistry for=20
caching reusable images. But it's also reasonable to have a dispose=20
listener on your control (perhaps on the label, on the composite holding =

the label, or specializing the dispose method of a higher level part) =
and=20
disposing the image then. I don't think images are normally resized=20
since that doesn't generally produce pretty results.


Wen Ai wrote:
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Hi all rap committers =
and developers,

I have a Problem with Images. I would like to create an image-object=20
from an external data resource programmatically, just like this code:
InputStream is =3D ...;
Image image =3D Graphics.getImage("test", is);
label.setImage(image);
This image-object "image" should be deleted after viewing it.

My problem:
1. How can I dispose this "image"?
2. The Image-Object "image" would finally be saved in a HashMap "images" =

(in ResourceFactory.java). Would the HashMap "images" completely be=20
stored in cache? If so, can I delete such an image-object "image" from=20
the HashMap "images"? Otherwise, more and more images will be saved in=20
it.
3. How can I change the size of the image-object, if I change the size=20
of the outside window?

Thank you for your help in advance.

Greetings

Wen=20
</PRE></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE><PRE =
wrap=3D""><!---->

</PRE></BLOCKQUOTE><BR></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_01BB_01C864DD.2CDB03C0--
Re: problem with images [message #72725 is a reply to message #72691] Fri, 01 February 2008 13:46 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

This is a multi-part message in MIME format.
--------------020900050106010508030403
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Frank,

That's what I suspected. Yes decorators as supported by the workbench
navigators are based on composing icons with overlays. Is there a
bugzilla I could track?


Frank Appel wrote:
> Yes this should be difficult with the current possibilities.
> But hopefully there will be a solution to this available soon, since
> we have to provide image decorators and if I'm not mistaken this is
> based on composed images.
>
>
> "Ed Merks" <merks@ca.ibm.com <mailto:merks@ca.ibm.com>> schrieb im
> Newsbeitrag news:fnv52d$uq6$2@build.eclipse.org...
> Frank,
>
> I see! I've had problems building up composed images with
> transparent overlays. Is that a know problem?
>
>
> Frank Appel wrote:
>> Hi,
>>
>> as RAP shares images between user sessions, it is currently not possible to
>> dispose of a single image instance. But RAP stores the images on disk and
>> does not buffer the images in memory. The registry only contains a link
>> where the file is located. So memory inpact is pretty low.
>>
>> Ciao
>> Frank
>>
>>
>> "Wen Ai" <wen.ai@gillardon.de> schrieb im Newsbeitrag
>> news:fnk6jp$p2j$1@build.eclipse.org...
>>
>>> Hi,
>>>
>>> in our application birt chart works for the graphical representation. If
>>> RAP has offered such a mechanism for cleaning up the images (without
>>> reusing them) from ResourceFactory, please let me know, or resizing the
>>> image without rendering again, or RAP + Birt work already together......
>>>
>>> Thanks a lot.
>>>
>>> Regards
>>> Wen
>>>
>>>
>>> Ed Merks schrieb:
>>>
>>>> Wen,
>>>>
>>>> It's common practice to use something like JFace's ImageRegistry for
>>>> caching reusable images. But it's also reasonable to have a dispose
>>>> listener on your control (perhaps on the label, on the composite holding
>>>> the label, or specializing the dispose method of a higher level part) and
>>>> disposing the image then. I don't think images are normally resized
>>>> since that doesn't generally produce pretty results.
>>>>
>>>>
>>>> Wen Ai wrote:
>>>>
>>>>> Hi all rap committers and developers,
>>>>>
>>>>> I have a Problem with Images. I would like to create an image-object
>>>>> from an external data resource programmatically, just like this code:
>>>>> InputStream is = ...;
>>>>> Image image = Graphics.getImage("test", is);
>>>>> label.setImage(image);
>>>>> This image-object "image" should be deleted after viewing it.
>>>>>
>>>>> My problem:
>>>>> 1. How can I dispose this "image"?
>>>>> 2. The Image-Object "image" would finally be saved in a HashMap "images"
>>>>> (in ResourceFactory.java). Would the HashMap "images" completely be
>>>>> stored in cache? If so, can I delete such an image-object "image" from
>>>>> the HashMap "images"? Otherwise, more and more images will be saved in
>>>>> it.
>>>>> 3. How can I change the size of the image-object, if I change the size
>>>>> of the outside window?
>>>>>
>>>>> Thank you for your help in advance.
>>>>>
>>>>> Greetings
>>>>>
>>>>> Wen
>>>>>
>>
>>
>>
>


--------------020900050106010508030403
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">
</head>
<body bgcolor="#ffffff" text="#000000">
Frank,<br>
<br>
That's what I suspected.&nbsp; Yes decorators as supported by the workbench
navigators are based on composing icons with overlays.&nbsp; Is there a
bugzilla I could track?<br>
<br>
<br>
Frank Appel wrote:
<blockquote cite="mid:fnv65d$60e$1@build.eclipse.org" type="cite">
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
<meta content="MSHTML 6.00.6000.16587" name="GENERATOR">
<style></style>
<div><font face="Arial" size="2">Yes this should be difficult with
the current possibilities. But&nbsp;hopefully there will be a solution to
this available soon, since we have to provide image decorators and if
I'm not mistaken&nbsp;this is based on&nbsp;composed images.</font></div>
<div>&nbsp;</div>
<blockquote
style="border-left: 2px solid rgb(0, 0, 0); padding-right: 0px; padding-left: 5px; margin-left: 5px; margin-right: 0px;">
<div>"Ed Merks" &lt;<a moz-do-not-send="true"
href="mailto:merks@ca.ibm.com">merks@ca.ibm.com</a>&gt; schrieb im
Newsbeitrag <a moz-do-not-send="true"
href="news:fnv52d$uq6$2@build.eclipse.org">news:fnv52d$uq6$2@build.eclipse.org</a>...</div>
Frank,<br>
<br>
I see!&nbsp; I've had problems building up composed images with transparent
overlays.&nbsp; Is that a know problem?<br>
<br>
<br>
Frank Appel wrote:
<blockquote cite="mid:fnv42d$ql4$1@build.eclipse.org" type="cite">
<pre wrap="">Hi,

as RAP shares images between user sessions, it is currently not possible to
dispose of a single image instance. But RAP stores the images on disk and
does not buffer the images in memory. The registry only contains a link
where the file is located. So memory inpact is pretty low.

Ciao
Frank


"Wen Ai" <a moz-do-not-send="true" class="moz-txt-link-rfc2396E"
href="mailto:wen.ai@gillardon.de">&lt;wen.ai@gillardon.de&gt;</a> schrieb im Newsbeitrag
<a moz-do-not-send="true" class="moz-txt-link-freetext"
href="news:fnk6jp$p2j$1@build.eclipse.org">news:fnk6jp$p2j$1@build.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Hi,

in our application birt chart works for the graphical representation. If
RAP has offered such a mechanism for cleaning up the images (without
reusing them) from ResourceFactory, please let me know, or resizing the
image without rendering again, or RAP + Birt work already together......

Thanks a lot.

Regards
Wen


Ed Merks schrieb:
</pre>
<blockquote type="cite">
<pre wrap="">Wen,

It's common practice to use something like JFace's ImageRegistry for
caching reusable images. But it's also reasonable to have a dispose
listener on your control (perhaps on the label, on the composite holding
the label, or specializing the dispose method of a higher level part) and
disposing the image then. I don't think images are normally resized
since that doesn't generally produce pretty results.


Wen Ai wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hi all rap committers and developers,

I have a Problem with Images. I would like to create an image-object
from an external data resource programmatically, just like this code:
InputStream is = ...;
Image image = Graphics.getImage("test", is);
label.setImage(image);
This image-object "image" should be deleted after viewing it.

My problem:
1. How can I dispose this "image"?
2. The Image-Object "image" would finally be saved in a HashMap "images"
(in ResourceFactory.java). Would the HashMap "images" completely be
stored in cache? If so, can I delete such an image-object "image" from
the HashMap "images"? Otherwise, more and more images will be saved in
it.
3. How can I change the size of the image-object, if I change the size
of the outside window?

Thank you for your help in advance.

Greetings

Wen
</pre>
</blockquote>
</blockquote>
</blockquote>
<pre wrap=""><!---->

</pre>
</blockquote>
<br>
</blockquote>
</blockquote>
<br>
</body>
</html>

--------------020900050106010508030403--
Re: problem with images [message #72741 is a reply to message #72725] Fri, 01 February 2008 14:12 Go to previous message
Eclipse UserFriend
Originally posted by: fappel.innoopract.com

This is a multi-part message in MIME format.

------=_NextPart_000_0054_01C864E4.EBA8F9E0
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit

Hi again,

I've created bug #217437 to track the progress. Hope that's what you
need :-)


Ciao
Frank


_____

Von: Ed Merks [mailto:merks@ca.ibm.com]
Bereitgestellt: Freitag, 1. Februar 2008 14:46
Bereitgestellt in: eclipse.technology.rap
Unterhaltung: problem with images
Betreff: Re: problem with images


Frank,

That's what I suspected. Yes decorators as supported by the workbench
navigators are based on composing icons with overlays. Is there a
bugzilla I could track?


Frank Appel wrote:

Yes this should be difficult with the current possibilities. But
hopefully there will be a solution to this available soon, since we have
to provide image decorators and if I'm not mistaken this is based on
composed images.


"Ed Merks" <merks@ca.ibm.com> schrieb im Newsbeitrag
news:fnv52d$uq6$2@build.eclipse.org...
Frank,

I see! I've had problems building up composed images with transparent
overlays. Is that a know problem?


Frank Appel wrote:

Hi,



as RAP shares images between user sessions, it is currently not possible
to

dispose of a single image instance. But RAP stores the images on disk
and

does not buffer the images in memory. The registry only contains a link

where the file is located. So memory inpact is pretty low.



Ciao

Frank





"Wen Ai" <mailto:wen.ai@gillardon.de> <wen.ai@gillardon.de> schrieb im
Newsbeitrag

news:fnk6jp$p2j$1@build.eclipse.org...



Hi,



in our application birt chart works for the graphical representation. If


RAP has offered such a mechanism for cleaning up the images (without

reusing them) from ResourceFactory, please let me know, or resizing the

image without rendering again, or RAP + Birt work already together......



Thanks a lot.



Regards

Wen





Ed Merks schrieb:



Wen,



It's common practice to use something like JFace's ImageRegistry for

caching reusable images. But it's also reasonable to have a dispose

listener on your control (perhaps on the label, on the composite holding


the label, or specializing the dispose method of a higher level part)
and

disposing the image then. I don't think images are normally resized

since that doesn't generally produce pretty results.





Wen Ai wrote:



Hi all rap committers and developers,



I have a Problem with Images. I would like to create an image-object

from an external data resource programmatically, just like this code:

InputStream is = ...;

Image image = Graphics.getImage("test", is);

label.setImage(image);

This image-object "image" should be deleted after viewing it.



My problem:

1. How can I dispose this "image"?

2. The Image-Object "image" would finally be saved in a HashMap "images"


(in ResourceFactory.java). Would the HashMap "images" completely be

stored in cache? If so, can I delete such an image-object "image" from

the HashMap "images"? Otherwise, more and more images will be saved in

it.

3. How can I change the size of the image-object, if I change the size

of the outside window?



Thank you for your help in advance.



Greetings



Wen












------=_NextPart_000_0054_01C864E4.EBA8F9E0
Content-Type: text/html;
charset="us-ascii"
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=3Dus-ascii">
<META content=3D"MSHTML 6.00.6000.16587" name=3DGENERATOR></HEAD>
<BODY text=3D#000000 bgColor=3D#ffffff>
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008>Hi again,</SPAN></FONT></DIV>
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008></SPAN></FONT>&nbsp;</DIV >
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008>I've created bug #217437 to track the =
progress. Hope=20
that's what you need :-)</SPAN></FONT></DIV>
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008></SPAN></FONT>&nbsp;</DIV >
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008></SPAN></FONT>&nbsp;</DIV >
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008>Ciao</SPAN></FONT></DIV>
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008>Frank</SPAN></FONT></DIV>
<DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff =
size=3D2><SPAN=20
class=3D128341014-01022008></SPAN></FONT>&nbsp;</DIV ><BR>
<DIV class=3DOutlookMessageHeader lang=3Dde dir=3Dltr align=3Dleft>
<HR tabIndex=3D-1>
<FONT face=3DTahoma size=3D2><B>Von:</B> Ed Merks =
[mailto:merks@ca.ibm.com]=20
<BR><B>Bereitgestellt:</B> Freitag, 1. Februar 2008 =
14:46<BR><B>Bereitgestellt=20
in:</B> eclipse.technology.rap<BR><B>Unterhaltung:</B> problem with=20
images<BR><B>Betreff:</B> Re: problem with=20
images<BR><BR></FONT></DIV>Frank,<BR><BR>That's what I suspected.&nbsp; =
Yes=20
decorators as supported by the workbench navigators are based on =
composing icons=20
with overlays.&nbsp; Is there a bugzilla I could track?<BR><BR><BR>Frank =
Appel=20
wrote:=20
<BLOCKQUOTE cite=3Dmid:fnv65d$60e$1@build.eclipse.org type=3D"cite">
<META content=3D"MSHTML 6.00.6000.16587" name=3DGENERATOR>
<STYLE></STYLE>

<DIV><FONT face=3DArial size=3D2>Yes this should be difficult with the =
current=20
possibilities. But&nbsp;hopefully there will be a solution to this =
available=20
soon, since we have to provide image decorators and if I'm not=20
mistaken&nbsp;this is based on&nbsp;composed images.</FONT></DIV>
<DIV>&nbsp;</DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: rgb(0,0,0) 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A href=3D"mailto:merks@ca.ibm.com"=20
moz-do-not-send=3D"true">merks@ca.ibm.com</A>&gt; schrieb im =
Newsbeitrag <A=20
href=3D"news:fnv52d$uq6$2@build.eclipse.org"=20
=
moz-do-not-send=3D"true">news:fnv52d$uq6$2@build.eclipse.org</A>...</DIV>=
Frank,<BR><BR>I=20
see!&nbsp; I've had problems building up composed images with =
transparent=20
overlays.&nbsp; Is that a know problem?<BR><BR><BR>Frank Appel =
wrote:=20
<BLOCKQUOTE cite=3Dmid:fnv42d$ql4$1@build.eclipse.org =
type=3D"cite"><PRE wrap=3D"">Hi,

as RAP shares images between user sessions, it is currently not possible =
to=20
dispose of a single image instance. But RAP stores the images on disk =
and=20
does not buffer the images in memory. The registry only contains a link=20
where the file is located. So memory inpact is pretty low.

Ciao
Frank


"Wen Ai" <A class=3Dmoz-txt-link-rfc2396E =
href=3D"mailto:wen.ai@gillardon.de" =
moz-do-not-send=3D"true">&lt;wen.ai@gillardon.de&gt;</A> schrieb im =
Newsbeitrag=20
<A class=3Dmoz-txt-link-freetext =
href=3D"news:fnk6jp$p2j$1@build.eclipse.org" =
moz-do-not-send=3D"true">news:fnk6jp$p2j$1@build.eclipse.org</A>...
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Hi,

in our application birt chart works for the graphical representation. If =

RAP has offered such a mechanism for cleaning up the images (without=20
reusing them) from ResourceFactory, please let me know, or resizing the=20
image without rendering again, or RAP + Birt work already together......

Thanks a lot.

Regards
Wen


Ed Merks schrieb:
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Wen,

It's common practice to use something like JFace's ImageRegistry for=20
caching reusable images. But it's also reasonable to have a dispose=20
listener on your control (perhaps on the label, on the composite holding =

the label, or specializing the dispose method of a higher level part) =
and=20
disposing the image then. I don't think images are normally resized=20
since that doesn't generally produce pretty results.


Wen Ai wrote:
</PRE>
<BLOCKQUOTE type=3D"cite"><PRE wrap=3D"">Hi all rap committers =
and developers,

I have a Problem with Images. I would like to create an image-object=20
from an external data resource programmatically, just like this code:
InputStream is =3D ...;
Image image =3D Graphics.getImage("test", is);
label.setImage(image);
This image-object "image" should be deleted after viewing it.

My problem:
1. How can I dispose this "image"?
2. The Image-Object "image" would finally be saved in a HashMap "images" =

(in ResourceFactory.java). Would the HashMap "images" completely be=20
stored in cache? If so, can I delete such an image-object "image" from=20
the HashMap "images"? Otherwise, more and more images will be saved in=20
it.
3. How can I change the size of the image-object, if I change the size=20
of the outside window?

Thank you for your help in advance.

Greetings

Wen=20
</PRE></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE><PRE =
wrap=3D""><!---->

</PRE></BLOCKQUOTE><BR></BLOCKQUOTE></BLOCKQUOTE><BR></BODY ></HTML>

------=_NextPart_000_0054_01C864E4.EBA8F9E0--
Previous Topic:Hyperlink disabled for messages in Forms
Next Topic:Problem with patch fragments
Goto Forum:
  


Current Time: Thu Mar 28 10:19:50 GMT 2024

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

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

Back to the top