Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     How to control the spacing between legend items?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
How to control the spacing between legend items?
 Login/Join
 
Member
posted
I have a compound report that has 3 reports and 3 pie graphs. Each Pie graph has different amount of slices, but each pie graph does its best to distribute the legend out along the right side of the graph. This looks odd when you look at the entire compound report and you see different amount of spacing in the legend for each graph.

Any suggestions on how to stop the graph engine from distributing the legend items? Ideally, I would like the legend to start at the top of the legend area and each item to be immediately below the previos one.

Thanks In Advance!
 
Posts: 2 | Registered: September 11, 2006Report This Post
Platinum Member
posted Hide Post
Hi Jack,

By using the following function you can place your legend any where in the Graph u want.

setRect(getLegendArea(),new Rectangle(&x,&y,&w,&h));

where x = x-axis Co-ordinates.
Y = y-axis Co-ordinates.
W = Width.
H = Height.
give the values as per as your Graph Size.

Thanks,
Kalyan


Thanks,
Kalyan.S
------------------------------------
WebFOCUS 7.1.4, Win XP SP2,
Oracle8i.
------------------------------------
 
Posts: 155 | Location: Bangalore. | Registered: January 24, 2006Report This Post
Member
posted Hide Post
Kalyan -
I will give this another try, but the cardinality of the data may vary per customer, so I have to select an arbritary size for the legend rectangle. Unfortunately, the graph engine wants to spread my legend items out to use the entire rectangle. So, if I have 3 items graphed the spacing is larger between items then if I have 4 items graphed. Seems like there should be an option to not distribute the items.

I guess I could determine the quantity of items in the data and derive some logic to dynamically set the legend rectangle size, but this seems like alot of hoops to jump through.
 
Posts: 2 | Registered: September 11, 2006Report This Post
Master
posted Hide Post
Do you have setPlace(true) in your code?

If yes, that's what causes your rectangle to adjust based on the number of series.
We need setPlace(true) to do some adjustment in graph by default but you can set that to false for the methods we need. For example, in your case you can do it by giving this method

setPlaceResize(getLegendArea(),false)

then you can make the rectange dynamically as you want.

Hope this works out for you,


WFConsultant

WF 8105M on Win7/Tomcat
 
Posts: 780 | Location: Florida | Registered: January 09, 2005Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     How to control the spacing between legend items?

Copyright © 1996-2020 Information Builders