4D v16.3

Graph Parameters

Home

 
4D v16.3
Graph Parameters

Graph Parameters 

 

Constant  Type Value Comment
Graph background color  String graphBackgroundColor Possible values: SVG compliant color expression (text), for example "#7F8E00", "Pink", or "#0a1414"
Graph background opacity  String graphBackgroundOpacity Possible values: Integers, range 0-100
Default value: 100
Graph background shadow color  String graphBackgroundShadowColor Possible values: SVG compliant color expression (text), for example "#7F8E00", "Pink", or "#0a1414"
Graph bottom margin  String bottomMargin Possible values: Real numbers
Default value: 12
Graph colors  String colors Possible values: Text array. Colors for each graph series.
Default values: Blue-green (#19BAC9), Yellow (#FFC338), Purple (#573E82), Green (#4FA839), Orange (#D95700), Blue (#1D9DF2), Yellow-green (#B5CF32), Red (#D43A26)
Graph column gap  String columnGap Possible values: Longints
Default value: 12
Sets spacing between bars
Graph column width max  String columnWidthMax Possible values: Real numbers
Default value: 200
Graph column width min  String columnWidthMin Possible values: Real numbers
Default value: 10
Graph default height  String defaultHeight Possible values: Real numbers
Default value: 400. If graphType=7 (Pie), then default value = 600
Graph default width  String defaultWidth Possible values: Real numbers
Default value
: 600. If graphType=7 (Pie), then default value = 800
Graph display legend  String displayLegend Possible values: Boolean
Default value: True
Graph document background color  String documentBackgroundColor Possible values: SVG compliant color expression (text), for example "#7F8E00", "Pink", or "#0a1414". When a graph saved as an SVG picture is opened elsewhere, the document background color is only displayed if the SVG rendering engine supports the SVG tiny 1.2 norm (supported on IE, Firefox, but not on Chrome).
Graph document background opacity  String documentBackgroundOpacity Possible values: Integer, range 0-100 (default value: 100). When a graph saved as an SVG picture is opened elsewhere, the document background opacity is only displayed if the SVG rendering engine supports the SVG tiny 1.2 norm (supported on IE, Firefox, but not on Chrome).
Graph font color  String fontColor Possible values: SVG compliant color expression (text), for example "#7F8E00", "Pink", or "#0a1414"
Graph font size  String fontSize Possible values: Longints
Default value: 12. If graphType=7 (Pie), see Graph pie font size
Graph left margin  String leftMargin Possible values: Real numbers
Default value: 12
Graph legend font color  String legendFontColor Possible values: SVG compliant color expression (text), for example "#7F8E00", "Pink", or "#0a1414"
Graph legend icon gap  String legendIconGap Possible values: Real numbers
Default value: Graph legend icon height/2
Graph legend icon height  String legendIconHeight Possible values: Real numbers
Default value: 20
Graph legend icon width  String legendIconWidth Possible values: Real numbers
Default value: 20
Graph legend labels  String legendLabels Possible values: Text array. If missing, 4D displays icons without text.
Graph line width  String lineWidth Possible values: Real numbers
Default value: 2
Graph pie font size  String pieFontSize Possible values: Real numbers
Default value: 16
Graph pie shift  String pieShift Possible values: Real numbers
Default value: 8
Graph plot height  String plotHeight Possible values: Real numbers
Default value: 12
Graph plot radius  String plotRadius Possible values: Real numbers
Default value: 12
Graph plot width  String plotWidth Possible values: Real numbers
Default value: 12
Graph right margin  String rightMargin Possible values: Real numbers
Default value: 2
Graph top margin  String topMargin Possible values: Real numbers
Default value: 2
Graph type  String graphType Possible values: Longints [1 to 8] where 1 = bars, 2 = proportional, 3 = stacked, 4 = lines, 5 = surfaces, 6 = scatter, 7 =  pie, 8 = pictures.
Default value: 1
If null, the graph is not drawn and no error message is displayed. If out of range, the graph is not drawn and an error message is displayed.
If you want to modify picture type graphs (value=8), you must copy the 4D/Resources/GraphTemplates/Graph_8_Pictures/ folder into the Resources folder of your database and perform the necessary modifications. Local picture files will be used instead of 4D files. There is no pattern for picture names; 4D sorts the files contained in the folder and assigns the first file to the first graph. These files can be of the SVG or image type.
Graph xGrid  String xGrid Possible values: Boolean
Default value: True.
Used only with proportional types 4 and 6.
Graph xMax  String xMax Possible values: Number, Date, Time (same type as xLabels parameter).
Only values lower than xMax are displayed on the graph. xMax is used only for graph types 4, 5, or 6 if xProp=true and if xLabels type is a number, date, or time. If missing or if xMin>xMax, 4D automatically calculates the xMax value.
Graph xMin  String xMin Possible values: Number, Date, Time (same type as xLabels parameter).
Only values higher than xMin are displayed on the graph. xMin is used only for graph types 4, 5, or 6 if xProp=true and if xLabels type is a number, date, or time. If missing or if xMin>xMax, 4D automatically calculates the xMin value.
Graph xProp  String xProp Possible values: Boolean
Default value: False
True for proportional x-axis; False for normal x-axis. xProp is used only for graph types 4, 5, or 6
Graph yGrid  String yGrid Possible values: Boolean
Default value: True
Graph yMax  String yMax Possible values: Numbers
If missing, 4D automatically calculates the yMax value.
Graph yMin  String yMin Possible values: Numbers
If missing, 4D automatically calculates the yMin value.


See also 

GRAPH

 
PROPERTIES 

Product: 4D
Theme: List of constant themes

 
HISTORY 

Created: 4D v15 R4

 
ARTICLE USAGE

4D Language Reference ( 4D v16)
4D Language Reference ( 4D v16.1)
4D Language Reference ( 4D v16.2)
4D Language Reference ( 4D v16.3)