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.
How do I put the legend only once in a multi-graph? There doesn't appear to be an option for that in the Advanced Graph Editor.
As you can see in below example, the legend repeats for each multi-graph. I want it only once.
-* File advgraph.fex
GRAPH FILE CAR
-* Created by Advanced Graph Assistant
SUM CAR.BODY.DEALER_COST
BY CAR.ORIGIN.COUNTRY
BY CAR.COMP.CAR
HEADING
"Dealer cost per country"
ON GRAPH PCHOLD FORMAT PNG
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET HAXIS 320
ON GRAPH SET VAXIS 200
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH VLINE
ON GRAPH SET GRWIDTH 2
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 1
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBISouthWestern.txt");
setReportParsingErrors(false);
setSelectionEnableMove(false);
setTransparentBorderColor(getSeries(0),true);
setTransparentBorderColor(getSeries(1),true);
setTransparentBorderColor(getSeries(2),true);
setTransparentBorderColor(getSeries(3),true);
setTransparentBorderColor(getSeries(4),true);
setTransparentBorderColor(getSeries(5),true);
setTransparentBorderColor(getSeries(6),true);
setTransparentBorderColor(getSeries(7),true);
setTransparentBorderColor(getSeries(8),true);
setTransparentBorderColor(getSeries(9),true);
setTransparentBorderColor(getSeries(10),true);
setDepthRadius(0);
setMarkerSizeDefault(50);
setTransparentBorderColor(getChartBackground(),true);
setPlace(true);
setLineBasicStrokeType(getSeries(0),12);
setBorderColor(getO1AxisLine(),new Color(0,0,0));
setFontSizeAbsolute(getDataText(0),true);
setFontSizeInPoints(getDataText(0),10);
setPlaceResize(getDataText(0),0);
setUseSeriesShapes(false);
setSquareMarkers(true);
setMarkerShape(getLegendLabelMarker(0),3);
setDisplay(getSubtitle(),false);
setLineWidth(getO1AxisLine(),2);
setFillColor(getO1AxisLine(),new Color(0,0,0));
setFontSizeAbsolute(getO1Title(),true);
setFontSizeInPoints(getO1Title(),10);
setPlaceResize(getO1Title(),0);
setFontSizeAbsolute(getO1Label(),true);
setFontSizeInPoints(getO1Label(),8);
setPlaceResize(getO1Label(),0);
setLineBasicStrokeType(getO1MajorGrid(),11);setTickStyle(getO1MajorTick(),4);
setDisplay(getO1MajorTick(),false);
setDisplay(getReferenceLineO1(0),false);
setFontSizeAbsolute(getY1Label(),true);
setFontSizeInPoints(getY1Label(),8);
setPlaceResize(getY1Label(),0);
setFontSizeAbsolute(getY1Title(),true);
setFontSizeInPoints(getY1Title(),10);
setPlaceResize(getY1Title(),0);
setFontStyle(getO1Label(),0);
setDisplay(getLegendArea(),true);
setFontSizeAbsolute(getLegendText(),true);
setFontSizeInPoints(getLegendText(),9);
setPlaceResize(getLegendText(),0);
setDisplay(getTitle(),true);
setDisplay(getY1MajorGrid(),false);
setDisplay(getY1MinorGrid(),false);
setDisplay(getReferenceLineY1(0),false);
setDisplay(getO1MajorGrid(),false);
setDisplay(getO1MinorGrid(),false);
setMarkerShape(getSeries(0),0);
setScaleMax(getY1Axis(),150.0);
setScaleMin(getY1Axis(),50.0);
setDisplayOffScale(getY1Axis(),true);
setScaleMustIncludeZero(getY1Axis(),false);
setScaleMinAuto(getY1Axis(),true);
setScaleMaxAuto(getY1Axis(),true);
setLegendPosition(2);
setLegendAutomatic(true);
setTransparentFillColor(getLegendArea(),true);
setSmoothLines(false);
setTextFormatPattern(getY1Label(),"#.#%");
setTextFormatPreset(getY1Label(),28);
setDisplay(getDataText(),true);
setZeroValueDataTextDisplay(false);
setTransparentBorderColor(getFrame(),true);
ENDSTYLE
END
This message has been edited. Last edited by: Wep5622,
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :
If its only HTML, then add some before the graphs.
-HTMLFORM BEGIN
<h1>My Title</h1>
-HTMLFORM END
-* File advgraph.fex
GRAPH FILE CAR
-* Created by Advanced Graph Assistant
SUM CAR.BODY.DEALER_COST
BY CAR.ORIGIN.COUNTRY
BY CAR.COMP.CAR
HEADING
"Dealer cost per country"
ON GRAPH PCHOLD FORMAT PNG
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET HAXIS 320
ON GRAPH SET VAXIS 200
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH VLINE
ON GRAPH SET GRWIDTH 2
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 1
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBISouthWestern.txt");
setReportParsingErrors(false);
setSelectionEnableMove(false);
setTransparentBorderColor(getSeries(0),true);
setTransparentBorderColor(getSeries(1),true);
setTransparentBorderColor(getSeries(2),true);
setTransparentBorderColor(getSeries(3),true);
setTransparentBorderColor(getSeries(4),true);
setTransparentBorderColor(getSeries(5),true);
setTransparentBorderColor(getSeries(6),true);
setTransparentBorderColor(getSeries(7),true);
setTransparentBorderColor(getSeries(8),true);
setTransparentBorderColor(getSeries(9),true);
setTransparentBorderColor(getSeries(10),true);
setDepthRadius(0);
setMarkerSizeDefault(50);
setTransparentBorderColor(getChartBackground(),true);
setPlace(true);
setLineBasicStrokeType(getSeries(0),12);
setBorderColor(getO1AxisLine(),new Color(0,0,0));
setFontSizeAbsolute(getDataText(0),true);
setFontSizeInPoints(getDataText(0),10);
setPlaceResize(getDataText(0),0);
setUseSeriesShapes(false);
setSquareMarkers(true);
setMarkerShape(getLegendLabelMarker(0),3);
setDisplay(getSubtitle(),false);
setLineWidth(getO1AxisLine(),2);
setFillColor(getO1AxisLine(),new Color(0,0,0));
setFontSizeAbsolute(getO1Title(),true);
setFontSizeInPoints(getO1Title(),10);
setPlaceResize(getO1Title(),0);
setFontSizeAbsolute(getO1Label(),true);
setFontSizeInPoints(getO1Label(),8);
setPlaceResize(getO1Label(),0);
setLineBasicStrokeType(getO1MajorGrid(),11);setTickStyle(getO1MajorTick(),4);
setDisplay(getO1MajorTick(),false);
setDisplay(getReferenceLineO1(0),false);
setFontSizeAbsolute(getY1Label(),true);
setFontSizeInPoints(getY1Label(),8);
setPlaceResize(getY1Label(),0);
setFontSizeAbsolute(getY1Title(),true);
setFontSizeInPoints(getY1Title(),10);
setPlaceResize(getY1Title(),0);
setFontStyle(getO1Label(),0);
setDisplay(getLegendArea(),true);
setFontSizeAbsolute(getLegendText(),true);
setFontSizeInPoints(getLegendText(),9);
setPlaceResize(getLegendText(),0);
setDisplay(getTitle(),true);
setDisplay(getY1MajorGrid(),false);
setDisplay(getY1MinorGrid(),false);
setDisplay(getReferenceLineY1(0),false);
setDisplay(getO1MajorGrid(),false);
setDisplay(getO1MinorGrid(),false);
setMarkerShape(getSeries(0),0);
setScaleMax(getY1Axis(),150.0);
setScaleMin(getY1Axis(),50.0);
setDisplayOffScale(getY1Axis(),true);
setScaleMustIncludeZero(getY1Axis(),false);
setScaleMinAuto(getY1Axis(),true);
setScaleMaxAuto(getY1Axis(),true);
setLegendPosition(2);
setLegendAutomatic(true);
setTransparentFillColor(getLegendArea(),true);
setSmoothLines(false);
setTextFormatPattern(getY1Label(),"#.#%");
setTextFormatPreset(getY1Label(),28);
setDisplay(getDataText(),true);
setZeroValueDataTextDisplay(false);
setTransparentBorderColor(getFrame(),true);
ENDSTYLE
END
I'm not talking about the heading, Waz, but about the legend.
How the legend gets rendered depends on how many lines are in my graph and what colours they get assigned by the template. Although I can control that by setting the series colours of the first n series by hand, of course.
I guess I'll go check the Perspective documentation for that...
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :
Yet... HTML is the way to go here, it turns out. Trying to do that in the multi-graph would be troublesome, it seems.
I had assumed that a multi-graph would be a single image, but it's not. It is an image per graph. I could add the legend to only one of the images in the multi-graph. I think that is possible using a DEFINE that evaluates to 'true' or 'false'. However, the legend takes space off the graph image, and since all the images in the multi-graph get the same size, doing so would yield a rather "distorted"-looking result. In my case of 4 graphs I would get 3 graphs that would span almost the full width of the image, but one about half that width because it has the legend next to it...
Thankfully, the HTML route was safe to take here, as the legend items are fixed for these graphs.
I tried doing this with DIV's instead of transparent images, but IE7 just refused to make the DIV's less high than a full line-width. It did work fine in Firefox and (presumably) other standards compliant browsers. I think the IE7 problem was due to it rendering the page in compatibility mode, probably due to the HTML that WF generates.This message has been edited. Last edited by: Wep5622,
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :