aspose file tools*
The moose likes Other Open Source Projects and the fly likes Cewolf - Vertical Bar Graph - Reduce Bar Width Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "Cewolf - Vertical Bar Graph - Reduce Bar Width" Watch "Cewolf - Vertical Bar Graph - Reduce Bar Width" New topic
Author

Cewolf - Vertical Bar Graph - Reduce Bar Width

Amandeep Aggarwal
Greenhorn

Joined: Jul 11, 2008
Posts: 12
Dear Experts,

Please excuse me if this question has been asked before. I could see similar posts , but those were posted sometime back.
Is there a way to reduce the width of bars in a bar graph.
I am using a vertical 3d bar graph with item labels. Below is the code


The Graph generated is attached as Graph1.jpg.

If I reduce the width of "img" to 500 i.e.
the bar width gets reduced, but the ItemLabels are not displayed and period values on x-axis get truncated(as shown in attachment Graph2.jpg). Is there a work around to reduce the width of bars and still display labels and complete x-axis period values(Eg: Mar 07 in my case).

Any help will be appreciated. Thanks in advance.

Regards,
Aman







[Thumbnail for Graph1.jpg]


[Thumbnail for Graph2.jpg]

Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42950
    
  71
Have you played with the itemMargin value of the BarRenderer postprocessor?
Amandeep Aggarwal
Greenhorn

Joined: Jul 11, 2008
Posts: 12
Thanks for a prompt reply. Yes,I was playing with itemMargin. After your response , I restored to the default itemMargin
The item labels did appear, but they seem to come only if there is a reasonable space between bars(See two attachments) which would depend on the bar length(y axis value). In Graph 1, the labels were not displayed. In Graph 2, the labels were displayed.

It did not help with the Months on x-axis as they still got truncated. Thanks for your help again.



[Thumbnail for Graph1.jpg]

[Thumbnail for Graph2.jpg]

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Cewolf - Vertical Bar Graph - Reduce Bar Width