|
6 | 6 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
7 | 7 |
|
8 | 8 | <!-- header --> |
9 | | - <!-- # include file="../../src.primitives/src.primitives.html"--> |
| 9 | + <!-- #include file="../../src.primitives/src.primitives.html"--> |
10 | 10 | <link href="../../min/primitives.latest.css?5100" media="screen" rel="stylesheet" type="text/css" /> |
11 | | - <script type="text/javascript" src="../../min/primitives.min.js?5100"></script> |
| 11 | + <!-- <script type="text/javascript" src="../../min/primitives.min.js?5100"></script> --> |
12 | 12 | <script type="text/javascript" src="common/helpers.js"></script> |
13 | 13 | <script type="text/javascript" src="../data/famdata.js"></script> |
14 | 14 |
|
|
25 | 25 | new primitives.helpers.controls.RadioBoxConfig("dataSet", defaultDataSetName, "Select Data Set", dataSetNames, primitives.helpers.controls.ValueType.String, onUpdate) |
26 | 26 | ]) |
27 | 27 | ], { |
28 | | - /* Data Sets */ |
29 | | - dataSet: defaultDataSetName, |
30 | | - |
31 | | - /* Family Diagram Specific Options */ |
32 | | - neighboursSelectionMode: primitives.common.NeighboursSelectionMode.ParentsChildrenSiblingsAndSpouses, |
33 | | - groupByType: primitives.common.GroupByType.Children, |
34 | | - alignBylevels: "true", |
35 | | - hideGrandParentsConnectors: "false", |
36 | | - enableMatrixLayout: "false", |
37 | | - minimumMatrixSize: 2, |
38 | | - maximumColumnsInMatrix: 6, |
39 | | - |
40 | | - /* On-screen annotations specific options */ |
41 | | - AnnotationOptions: { |
42 | | - connectorPlacementType: primitives.common.ConnectorPlacementType.Offbeat, |
43 | | - connectorShapeType: primitives.common.ConnectorShapeType.OneWay, |
44 | | - labelPlacementType: primitives.common.ConnectorLabelPlacementType.Between, |
45 | | - lineWidth: 2, |
46 | | - lineType: primitives.common.LineType.Dashed, |
47 | | - color: primitives.common.Colors.Red, |
48 | | - offset: 5, |
49 | | - zOrderType: primitives.common.ZOrderType.Auto |
50 | | - }, |
51 | | - /* Layout */ |
52 | | - pageFitMode: primitives.common.PageFitMode.FitToPage, |
53 | | - orientationType: primitives.common.OrientationType.Top, |
54 | | - verticalAlignment: primitives.common.VerticalAlignmentType.Middle, |
55 | | - horizontalAlignment: primitives.common.HorizontalAlignmentType.Center, |
56 | | - childrenPlacementType: primitives.common.ChildrenPlacementType.Horizontal, |
57 | | - leavesPlacementType: primitives.common.ChildrenPlacementType.Horizontal, |
58 | | - maximumColumnsInMatrix: 6, |
59 | | - minimalVisibility: primitives.common.Visibility.Dot, |
60 | | - selectionPathMode: primitives.common.SelectionPathMode.None, |
61 | | - |
62 | | - hasButtons: primitives.common.Enabled.Auto, |
63 | | - hasSelectorCheckbox: primitives.common.Enabled.True, |
64 | | - selectCheckBoxLabel: "Selected", |
65 | | - itemTitleFirstFontColor: primitives.common.Colors.White, |
66 | | - itemTitleSecondFontColor: primitives.common.Colors.White, |
67 | | - buttonsPanelSize: 28, |
68 | | - groupTitlePanelSize: 24, |
69 | | - checkBoxPanelSize: 24, |
70 | | - |
71 | | - /* group title options */ |
72 | | - groupTitlePlacementType: primitives.common.AdviserPlacementType.Left, |
73 | | - groupTitleOrientation: primitives.text.TextOrientationType.RotateRight, |
74 | | - groupTitleVerticalAlignment: primitives.common.VerticalAlignmentType.Middle, |
75 | | - groupTitleHorizontalAlignment: primitives.common.HorizontalAlignmentType.Center, |
76 | | - groupTitleFontSize: "12px", |
77 | | - groupTitleFontFamily: "Arial", |
78 | | - groupTitleColor: primitives.common.Colors.RoyalBlue, |
79 | | - groupTitleFontWeight: "normal", |
80 | | - groupTitleFontStyle: "normal", |
81 | | - |
82 | | - /* Template */ |
83 | | - DefaultTemplateOptions: { |
84 | | - minimizedItemCornerRadius: 12, |
85 | | - minimizedItemSize: new primitives.common.Size(16, 16), |
86 | | - highlightPadding: 4, |
87 | | - minimizedItemShapeType: primitives.common.ShapeType.None, |
88 | | - minimizedItemLineWidth: 1, |
89 | | - minimizedItemLineType: primitives.common.LineType.Solid, |
90 | | - minimizedItemBorderColor: null, |
91 | | - minimizedItemFillColor: null, |
92 | | - minimizedItemOpacity: 1.0 |
93 | | - }, |
94 | | - |
95 | | - /* Intervals */ |
96 | | - normalLevelShift: 20, |
97 | | - dotLevelShift: 20, |
98 | | - lineLevelShift: 20, |
99 | | - |
100 | | - normalItemsInterval: 20, |
101 | | - dotItemsInterval: 10, |
102 | | - lineItemsInterval: 10, |
103 | | - |
104 | | - cousinsIntervalMultiplier: 0, |
105 | | - |
106 | | - /* Connectors */ |
107 | | - arrowsDirection: primitives.common.GroupByType.Parents, |
108 | | - showExtraArrows: true, |
109 | | - extraArrowsMinimumSpace: 30, |
110 | | - connectorType: primitives.common.ConnectorType.Squared, |
111 | | - elbowType: primitives.common.ElbowType.Round, |
112 | | - bevelSize: 4, |
113 | | - elbowDotSize: 4, |
114 | | - linesType: primitives.common.LineType.Solid, |
115 | | - linesColor: primitives.common.Colors.Black, |
116 | | - linesWidth: 1, |
117 | | - |
118 | | - /* Labels */ |
119 | | - showLabels: primitives.common.Enabled.Auto, |
120 | | - labelSize: new primitives.common.Size(60, 40), |
121 | | - labelOrientation: primitives.text.TextOrientationType.Horizontal, |
122 | | - labelPlacement: primitives.common.PlacementType.Top, |
123 | | - labelOffset: 1, |
124 | | - labelFontSize: "10px", |
125 | | - labelFontFamily: "Arial", |
126 | | - labelColor: primitives.common.Colors.Black, |
127 | | - labelFontWeight: "normal", |
128 | | - labelFontStyle: "normal", |
129 | | - |
130 | | - /* Callout */ |
131 | | - calloutMaximumVisibility: primitives.common.Visibility.Dot, |
132 | | - showCallout: "true", |
133 | | - calloutPlacementOffset: 100, |
134 | | - calloutfillColor: "#000000", |
135 | | - calloutBorderColor: null, |
136 | | - calloutOffset: 4, |
137 | | - calloutCornerRadius: 4, |
138 | | - calloutPointerWidth: "10%", |
139 | | - calloutLineWidth: 1, |
140 | | - calloutOpacity: 0.2, |
141 | | - |
142 | | - /* Interactivity */ |
143 | | - navigationMode: primitives.common.NavigationMode.Default, |
144 | | - highlightGravityRadius: 40, |
145 | | - enablePanning: true, |
146 | | - |
147 | | - /* Graphics */ |
148 | | - graphicsType: primitives.common.GraphicsType.SVG, |
149 | | - |
150 | | - scale: 1.0 |
| 28 | + /* Data Sets */ |
| 29 | + dataSet: defaultDataSetName, |
| 30 | + |
| 31 | + /* Family Diagram Specific Options */ |
| 32 | + neighboursSelectionMode: primitives.common.NeighboursSelectionMode.ParentsChildrenSiblingsAndSpouses, |
| 33 | + groupByType: primitives.common.GroupByType.Children, |
| 34 | + alignBylevels: "true", |
| 35 | + hideGrandParentsConnectors: "false", |
| 36 | + enableMatrixLayout: "false", |
| 37 | + minimumMatrixSize: 2, |
| 38 | + maximumColumnsInMatrix: 6, |
| 39 | + |
| 40 | + /* On-screen annotations specific options */ |
| 41 | + AnnotationOptions: { |
| 42 | + connectorPlacementType: primitives.common.ConnectorPlacementType.Offbeat, |
| 43 | + connectorShapeType: primitives.common.ConnectorShapeType.OneWay, |
| 44 | + labelPlacementType: primitives.common.ConnectorLabelPlacementType.Between, |
| 45 | + lineWidth: 2, |
| 46 | + lineType: primitives.common.LineType.Dashed, |
| 47 | + color: primitives.common.Colors.Red, |
| 48 | + offset: 5, |
| 49 | + zOrderType: primitives.common.ZOrderType.Auto |
151 | 50 | }, |
| 51 | + /* Layout */ |
| 52 | + pageFitMode: primitives.common.PageFitMode.FitToPage, |
| 53 | + orientationType: primitives.common.OrientationType.Top, |
| 54 | + verticalAlignment: primitives.common.VerticalAlignmentType.Middle, |
| 55 | + horizontalAlignment: primitives.common.HorizontalAlignmentType.Center, |
| 56 | + childrenPlacementType: primitives.common.ChildrenPlacementType.Horizontal, |
| 57 | + leavesPlacementType: primitives.common.ChildrenPlacementType.Horizontal, |
| 58 | + maximumColumnsInMatrix: 6, |
| 59 | + minimalVisibility: primitives.common.Visibility.Dot, |
| 60 | + selectionPathMode: primitives.common.SelectionPathMode.None, |
| 61 | + |
| 62 | + hasButtons: primitives.common.Enabled.Auto, |
| 63 | + hasSelectorCheckbox: primitives.common.Enabled.True, |
| 64 | + selectCheckBoxLabel: "Selected", |
| 65 | + itemTitleFirstFontColor: primitives.common.Colors.White, |
| 66 | + itemTitleSecondFontColor: primitives.common.Colors.White, |
| 67 | + buttonsPanelSize: 28, |
| 68 | + groupTitlePanelSize: 24, |
| 69 | + checkBoxPanelSize: 24, |
| 70 | + |
| 71 | + /* group title options */ |
| 72 | + groupTitlePlacementType: primitives.common.AdviserPlacementType.Left, |
| 73 | + groupTitleOrientation: primitives.text.TextOrientationType.RotateRight, |
| 74 | + groupTitleVerticalAlignment: primitives.common.VerticalAlignmentType.Middle, |
| 75 | + groupTitleHorizontalAlignment: primitives.common.HorizontalAlignmentType.Center, |
| 76 | + groupTitleFontSize: "12px", |
| 77 | + groupTitleFontFamily: "Arial", |
| 78 | + groupTitleColor: primitives.common.Colors.RoyalBlue, |
| 79 | + groupTitleFontWeight: "normal", |
| 80 | + groupTitleFontStyle: "normal", |
| 81 | + |
| 82 | + /* Template */ |
| 83 | + DefaultTemplateOptions: { |
| 84 | + minimizedItemCornerRadius: 12, |
| 85 | + minimizedItemSize: new primitives.common.Size(16, 16), |
| 86 | + highlightPadding: 4, |
| 87 | + minimizedItemShapeType: primitives.common.ShapeType.None, |
| 88 | + minimizedItemLineWidth: 1, |
| 89 | + minimizedItemLineType: primitives.common.LineType.Solid, |
| 90 | + minimizedItemBorderColor: null, |
| 91 | + minimizedItemFillColor: null, |
| 92 | + minimizedItemOpacity: 1.0 |
| 93 | + }, |
| 94 | + |
| 95 | + /* Intervals */ |
| 96 | + normalLevelShift: 20, |
| 97 | + dotLevelShift: 20, |
| 98 | + lineLevelShift: 20, |
| 99 | + |
| 100 | + normalItemsInterval: 20, |
| 101 | + dotItemsInterval: 10, |
| 102 | + lineItemsInterval: 10, |
| 103 | + |
| 104 | + cousinsIntervalMultiplier: 0, |
| 105 | + |
| 106 | + /* Connectors */ |
| 107 | + arrowsDirection: primitives.common.GroupByType.Parents, |
| 108 | + showExtraArrows: true, |
| 109 | + extraArrowsMinimumSpace: 30, |
| 110 | + connectorType: primitives.common.ConnectorType.Squared, |
| 111 | + elbowType: primitives.common.ElbowType.Round, |
| 112 | + bevelSize: 4, |
| 113 | + elbowDotSize: 4, |
| 114 | + linesType: primitives.common.LineType.Solid, |
| 115 | + linesColor: primitives.common.Colors.Black, |
| 116 | + linesWidth: 1, |
| 117 | + |
| 118 | + /* Labels */ |
| 119 | + showLabels: primitives.common.Enabled.Auto, |
| 120 | + labelSize: new primitives.common.Size(60, 40), |
| 121 | + labelOrientation: primitives.text.TextOrientationType.Horizontal, |
| 122 | + labelPlacement: primitives.common.PlacementType.Top, |
| 123 | + labelOffset: 1, |
| 124 | + labelFontSize: "10px", |
| 125 | + labelFontFamily: "Arial", |
| 126 | + labelColor: primitives.common.Colors.Black, |
| 127 | + labelFontWeight: "normal", |
| 128 | + labelFontStyle: "normal", |
| 129 | + |
| 130 | + /* Callout */ |
| 131 | + calloutMaximumVisibility: primitives.common.Visibility.Dot, |
| 132 | + showCallout: "true", |
| 133 | + calloutPlacementOffset: 100, |
| 134 | + calloutfillColor: "#000000", |
| 135 | + calloutBorderColor: null, |
| 136 | + calloutOffset: 4, |
| 137 | + calloutCornerRadius: 4, |
| 138 | + calloutPointerWidth: "10%", |
| 139 | + calloutLineWidth: 1, |
| 140 | + calloutOpacity: 0.2, |
| 141 | + |
| 142 | + /* Interactivity */ |
| 143 | + navigationMode: primitives.common.NavigationMode.Default, |
| 144 | + highlightGravityRadius: 40, |
| 145 | + enablePanning: true, |
| 146 | + |
| 147 | + /* Graphics */ |
| 148 | + graphicsType: primitives.common.GraphicsType.SVG, |
| 149 | + |
| 150 | + scale: 1.0 |
| 151 | + }, |
152 | 152 | /* On property change event handler */ |
153 | 153 | onUpdate |
154 | 154 | ); |
|
322 | 322 | } |
323 | 323 |
|
324 | 324 | function updateHighlightPathAnnotations(data) { |
325 | | - var annotations = control.getOption("annotations"); |
| 325 | + var annotations = control.getOption("annotations") || []; |
326 | 326 |
|
327 | 327 | var newAnnotations = []; |
328 | 328 | for (var index = 0, len = annotations.length; index < len; index += 1) { |
|
0 commit comments