You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by mccorby <mc...@gmail.com> on 2010/11/04 06:41:21 UTC

JfreeChart plugin and dynamic size of the images

Hi all,
I am using jfreechart plugin to display charts in the application.
Everything was ok until I found out that certain images were clipped. 
This happens to charts having many items in the legend so that only (part
of) the legend is displayed.
Though I can change the height property in the declaration of the action to
be higher, this is not what I'm looking for (there can be other  generated
images larger than the maximum specified in the action).
Is there any way of doing this dynamically?

Cheers,
Jose C.
-- 
View this message in context: http://old.nabble.com/JfreeChart-plugin-and-dynamic-size-of-the-images-tp30129303p30129303.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: JfreeChart plugin and dynamic size of the images

Posted by Maurizio Cucchiara <ma...@gmail.com>.
Did you try to use dynamic variables inside your result declaration?
Something like this:

<result name="success" type="chart">
   <param name="value">chart</param>
   <param name="type">png</param>
   <param name="width">${width}</param>
   <param name="height">${height}</param>
 </result>


2010/11/4 mccorby <mc...@gmail.com>:
>
> I forgot to tell the environment I'm working with:
> - Struts2 2.2.1
> - struts2-jfreechart-plugin-2.2.1
>
>
> mccorby wrote:
>>
>> Hi all,
>> I am using jfreechart plugin to display charts in the application.
>> Everything was ok until I found out that certain images were clipped.
>> This happens to charts having many items in the legend so that only (part
>> of) the legend is displayed.
>> Though I can change the height property in the declaration of the action
>> to be higher, this is not what I'm looking for (there can be other
>> generated images larger than the maximum specified in the action).
>> Is there any way of doing this dynamically?
>>
>> Cheers,
>> Jose C.
>>
>
> --
> View this message in context: http://old.nabble.com/JfreeChart-plugin-and-dynamic-size-of-the-images-tp30129303p30129746.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>



-- 
Maurizio Cucchiara

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: JfreeChart plugin and dynamic size of the images

Posted by mccorby <mc...@gmail.com>.
I forgot to tell the environment I'm working with:
- Struts2 2.2.1
- struts2-jfreechart-plugin-2.2.1


mccorby wrote:
> 
> Hi all,
> I am using jfreechart plugin to display charts in the application.
> Everything was ok until I found out that certain images were clipped. 
> This happens to charts having many items in the legend so that only (part
> of) the legend is displayed.
> Though I can change the height property in the declaration of the action
> to be higher, this is not what I'm looking for (there can be other 
> generated images larger than the maximum specified in the action).
> Is there any way of doing this dynamically?
> 
> Cheers,
> Jose C.
> 

-- 
View this message in context: http://old.nabble.com/JfreeChart-plugin-and-dynamic-size-of-the-images-tp30129303p30129746.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org