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     [SOLVED] Compound doc, pie chart, legend, white space

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Compound doc, pie chart, legend, white space
 Login/Join
 
Member
posted
I am building a compound document which will contain 3 columns of reports and graphs. I am trying to minimize white space around graphs, and between the different reports/graphs.

The first graph on the doc is a pie chart. With setRect(getPieFrame(),new Rectangle(x,y,width,height)) I can move the pie chart around the graph rectangle. However setLegendRect(new Rectangle(x,y,w,h)) does not seem to affect the legend at all. I have tried extreme values for x, y, w and h and the legend does not change. I have read through the API guide, looked through the forum and searched the internet, but cannot determine what I am doing wrong. Below is the code for this pie chart. Any ideas, or pointing me to a source which provides a great explanation of graphics would be great appreciated.

Thank you,

Jim

SET HTMLARCHIVE=ON
COMPOUND LAYOUT PCHOLD FORMAT PDF
UNITS=IN, $
SECTION=section1, LAYOUT=ON, METADATA='0.5^0.5^0.5^0.5^4', MERGE=OFF, ORIENTATION=LANDSCAPE, PAGESIZE=Letter, SHOW_GLOBALFILTER=OFF, $
PAGELAYOUT=1, NAME='Page layout 1', text='Page layout 1', TOC-LEVEL=1, BOTTOMMARGIN=0.5, TOPMARGIN=0.5, ORIENTATION=LANDSCAPE, METADATA='BOTTOMMARGIN=0.5,TOPMARGIN=0.5,LEFTMARGIN=0,RIGHTMARGIN=0,ORIENTATION=LANDSCAPE,', $
COMPONENT='graph1', TEXT='graph1', TOC-LEVEL=2, POSITION=(0.500 0.700), DIMENSION=(4.000 1.799), COMPONENT-TYPE=GRAPH, METADATA='Z-INDEX: 100; POSITION: absolute; WIDTH: 4in; HEIGHT: 1.799in; TOP: 0.7in; LEFT: 0.5in', $
COMPONENT='graph2', TEXT='graph2', TOC-LEVEL=2, POSITION=(0.500 2.700), DIMENSION=(1.000 1.500), COMPONENT-TYPE=GRAPH, METADATA='Z-INDEX: 100; POSITION: absolute; WIDTH: 1in; HEIGHT: 1.5in; TOP: 2.7in; LEFT: 0.5in', $
COMPONENT='graph3', TEXT='graph3', TOC-LEVEL=2, POSITION=(1.600 2.700), DIMENSION=(2.500 1.500), COMPONENT-TYPE=GRAPH, METADATA='Z-INDEX: 100; POSITION: absolute; WIDTH: 2.5in; HEIGHT: 1.5in; TOP: 2.7in; LEFT: 1.6in', $
COMPONENT='report1', TEXT='report1', TOC-LEVEL=2, POSITION=(0.500 4.400), DIMENSION=(4.000 2.890), METADATA='Z-INDEX: 100; POSITION: absolute; WIDTH: 4in; HEIGHT: 2.89in; TOP: 4.4in; LEFT: 0.5in', $
COMPONENT='graph4', TEXT='graph4', TOC-LEVEL=2, POSITION=(0.500 7.600), DIMENSION=(3.958 1.250), COMPONENT-TYPE=GRAPH, METADATA='Z-INDEX: 100; POSITION: absolute; WIDTH: 3.958in; HEIGHT: 1.25in; TOP: 7.6in; LEFT: 0.5in', $
OBJECT=STRING, NAME='text1', TEXT='Total Invoiced - TTX and Agency', POSITION=(1.500 0.500), MARKUP=ON, WRAP=ON, DIMENSION=(2.167 0.167), style=bold, METADATA='', $
OBJECT=STRING, NAME='text2', TEXT='Total Invoiced by Type', POSITION=(1.250 2.500), MARKUP=ON, WRAP=ON, DIMENSION=(1.542 0.167), style=bold, METADATA='', $
OBJECT=STRING, NAME='text3', TEXT='TTX Top Invoiced Customers', POSITION=(1.250 4.167), MARKUP=ON, WRAP=ON, DIMENSION=(2.000 0.167), style=bold, METADATA='', $
OBJECT=STRING, NAME='text4', TEXT='Total Adjustments - TTX and Agency', POSITION=(1.250 7.292), MARKUP=ON, WRAP=ON, DIMENSION=(2.500 0.167), style=bold, METADATA='', $
OBJECT=STRING, NAME='text5', TEXT='Accounts Receivable Dashboard', POSITION=(5.510 0.094), MARKUP=ON, WRAP=ON, DIMENSION=(3.333 0.417), style=bold, METADATA='', $
END
SET COMPONENT='graph1'
-*component_type graph
DEFINE FILE FIN_INVOICE_DETAILS
DNAME/A10=
IF FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.MASTERBA EQ 'UTLX' THEN 'Union Tank'
ELSE FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.MASTERBA;
END
TABLE FILE FIN_INVOICE_DETAILS
SUM COMPUTE Total/D12.0M=FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.AMOUNT / 1000 ;
COMPUTE MYSORT/A50 = DNAME || '-' || LJUST(15,(FTOA(Total,'(D12.0M)','A15')),'A15');
BY FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.DNAME
WHERE FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.RECORD_DT EQ '&RECORD_DT' AND FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.BUSA NE 'TXRC' AND FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.TYP NE 'WO' OR 'RM' AND FIN_INVOICE_DETAILS.FIN_INVOICE_DETAILS.ACCOUNT NE 'TXRC';
ON TABLE HOLD AS FINHOLD
END
GRAPH FILE FINHOLD
SUM FINHOLD.FINHOLD.Total
BY FINHOLD.FINHOLD.MYSORT
ON GRAPH PCHOLD FORMAT PNG
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET VZERO OFF
ON GRAPH SET HAXIS 27648
ON GRAPH SET VAXIS 12456
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH PIESINGL
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 1
ON GRAPH SET GRXAXIS 0
ON GRAPH SET GRAPHSTYLE *
setReportParsingErrors(false);
setSelectionEnableMove(false);
setDepthRadius(5);
setTransparentBorderColor(getChartBackground(),true);
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);
setPlace(false);
-*setTextFormatPreset(getPieSliceLabel(),6);
setFillColor(getSeries(0),new Color(93,138,200));
setFillColor(getSeries(1),new Color(128,0,0));
setFillColor(getSeries(2),new Color(255,194,6));
setFillColor(getSeries(3),new Color(192,192,192));
setFillColor(getSeries(4),new Color(255,128,0));
setFillColor(getSeries(5),new Color(255,127,80));
setFillColor(getSeries(6),new Color(74,74,74));
-*setRect(getFrame(), new Rectangle(-16000,-16000,32000,32000));
setLegendOrient(0);
setRect(getPieFrame(),new Rectangle(-16000,-5000,25000,22000));
setLegendRect(new Rectangle(13000,-1000,1000,10000));
setExtendToFrameEdge(true);
-*setLegendDisplay(true);
setPieFeelerTextDisplay(0);
-*setDisplay(getLegendArea(),true);
-*setLegendPosition(2);
setPieDepth(50);
setPieTilt(70);
setDisplay(getPieLabel(),false);
ENDSTYLE
END

This message has been edited. Last edited by: <Kathryn Henning>,


WebFOCUS release 7.7.03
WinNT 6.0 64bit
 
Posts: 10 | Registered: December 23, 2010Report This Post
Member
posted Hide Post
Hi jim,

I have couple of observations.
Ur HAXIS and VAXIS values are too high i guess.
I gave default values 770 and 440 for the axes.

try giving
setLegendAutomatic(false);
and check whether you are able to move your legends.
thanks
Badri


WF 7.6.11,
oracle 11g ,windows
PDF , excel, AHTML
 
Posts: 17 | Registered: February 12, 2013Report This Post
Member
posted Hide Post
Hi Badri,

I keep setting the HAXIS and VAXIS back to default values. When I switch between Design mode and Text Editor mode, HAXIS and VAXIS are changed to these high values.

Thank you for the suggestion on setLegendAutomatic(false). With this api and setLegendPosition(-1) - free floating, my legend moved!

Jim


WebFOCUS release 7.7.03
WinNT 6.0 64bit
 
Posts: 10 | Registered: December 23, 2010Report 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     [SOLVED] Compound doc, pie chart, legend, white space

Copyright © 1996-2020 Information Builders