/3.1 (Extension.1 Name: "Legend Tool" Dependencies: "$AVBIN/avdlog.dll\n" FirstRootClassName: "Tool" Roots: 2 Roots: 4 Roots: 196 Roots: 197 Roots: 198 Roots: 199 Roots: 200 Roots: 201 Roots: 202 Roots: 203 Roots: 204 Roots: 205 Roots: 206 Version: 31 About: "Adds a tool for creating and setting advanced properties for legends to your layout document interface, This tool opens a wizard you use to set the properties for a legend. (v3.1)" CanUnloadScript: 207 UnloadScript: 208 InstallScript: 209 UninstallScript: 210 ExtVersion: 1 ) (Tool.2 InternalName: "MapTool" Help: "Custom Legend Tool//Click where you want the lower left origin of a multicolumn legend" Icon: 3 Cursor: "Cursors.Bullseye" Apply: "Legends.Show" ) (AVIcon.3 Name: "CartoLegend" Res: "Icons.CartoLegend" ) (AVDLog.4 Name: "Legends Multi-Column Legend" X: 7 Y: 222 W: 486 H: 316 HelpTopic: "Layout_Advanced_Legend_Tool" ConstrainedControlNames: 5 ConstrainedControlNames: 6 ConstrainedControlNames: 7 ConstrainedControlNames: 8 ConstrainedControlNames: 9 ConstrainedControlNames: 10 ConstrainedControlNames: 11 Constraints: 12 Constraints: 13 Constraints: 14 Constraints: 15 Constraints: 16 Constraints: 17 Constraints: 18 Server: 19 ControlPanel: 20 Title: "Custom Legend - Step 1 of 5: Basic Settings" EscapeEnabled: 1 AlwaysOnTop: 1 HasTitleBar: 1 Closeable: 1 Close: "Legends.Close" Open: "Legends.Open" DefaultButton: 195 ) (AVStr.5 S: "LFinish" ) (AVStr.6 S: "LNext" ) (AVStr.7 S: "LBack" ) (AVStr.8 S: "LCancel" ) (AVStr.9 S: "aLabelButton1" ) (AVStr.10 S: "AddThemes" ) (AVStr.11 S: "RemoveThemes" ) (Numb.12 N: 85.00000000000000 ) (Numb.13 N: 85.00000000000000 ) (Numb.14 N: 85.00000000000000 ) (Numb.15 N: 85.00000000000000 ) (Numb.16 N: 85.00000000000000 ) (Numb.17 N: 85.00000000000000 ) (Numb.18 N: 85.00000000000000 ) (Nil.19 ) (CPanel.20 Child: 21 Child: 25 Child: 47 Child: 66 Child: 118 Child: 151 Child: 152 Child: 153 Child: 154 Child: 174 Child: 175 Child: 182 ResBox: 183 ResBox: 184 ResBox: 185 ResBox: 186 ResBox: 187 ResBox: 188 ResBox: 189 ResBox: 190 ResBox: 191 ResBox: 192 ResBox: 193 ResBox: 194 Listening: 1 ) (CPanel.21 InternalName: "aControlPanel2" Child: 22 Constraints: 0x55 ResBox: 24 VisibleBorder: 1 Listening: 1 ) (AVIBox.22 InternalName: "aIconBox1" Constraints: 0x55 Icon: 23 Listening: 1 ) (AVIcon.23 Name: "CartoLegend" Res: "Icons.CartoLegend" ) (RectD.24 Left: 6.00000000000000 Top: 266.00000000000000 Right: 163.00000000000000 Bottom: 7.00000000000000 ) (CPanel.25 InternalName: "ThemePanel" Child: 26 Child: 28 Child: 30 Child: 31 Child: 32 Child: 33 Child: 35 Child: 37 Constraints: 0x55 ResBox: 39 ResBox: 40 ResBox: 41 ResBox: 42 ResBox: 43 ResBox: 44 ResBox: 45 ResBox: 46 VisibleBorder: 1 Listening: 1 ) (AVCBBox.26 InternalName: "Vname" Help: "Choose a view from the list of views in your project to create a legend from" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Choose a view:" Select: "Legends.Change View" ) (Nil.27 ) (AVLBox.28 InternalName: "ThemeList" Help: "Available Themes//Choose the themes to add to your legend" NextControl: 27 ContentKind: 4 Constraints: 0x55 ColumnCount: 1 HorizontalScroll: 1 Listening: 1 VerticalScroll: 1 Select: "Legends.Theme List Update" SelectionStyle: 29 ) (AVEnum.29 Name: "LISTBOX_SELECTION_MULTIRANGE" ) (TextLabel.30 InternalName: "aTextLabel4" Constraints: 0x55 Label: "Choose the themes to show \nin your custom legend:" Listening: 1 ) (AVCBBox.31 InternalName: "NumCols" Help: "This is the number of columns that ArcView will try to use when creating your legend" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 ) (TextLabel.32 InternalName: "aTextLabel301" Constraints: 0x55 Label: "Choose the number of\nlabel and symbol columns\nto display your legend:" Listening: 1 ) (AVLBox.33 InternalName: "LegThemes" Help: "Legend Themes//This is the list of themes that will go into your legend" NextControl: 27 ContentKind: 4 Constraints: 0x55 ColumnCount: 1 HorizontalScroll: 1 Listening: 1 VerticalScroll: 1 Select: "Legends.Theme List Update" SelectionStyle: 34 ) (AVEnum.34 Name: "LISTBOX_SELECTION_MULTIRANGE" ) (Butn.35 InternalName: "AddThemes" Help: "Add to Legend//Once you select one or more themes on the left, click this to move them to the list on the right" Icon: 36 Click: "Legends.AddDrop Themes" ) (AVIcon.36 Name: "ShiftRight" Res: "Icons.ShiftRight" ) (Butn.37 InternalName: "RemoveThemes" Help: "Remove from Legend//Removes the selected themes on the right from the legend" Icon: 38 Click: "Legends.AddDrop Themes" ) (AVIcon.38 Name: "ShiftLeft" Res: "Icons.ShiftLeft" ) (RectD.39 Left: 11.00000000000000 Top: 125.00000000000000 Right: 286.00000000000000 Bottom: 18.00000000000000 ) (RectD.40 Left: 11.00000000000000 Top: 174.00000000000000 Right: 129.00000000000000 Bottom: 78.00000000000000 ) (RectD.41 Left: 14.00000000000000 Top: 78.00000000000000 Right: 299.00000000000000 Bottom: 41.00000000000000 ) (RectD.42 Left: 171.00000000000000 Top: 306.00000000000000 Right: 300.00000000000000 Bottom: 192.00000000000000 ) (RectD.43 Left: 11.00000000000000 Top: 247.00000000000000 Right: 178.00000000000000 Bottom: 192.00000000000000 ) (RectD.44 Left: 175.00000000000000 Top: 174.00000000000000 Right: 291.00000000000000 Bottom: 78.00000000000000 ) (RectD.45 Left: 139.00000000000000 Top: 113.00000000000000 Right: 163.00000000000000 Bottom: 89.00000000000000 ) (RectD.46 Left: 139.00000000000000 Top: 151.00000000000000 Right: 163.00000000000000 Bottom: 127.00000000000000 ) (CPanel.47 InternalName: "SymbolPanel" Child: 48 Child: 55 Child: 62 Constraints: 0x55 ResBox: 63 ResBox: 64 ResBox: 65 VisibleBorder: 1 Listening: 1 ) (CPanel.48 InternalName: "aControlPanel10" Child: 49 Child: 50 Child: 51 Constraints: 0x55 ResBox: 52 ResBox: 53 ResBox: 54 Label: "Show area symbols as:" VisibleBorder: 1 Listening: 1 ) (RButn.49 InternalName: "PolysAsRects" Help: "Display your fill symbols as rectangles" Constraints: 0x55 Listening: 1 Label: "Rectangles" ) (RButn.50 InternalName: "PolysAsSquares" Help: "Display your fill symbols as squares" Constraints: 0x55 Listening: 1 Label: "Squares" ) (RButn.51 InternalName: "PolysAsOvals" Help: "Display your fill symbols as ovals" Constraints: 0x55 Listening: 1 Label: "Ovals" ) (RectD.52 Left: 10.00000000000000 Top: 46.00000000000000 Right: 135.00000000000000 Bottom: 25.00000000000000 ) (RectD.53 Left: 10.00000000000000 Top: 66.00000000000000 Right: 135.00000000000000 Bottom: 46.00000000000000 ) (RectD.54 Left: 10.00000000000000 Top: 88.00000000000000 Right: 135.00000000000000 Bottom: 66.00000000000000 ) (CPanel.55 InternalName: "aControlPanel11" Child: 56 Child: 57 Child: 58 Constraints: 0x55 ResBox: 59 ResBox: 60 ResBox: 61 Label: "Show line symbols as:" VisibleBorder: 1 Listening: 1 ) (RButn.56 InternalName: "LinesAsHorz" Help: "Display your line symbols as horizontal lines" Constraints: 0x55 Listening: 1 Label: "Horizontal lines" ) (RButn.57 InternalName: "LinesAsZigZag" Help: "Display your line symbols as zig zag lines" Constraints: 0x55 Listening: 1 Label: "Zig zag lines" ) (RButn.58 InternalName: "LinesAsEsses" Help: "Display your line symbols as S curves" Constraints: 0x55 Listening: 1 Label: "'S' curves" ) (RectD.59 Left: 8.00000000000000 Top: 45.00000000000000 Right: 133.00000000000000 Bottom: 24.00000000000000 ) (RectD.60 Left: 8.00000000000000 Top: 67.00000000000000 Right: 133.00000000000000 Bottom: 45.00000000000000 ) (RectD.61 Left: 8.00000000000000 Top: 88.00000000000000 Right: 133.00000000000000 Bottom: 67.00000000000000 ) (TextLabel.62 InternalName: "aTextLabel21" Constraints: 0x55 Label: "Choose the shapes to represent your legend's \nsymbols with:" Listening: 1 ) (RectD.63 Left: 64.00000000000000 Top: 143.00000000000000 Right: 232.00000000000000 Bottom: 47.00000000000000 ) (RectD.64 Left: 64.00000000000000 Top: 241.00000000000000 Right: 232.00000000000000 Bottom: 145.00000000000000 ) (RectD.65 Left: 21.00000000000000 Top: 49.00000000000000 Right: 261.00000000000000 Bottom: 15.00000000000000 ) (CPanel.66 InternalName: "SpacingPanel" Child: 67 Child: 69 Child: 71 Child: 73 Child: 74 Child: 75 Child: 76 Child: 78 Child: 79 Child: 81 Child: 82 Child: 83 Child: 85 Child: 86 Child: 87 Child: 88 Child: 89 Child: 90 Child: 91 Child: 92 Child: 94 Child: 95 Constraints: 0x55 ResBox: 96 ResBox: 97 ResBox: 98 ResBox: 99 ResBox: 100 ResBox: 101 ResBox: 102 ResBox: 103 ResBox: 104 ResBox: 105 ResBox: 106 ResBox: 107 ResBox: 108 ResBox: 109 ResBox: 110 ResBox: 111 ResBox: 112 ResBox: 113 ResBox: 114 ResBox: 115 ResBox: 116 ResBox: 117 VisibleBorder: 1 Listening: 1 ) (TextLine.67 InternalName: "XTitleLegend" Help: "Enter the distance between the title and the other elements of the legend" Text: "0.4" Constraints: 0x55 Listening: 1 TextType: 68 NextControl: 27 ) (AVEnum.68 Name: "TEXTLINE_TYPE_REAL" ) (TextLine.69 InternalName: "XColumns" Help: "Enter the distance between each column of symbols and labels" Text: "0.25" Constraints: 0x55 Listening: 1 TextType: 70 NextControl: 27 ) (AVEnum.70 Name: "TEXTLINE_TYPE_REAL" ) (TextLine.71 InternalName: "XThemeSyms" Help: "Enter the amount of space (vertically) between a themes title and its symbols and labels" Text: "0.125" Constraints: 0x55 Listening: 1 TextType: 72 NextControl: 27 ) (AVEnum.72 Name: "TEXTLINE_TYPE_REAL" ) (TextLabel.73 InternalName: "aTextLabel28" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLabel.74 InternalName: "aTextLabel29" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLabel.75 InternalName: "aTextLabel30" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLine.76 InternalName: "XSymsLabels" Help: "Enter the amount of space (horizontal) between symbls and their labels" Text: "0.25" Constraints: 0x55 Listening: 1 TextType: 77 NextControl: 27 ) (AVEnum.77 Name: "TEXTLINE_TYPE_REAL" ) (TextLabel.78 InternalName: "aTextLabel13" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLine.79 InternalName: "XSymRows" Help: "Enter the amount of space (vertical) that will be placed between rows of symbols and labels" Text: "0.05" Constraints: 0x55 Listening: 1 TextType: 80 NextControl: 27 ) (AVEnum.80 Name: "TEXTLINE_TYPE_REAL" ) (TextLabel.81 InternalName: "aTextLabel15" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLabel.82 InternalName: "aTextLabel16" Constraints: 0x55 Label: "Enter the amount of space to be placed\nbetween the elements of your legend." Listening: 1 ) (TextLine.83 InternalName: "XThemes" Help: "Enter the amount of space to occur between themes (vertically)" Text: "0.05" Constraints: 0x55 Listening: 1 TextType: 84 NextControl: 27 ) (AVEnum.84 Name: "TEXTLINE_TYPE_REAL" ) (TextLabel.85 InternalName: "aTextLabel19" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLabel.86 InternalName: "aTextLabel20" Constraints: 0x55 Label: "Title and legend:" Listening: 1 ) (TextLabel.87 InternalName: "aTextLabel213" Constraints: 0x55 Label: "Columns:" Listening: 1 ) (TextLabel.88 InternalName: "aTextLabel22" Constraints: 0x55 Label: "Themes:" Listening: 1 ) (TextLabel.89 InternalName: "aTextLabel23" Constraints: 0x55 Label: "Theme names \nand symbols:" Listening: 1 ) (TextLabel.90 InternalName: "aTextLabel277" Constraints: 0x55 Label: "Symbols and labels:" Listening: 1 ) (TextLabel.91 InternalName: "aTextLabel25" Constraints: 0x55 Label: "Rows of symbols:" Listening: 1 ) (TextLine.92 InternalName: "XSymWidth" Help: "Enter the length of line symbols" Text: "0.4" Constraints: 0x55 Listening: 1 TextType: 93 NextControl: 27 ) (AVEnum.93 Name: "TEXTLINE_TYPE_REAL" ) (TextLabel.94 InternalName: "aTextLabel308" Constraints: 0x55 Label: "inches" Listening: 1 ) (TextLabel.95 InternalName: "aTextLabel454" Constraints: 0x55 Label: "Length of line symbols:" Listening: 1 ) (RectD.96 Left: 165.00000000000000 Top: 85.00000000000000 Right: 237.00000000000000 Bottom: 65.00000000000000 ) (RectD.97 Left: 165.00000000000000 Top: 110.00000000000000 Right: 237.00000000000000 Bottom: 90.00000000000000 ) (RectD.98 Left: 165.00000000000000 Top: 159.00000000000000 Right: 237.00000000000000 Bottom: 139.00000000000000 ) (RectD.99 Left: 242.00000000000000 Top: 87.00000000000000 Right: 300.00000000000000 Bottom: 67.00000000000000 ) (RectD.100 Left: 242.00000000000000 Top: 109.00000000000000 Right: 300.00000000000000 Bottom: 91.00000000000000 ) (RectD.101 Left: 242.00000000000000 Top: 133.00000000000000 Right: 300.00000000000000 Bottom: 117.00000000000000 ) (RectD.102 Left: 165.00000000000000 Top: 190.00000000000000 Right: 237.00000000000000 Bottom: 170.00000000000000 ) (RectD.103 Left: 242.00000000000000 Top: 158.00000000000000 Right: 300.00000000000000 Bottom: 142.00000000000000 ) (RectD.104 Left: 165.00000000000000 Top: 215.00000000000000 Right: 237.00000000000000 Bottom: 195.00000000000000 ) (RectD.105 Left: 242.00000000000000 Top: 191.00000000000000 Right: 300.00000000000000 Bottom: 175.00000000000000 ) (RectD.106 Left: 15.00000000000000 Top: 55.00000000000000 Right: 280.00000000000000 Bottom: 17.00000000000000 ) (RectD.107 Left: 165.00000000000000 Top: 134.00000000000000 Right: 237.00000000000000 Bottom: 114.00000000000000 ) (RectD.108 Left: 242.00000000000000 Top: 214.00000000000000 Right: 300.00000000000000 Bottom: 198.00000000000000 ) (RectD.109 Left: 14.00000000000000 Top: 88.00000000000000 Right: 168.00000000000000 Bottom: 69.00000000000000 ) (RectD.110 Left: 14.00000000000000 Top: 112.00000000000000 Right: 168.00000000000000 Bottom: 93.00000000000000 ) (RectD.111 Left: 14.00000000000000 Top: 138.00000000000000 Right: 168.00000000000000 Bottom: 119.00000000000000 ) (RectD.112 Left: 14.00000000000000 Top: 175.00000000000000 Right: 168.00000000000000 Bottom: 140.00000000000000 ) (RectD.113 Left: 14.00000000000000 Top: 194.00000000000000 Right: 168.00000000000000 Bottom: 175.00000000000000 ) (RectD.114 Left: 14.00000000000000 Top: 218.00000000000000 Right: 168.00000000000000 Bottom: 199.00000000000000 ) (RectD.115 Left: 165.00000000000000 Top: 239.00000000000000 Right: 237.00000000000000 Bottom: 219.00000000000000 ) (RectD.116 Left: 242.00000000000000 Top: 237.00000000000000 Right: 300.00000000000000 Bottom: 221.00000000000000 ) (RectD.117 Left: 14.00000000000000 Top: 241.00000000000000 Right: 171.00000000000000 Bottom: 222.00000000000000 ) (CPanel.118 InternalName: "TitlePanel" Child: 119 Child: 121 Child: 122 Child: 123 Child: 124 Child: 125 Child: 126 Child: 127 Child: 128 Child: 129 Child: 130 Child: 131 Child: 132 Child: 133 Child: 135 Constraints: 0x55 ResBox: 136 ResBox: 137 ResBox: 138 ResBox: 139 ResBox: 140 ResBox: 141 ResBox: 142 ResBox: 143 ResBox: 144 ResBox: 145 ResBox: 146 ResBox: 147 ResBox: 148 ResBox: 149 ResBox: 150 VisibleBorder: 1 Listening: 1 ) (TextLine.119 InternalName: "LegTitle" Help: "Enter text for a title (optional)" Constraints: 0x55 Listening: 1 TextType: 120 Empty: "Legends.Title Update" Changed: "Legends.Title Update" NextControl: 27 ) (AVEnum.120 Name: "TEXTLINE_TYPE_ALL" ) (AVCBBox.121 InternalName: "TitleFont" Help: "Choose a font for your title" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Title font:" Select: "Legends.Change Title Font" ) (AVCBBox.122 InternalName: "TitleSize" Help: "Choose the size for your title" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Title size (pts):" ) (AVCBBox.123 InternalName: "TitleStyle" Help: "Choose the style for your title" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Title style:" ) (TextLabel.124 InternalName: "aTextLabel5" Constraints: 0x55 Label: "Enter an optional title for your legend:" Listening: 1 ) (RButn.125 InternalName: "LL" Help: "Positions the title at the bottom of the legend, aligning it with the left edge of the legend" Constraints: 0x55 Listening: 1 ) (RButn.126 InternalName: "RC" Help: "Positions the title to the right of the legend, vertically centering it" Constraints: 0x55 Listening: 1 ) (TextLabel.127 InternalName: "TitleJustLab" Constraints: 0x55 Label: "Title positioning options:" Listening: 1 ) (RButn.128 InternalName: "UR" Help: "Positions the title at the top of the legend, aligning it with the right edge of the legend" Constraints: 0x55 Listening: 1 ) (RButn.129 InternalName: "UC" Help: "Positions the title at the top of the legend, horizontally centering it" Constraints: 0x55 Listening: 1 ) (RButn.130 InternalName: "CL" Help: "Positions the title at the bottom of the legend, horizontally centering it" Constraints: 0x55 Listening: 1 ) (RButn.131 InternalName: "LC" Help: "Positions the title to the left of the legend, vertically centering it" Constraints: 0x55 Listening: 1 ) (RButn.132 InternalName: "UL" Help: "Positions the title at the top of the legend, aligning it with the left edge of the legend" Constraints: 0x55 Listening: 1 ) (AVIBox.133 InternalName: "aIconBox30" Constraints: 0x55 Icon: 134 Listening: 1 ) (AVIcon.134 Name: "grat.bmp" Data: 4e442049 6d616765 00010014 00110000 Data: 01541213 12131213 12131213 12131213 Data: 12131213 12131300 00000000 00000000 Data: 00000000 00000000 00131300 00131213 Data: 12131300 12131213 12131300 00131300 Data: 13001313 13131300 13131313 13130013 Data: 00131200 12001213 12131200 12131213 Data: 12130013 00131300 13130013 00000000 Data: 00000000 13001313 00131200 12000000 Data: 12131200 12131213 00000013 00131300 Data: 00131300 13131300 13131313 00131300 Data: 00131200 12131200 12131200 12131213 Data: 00131213 00131300 13131313 00131300 Data: 13131300 13131313 00131300 00131213 Data: 00130000 00001200 12131300 00131300 Data: 13001300 00001300 13130000 00130013 Data: 00131200 12000013 12001200 12130013 Data: 12000013 00131300 00131300 13130000 Data: 13001313 00131300 00131200 12131213 Data: 00130000 12001200 12131213 00131300 Data: 00000000 00000000 00000000 00000000 Data: 00131213 12131213 12131213 12131213 Data: 12131213 12130000 04000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 80008080 0000c0c0 c000c0dc c000f0ca Data: a600f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000000 00000000 Data: 80000080 00000080 80008000 00008000 Data: 8000f0fb ff00a4a0 a0008080 80000000 Data: ff0000ff 000000ff ff00ff00 0000ff00 Data: ff00ffff 0000ffff ff000002 00080007 Data: 00200001 00020000 00000000 0000 ) (RButn.135 InternalName: "RL" Help: "Positions the title at the bottom of the legend, aligning it with the right edge of the legend" Constraints: 0x55 Listening: 1 ) (RectD.136 Left: 8.00000000000000 Top: 58.00000000000000 Right: 282.00000000000000 Bottom: 38.00000000000000 ) (RectD.137 Left: 15.00000000000000 Top: 171.00000000000000 Right: 284.00000000000000 Bottom: 75.00000000000000 ) (RectD.138 Left: 15.00000000000000 Top: 193.00000000000000 Right: 284.00000000000000 Bottom: 97.00000000000000 ) (RectD.139 Left: 15.00000000000000 Top: 215.00000000000000 Right: 284.00000000000000 Bottom: 119.00000000000000 ) (RectD.140 Left: 14.00000000000000 Top: 39.00000000000000 Right: 285.00000000000000 Bottom: 19.00000000000000 ) (RectD.141 Left: 191.00000000000000 Top: 236.00000000000000 Right: 210.00000000000000 Bottom: 219.00000000000000 ) (RectD.142 Left: 259.00000000000000 Top: 201.00000000000000 Right: 278.00000000000000 Bottom: 184.00000000000000 ) (RectD.143 Left: 15.00000000000000 Top: 165.00000000000000 Right: 185.00000000000000 Bottom: 147.00000000000000 ) (RectD.144 Left: 239.00000000000000 Top: 168.00000000000000 Right: 258.00000000000000 Bottom: 151.00000000000000 ) (RectD.145 Left: 215.00000000000000 Top: 168.00000000000000 Right: 234.00000000000000 Bottom: 151.00000000000000 ) (RectD.146 Left: 215.00000000000000 Top: 236.00000000000000 Right: 234.00000000000000 Bottom: 219.00000000000000 ) (RectD.147 Left: 171.00000000000000 Top: 201.00000000000000 Right: 191.00000000000000 Bottom: 184.00000000000000 ) (RectD.148 Left: 191.00000000000000 Top: 168.00000000000000 Right: 210.00000000000000 Bottom: 151.00000000000000 ) (RectD.149 Left: 190.00000000000000 Top: 218.00000000000000 Right: 254.00000000000000 Bottom: 167.00000000000000 ) (RectD.150 Left: 239.00000000000000 Top: 236.00000000000000 Right: 258.00000000000000 Bottom: 219.00000000000000 ) (LButn.151 InternalName: "LFinish" Help: "Accept this legend and close the Custom Legend Wizard" Label: "Finish" Click: "Legends.Create" ) (LButn.152 InternalName: "LNext" Help: "Show the next panel of the Custom Legend Wizard" Label: "Next >>" Click: "Legends.Update Panel" ) (LButn.153 InternalName: "LBack" Help: "Show the previous panel of the Custom Legend Wizard" Label: "<< Back" Click: "Legends.Update Panel" ) (CPanel.154 InternalName: "BorderPanel" Child: 155 Child: 156 Child: 157 Child: 158 Child: 159 Child: 164 Child: 165 Constraints: 0x55 ResBox: 167 ResBox: 168 ResBox: 169 ResBox: 170 ResBox: 171 ResBox: 172 ResBox: 173 VisibleBorder: 1 Listening: 1 ) (TextLabel.155 InternalName: "aTextLabel166" Constraints: 0x55 Label: "Choose settings for your legend's border:" Listening: 1 ) (AVCBBox.156 InternalName: "BorderWidth" Help: "Choose a width for your border" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Border width:" ) (AVCBBox.157 InternalName: "BorderOLColor" Help: "Choose a color for your border line" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Border color:" ) (AVCBBox.158 InternalName: "BorderBGColor" Help: "Choose a fill color for your border" NextControl: 27 ContentKind: 4 Constraints: 0x55 Listening: 1 Label: "Background color:" ) (CPanel.159 InternalName: "aControlPanel3" Child: 160 Child: 161 Constraints: 0x55 ResBox: 162 ResBox: 163 Label: "Special Effects:" VisibleBorder: 1 Listening: 1 ) (AVCBox.160 InternalName: "UseDropShadow" Help: "Add a drop-shadow behind your legend" Listening: 1 Label: "Drop-shadow" Constraints: 0x55 ) (AVCBox.161 InternalName: "RoundCorners" Help: "Round the corners of your legend's border" Listening: 1 Label: "Round corners" Constraints: 0x55 ) (RectD.162 Left: 15.00000000000000 Top: 38.00000000000000 Right: 148.00000000000000 Bottom: 20.00000000000000 ) (RectD.163 Left: 146.00000000000000 Top: 38.00000000000000 Right: 267.00000000000000 Bottom: 20.00000000000000 ) (TextLabel.164 InternalName: "blah" Constraints: 0x55 Label: "Border\nstyle:" Listening: 1 ) (AVLBox.165 InternalName: "BorderStyle" Help: "Choose a border style" NextControl: 27 ContentKind: 4 Constraints: 0x55 ColumnCount: 1 Listening: 1 VerticalScroll: 1 SelectionStyle: 166 ) (AVEnum.166 Name: "LISTBOX_SELECTION_SINGLECELL" ) (RectD.167 Left: 12.00000000000000 Top: 29.00000000000000 Right: 300.00000000000000 Bottom: 9.00000000000000 ) (RectD.168 Left: 32.00000000000000 Top: 233.00000000000000 Right: 272.00000000000000 Bottom: 122.00000000000000 ) (RectD.169 Left: 32.00000000000000 Top: 266.00000000000000 Right: 272.00000000000000 Bottom: 144.00000000000000 ) (RectD.170 Left: 32.00000000000000 Top: 283.00000000000000 Right: 272.00000000000000 Bottom: 164.00000000000000 ) (RectD.171 Left: 16.00000000000000 Top: 244.00000000000000 Right: 284.00000000000000 Bottom: 194.00000000000000 ) (RectD.172 Left: 32.00000000000000 Top: 73.00000000000000 Right: 95.00000000000000 Bottom: 41.00000000000000 ) (RectD.173 Left: 97.00000000000000 Top: 116.00000000000000 Right: 272.00000000000000 Bottom: 38.00000000000000 ) (LButn.174 InternalName: "LCancel" Help: "Close the Custom Legend Wizard with out adding a legend" Label: "Cancel" Click: "Legends.Update Panel" ) (CPanel.175 InternalName: "IntroPanel" Child: 176 Child: 177 Child: 178 Constraints: 0x55 ResBox: 179 ResBox: 180 ResBox: 181 VisibleBorder: 1 Listening: 1 ) (TextLabel.176 InternalName: "aTextLabel193" Constraints: 0x55 Label: "The Custom Legend wizard helps you \ncreate a graphical legend in your layout.\nYou can create a legend for any view in \nyour project, choose which themes will be\nshown, the number of columns to display, \nand various other custom settings." Listening: 1 ) (TextLabel.177 InternalName: "aTextLabel293" Constraints: 0x55 Label: "Click Next to proceed." Listening: 1 ) (TextLabel.178 InternalName: "aTextLabel1" Constraints: 0x55 Label: "You can click Preview at any time to see \nhow the settings you have chosen affect \nthe appearance of your legend. " Listening: 1 ) (RectD.179 Left: 8.00000000000000 Top: 133.00000000000000 Right: 292.00000000000000 Bottom: 9.00000000000000 ) (RectD.180 Left: 8.00000000000000 Top: 245.00000000000000 Right: 220.00000000000000 Bottom: 225.00000000000000 ) (RectD.181 Left: 7.00000000000000 Top: 216.00000000000000 Right: 299.00000000000000 Bottom: 138.00000000000000 ) (LButn.182 InternalName: "aLabelButton1" Label: "Help..." Click: "Legends.Help" ) (RectD.183 Left: 8.00000000000000 Top: 279.00000000000000 Right: 480.00000000000000 Bottom: 9.00000000000000 ) (RectD.184 Left: 803.00000000000000 Top: 278.00000000000000 Right: 1109.00000000000000 Bottom: 25.00000000000000 ) (RectD.185 Left: 314.00000000000000 Top: 590.00000000000000 Right: 620.00000000000000 Bottom: 336.00000000000000 ) (RectD.186 Top: 592.00000000000000 Right: 306.00000000000000 Bottom: 338.00000000000000 ) (RectD.187 Left: 492.00000000000000 Top: 277.00000000000000 Right: 798.00000000000000 Bottom: 24.00000000000000 ) (RectD.188 Left: 398.00000000000000 Top: 309.00000000000000 Right: 480.00000000000000 Bottom: 285.00000000000000 ) (RectD.189 Left: 312.00000000000000 Top: 309.00000000000000 Right: 393.00000000000000 Bottom: 285.00000000000000 ) (RectD.190 Left: 225.00000000000000 Top: 309.00000000000000 Right: 307.00000000000000 Bottom: 285.00000000000000 ) (RectD.191 Left: 622.00000000000000 Top: 591.00000000000000 Right: 927.00000000000000 Bottom: 337.00000000000000 ) (RectD.192 Left: 139.00000000000000 Top: 309.00000000000000 Right: 221.00000000000000 Bottom: 285.00000000000000 ) (RectD.193 Left: 930.00000000000000 Top: 592.00000000000000 Right: 1236.00000000000000 Bottom: 338.00000000000000 ) (RectD.194 Left: 8.00000000000000 Top: 309.00000000000000 Right: 90.00000000000000 Bottom: 285.00000000000000 ) (Nil.195 ) (Script.196 Name: "Legends.Create" SourceCode: "thelayout = av.GetActiveDoc\nif ( Not (theLayout.is(Layout))) then\n Msgbox.Info(\"Please make your layout active again.\",\"Oops\")\n return nil\nend\n\nLgraphics = thelayout.GetGraphics\nMTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nif (self.GetLabel = \"Finish\") then\n m = LGraphics.FindByName(\"_Try_It\") \n m.SetName(\"Finished Legend\")\n MTD.Close\n return nil\nend\n\n\nBackButton = MTD.FindByName(\"LBack\")\nNextButton = MTD.FindByName(\"LNext\")\nFinishButton = MTD.FindByName(\"LFinish\")\n\nVFrame = MTD.FindByName(\"Vn ame\").GetSelection\nNumCols = MTD.FindByName(\"NumCols\").GetSelection\nFinishButton = MTD.FindByName(\"LFinish\")\nLegTitle = MTD.FindByName(\"LegTitle\").GetText\nTitleFont = MTD.FindByName(\"TitleFont\").GetSelection\nTitleSize = MTD.FindByName(\"TitleSize\").GetSelection.AsNumber\nTitleStyle = MTD.FindByName(\"TitleStyle\").GetSelection\nif (MTD.FindByName(\"TitleStyle\").GetList.FindByValue(\"Normal\") <> -1) then\n FontNorm = \"Normal\"\nelse\n FontNorm = MTD.FindByName(\"TitleStyle\").GetList.Get(0)\nend\n\nBorderStyle = MTD.FindB yName(\"BorderStyle\").GetCurrentRow\nBorderWidth = MTD.FindByName(\"BorderWidth\").GetSelection.AsNumber\nBorderOLColor = MTD.FindByName(\"BorderOLColor\").GetSelection\nBorderBGColor = MTD.FindByName(\"BorderBGColor\").GetSelection\nUseDropShadow = MTD.FindByName(\"UseDropShadow\").IsSelected\nRoundCorners = MTD.FindByName(\"RoundCorners\").IsSelected\n\nPolysAsRects = MTD.FindByName(\"PolysAsRects\").IsSelected\nPolysAsSquares = MTD.FindByName(\"PolysAsSquares\").IsSelected\nPolysAsOvals = MTD.FindByName(\"PolysAsOvals\").IsSelect ed\nLinesAsHorz = MTD.FindByName(\"LinesAsHorz\").IsSelected\nLinesAsZigZag = MTD.FindByName(\"LinesAsZigZag\").IsSelected\nLinesAsEsses = MTD.FindByName(\"LinesAsEsses\").IsSelected\n\nXTitleLegend = MTD.FindByName(\"XTitleLegend\").GetText.AsNumber\nXColumns = MTD.FindByName(\"XColumns\").GetText.AsNumber\nXThemes = MTD.FindByName(\"XThemes\").GetText.AsNumber\nXThemeSyms = MTD.FindByName(\"XThemeSyms\").GetText.AsNumber\nXSymsLabels = MTD.FindByName(\"XSymsLabels\").GetText.AsNumber\nXSymRows = MTD.FindByName(\"XSymRows\").GetText. AsNumber\nXSymWidth = MTD.FindByName(\"XSymWidth\").GetText.AsNumber\n\nUL = MTD.FindByName(\"UL\").IsSelected\nUC = MTD.FindByName(\"UC\").IsSelected\nUR = MTD.FindByName(\"UR\").IsSelected\nLC = MTD.FindByName(\"LC\").IsSelected\nRC = MTD.FindByName(\"RC\").IsSelected\nLL = MTD.FindByName(\"LL\").IsSelected\nCL = MTD.FindByName(\"CL\").IsSelected\nRL = MTD.FindByName(\"RL\").IsSelected\n\nLegFlatness = av.GetProject.GetLegendLineFlatness\nlsw = XSymWidth\nllh = 0.2 * (100 - LegFlatness) /100\n\nthelayout = av.GetActiveDoc\nLgraphics = thel ayout.GetGraphics\nRectOrigin = FinishButton.GetObjectTag\n\ntheView = av.GetProject.FindDoc(VFrame)\ntheThemesToUse = MTD.FindByName(\"LegThemes\").GetList\n\nif (NumCols <> \"One per theme\") then\n MaxNumCols = NumCols.AsNumber\nend\n\nif (theThemesToUse.Count = 1) then\n DefTitle = LegTitle\n ThemeHasTitle = false\nelse\n DefTitle = LegTitle\n ThemeHasTitle = true\nend\nif (DefTitle.Count < 1) then\n LegendHasTitle = false\nelse\n LegendHasTitle = true\nend\n\n'*********************************************************\n'* S trategy is to make one column per theme then *\n'* if the legend configuration strategy is based on *\n'* columns this will also be used, but more than one *\n'* theme may be in a column, but only very large *\n'* themes will be permitted to be broken across columns. *\n'* If the strategy is based on rows, then a separate *\n'* routine will be used to create the legend, but it *\n'* will still be theme based. *\n'******************************************* **************\n\nif (NumCols = \"One per theme\")then\n NextGraphicOrigin = (100@100)\n if (LegendHasTitle) then\n NextGraphicOrigin = NextGraphicOrigin + (0@(XTitleLegend))\n theTitle = GraphicText.Make(DefTitle,NextGraphicOrigin)\n theTitle.GetSymbol.SetFont(Font.Make(TitleFont,TitleStyle))\n theTitle.GetSymbol.SetSize(TitleSize)\n theTitle.SetDisplay(theLayout.GetDisplay)\n theTitle.SetObjectTag(\"cl\")\n theTitle.SetSelected(false)\n NextGraphicOrigin = NextGraphicOrigin - (0@XTitleLegend)\n end\n for each thm in theThemesToUse\n tt = theView.FindTheme(thm)\n if (tt = nil) then return nil end\n theLegend = theView.FindTheme(thm).GetLegend\n ss = XSymRows + 0.2\n if ((tt.Is(FTheme)) OR (tt.GetClass.GetClassName = \"DBTheme\") OR (tt.GetClass.GetClassName = \"GTheme\") OR (tt.GetClass.GetClassName = \"BaseMapTheme\")) then\n theClasses = theLegend.GetClassifications\n theSymbols = theLegend.GetSymbols\n ThemeIsSimple = false\n ThemeHasTitle = true\n if (theLegend.GetLegend Type = #LEGEND_TYPE_SIMPLE) then\n ThemeHasTitle = false\n ThemeIsSimple = true\n end\n if (ThemeHasTitle) then\n theThemeTitle = GraphicText.Make(thm,NextGraphicOrigin)\n theThemeTitle.GetSymbol.SetFont(Font.Make(TitleFont,FontNorm))\n theThemeTitle.GetSymbol.SetSize(12)\n theThemeTitle.SetDisplay(thelayout.GetDisplay)\n ThemeTitleHeight = theThemeTitle.GetBounds.GetHeight\n Lgraphics.AddBatch(theThemeTitle)\n theThemeTitle.SetObjectTag(\"cl\")\n theThemeTitle.SetSelected(false)\n NextGraphicOrigin = NextGraphicOrigin - (0@(XThemeSyms + ThemeTitleHeight))\n end\n for each c in 0..((theClasses.Count) - 1)\n if ((theLegend.IsNoDataClassDisplayed.Not) and (theClasses.Get(c).GetLabel = \"No Data\")) then\n continue\n end \n itemLabel = theClasses.Get(c).GetLabel\n if ((itemLabel = Nil) or (itemLabel = \"\")) then 'Handle for SingleSymbol Legends with No Label\n itemLabel = thm\n end\n t heLabel = GraphicText.Make( itemLabel,( NextGraphicOrigin + ((XSymWidth + XSymsLabels)@0.05) ) )\n theLabel.GetSymbol.SetFont(Font.make(TitleFont,FontNorm))\n theLabel.GetSymbol.SetSize(10)\n theLabel.SetDisplay(thelayout.GetDisplay) \n theSym = theSymbols.Get(c).Clone\n if (theSym.Is(Fill)) then\n if (PolysAsRects) then\n newgraphic = GraphicShape.Make(Rect.Make(NextGraphicOrigin,(lsw@0.2))) 'Standard Rect\n elseif (PolysAsOvals) then\n newgraphic = GraphicShape.Make(Oval.Make(NextGraphicOrigin,(lsw@0.2))) 'Oval\n elseif (PolysAsSquares) then\n newgraphic = GraphicShape.Make(Rect.Make( (NextGraphicOrigin + ((0.25*lsw)@0)) ,(0.2@0.2) )) 'Square\n end\n elseif (theSym.Is(Pen)) then\n if (LinesAsEsses) then\n newgraphic = GraphicShape.Make(PolyLine.Make({{(0@0),(0.125@0.625),(0.25@0.875),(0.375@0.97),(0.5@1),(0.625@0.97),(0.75@0.875),(0.875@0.725),(1@0.5),(1.125@0.275),(1.25@0.125),(1.375@0. 03),(1.5@0),(1.625@0.03),(1.75@0.125),(1.875@0.375),(2@1)}})) 'Squiggle \n newgraphic.SetOrigin(NextGraphicOrigin)\n newgraphic.SetBounds(Rect.Make(NextGraphicOrigin,(XSymWidth@0.2)))\n newGraphic.SetExtent(XSymWidth@llh)\n elseif (LinesAsHorz) then\n newgraphic = GraphicShape.Make(Line.Make( (NextGraphicOrigin + (0@0.11)),(NextGraphicOrigin +(XSymWidth@0.11)) ) )\n elseif (LinesAsZigZag) then\n newgraphic = GraphicShape.Make(PolyLine .Make({{(0@0),(0.133334@0.2),(0.2666667@0),(0.4@0.2)}}))\n newgraphic.SetOrigin(NextGraphicOrigin)\n newGraphic.SetExtent(XSymWidth@llh)\n end\n elseif (theSym.Is(Marker)) then \n newgraphic = GraphicShape.Make(NextGraphicOrigin + ( ((lsw/2))@0.1) )\n if(thesym.GetSize > 18) then\n ss = thesym.GetSize/72\n end\n elseif (theSym.Is(TextSymbol)) then\n newgraphic = GraphicText.Make(\"Text\",NextGraphicOrigin)\n end\n \n newgraphic.SetSymbol(thesym)\n newgraphic.GetSymbol.SetColorLock(true)\n newgraphic.SetObjectTag(\"cl\")\n theLabel.SetObjectTag(\"cl\")\n Lgraphics.AddBatch(theLabel)\n Lgraphics.AddBatch(newgraphic)\n newgraphic.SetSelected(true)\n theLabel.SetSelected(true)\n NextGraphicOrigin = NextGraphicOrigin - (0@ss)\n end\n elseif (tt.Is(ITheme)) then\n itemLabel = thm\n theLabel = GraphicText.Make( itemLabel,( NextGraphicOrigin + ((XSymWidth + XSym sLabels)@0.05) ) )\n theLabel.GetSymbol.SetFont(Font.make(TitleFont,FontNorm))\n theLabel.GetSymbol.SetSize(10)\n theLabel.SetDisplay(thelayout.GetDisplay)\n newgraphic = GraphicText.Make(\" Image\",(NextGraphicOrigin + (0@0.05)))\n newgraphic.GetSymbol.SetFont(Font.make(TitleFont,FontNorm))\n newgraphic.GetSymbol.SetSize(10)\n newgraphic.SetDisplay(thelayout.GetDisplay)\n newgraphic.GetSymbol.SetColorLock(true)\n newgraphic.SetObjectTag(\"cl\")\n theLabel.SetObjectTag(\" cl\")\n Lgraphics.AddBatch(theLabel)\n Lgraphics.AddBatch(newgraphic)\n newgraphic.SetSelected(true)\n theLabel.SetSelected(true)\n NextGraphicOrigin = NextGraphicOrigin - (0@ss)\n themeHasTitle = false\n else\n continue\n end\n 'Then Center the Title\n if (themeHasTitle) then\n 'Group the individual components of the legend\n Lgraphics.GroupSelected\n components = Lgraphics.GetSelected.Get(0)\n ComponentsWidth = components.GetBounds.GetWidth\n TitleWid th = theThemeTitle.GetBounds.GetWidth\n if (ComponentsWidth >= TitleWidth) then\n oldOrigin = theThemeTitle.GetOrigin\n newOrigin = oldOrigin + ( ((ComponentsWidth - TitleWidth)/2)@0 )\n theThemeTitle.SetOrigin(newOrigin)\n else\n oldOrigin = components.GetOrigin\n newOrigin = oldOrigin + ( ((TitleWidth - ComponentsWidth)/2)@0 )\n components.SetOrigin(newOrigin)\n end\n theThemeTitle.SetSelected(true) \n Lgraphics.GroupSelected\n Lgraphics.GetSelec ted.Get(0).SetObjectTag(\"cl\")\n else\n Lgraphics.GroupSelected \n Lgraphics.GetSelected.Get(0).SetObjectTag(\"cl\")\n end\n PartsSoFar = Lgraphics.FindAllByObjectTag(\"cl\")\n for each h in PartsSoFar\n h.SetSelected(true)\n end\n Lgraphics.GroupSelected\n WidthSoFar = Lgraphics.GetSelected.Get(0).GetBounds.GetWidth\n Lgraphics.UngroupSelected\n coladj = lsw.Clone\n if (colAdj < 0.4) then\n colAdj = 0.4\n end\n NextGraphicOrigin = ((100 + XColumns + colAdj)@100 ) + (WidthSoFar@0)\n Lgraphics.UnSelectAll\n end 'Processing of themes\n theLegParts = Lgraphics.FindAllByObjectTag(\"cl\")\n for each gi in theLegParts\n gi.SetSelected(true)\n end\n\n\nelse\n TotalHeight = 0\n ThemeHeights = {}\n ThemeHeight = 0\n for each thm in theThemesToUse\n tt = theView.FindTheme(thm)\n if (tt = nil) then return nil end\n if ((tt.Is(FTheme)) OR (tt.GetClass.GetClassName = \"DBTheme\") OR (tt.GetClass.GetClassName = \"GTheme\") OR (tt.GetClass.GetClassName = \"BaseMapTheme\")) then\n theLegend = theView.FindTheme(thm).GetLegend\n ss = XSymRows + 0.2\n theSymbols = theLegend.GetSymbols\n theClasses = theLegend.GetClassifications\n theThemeTitle = GraphicText.Make(\"KK\",(1@1))\n theThemeTitle.GetSymbol.SetSize(12)\n theThemeTitle.SetDisplay(thelayout.GetDisplay)\n ThemeTitleHeight = theThemeTitle.GetBounds.GetHeight\n if (theLegend.GetLegendType = #LEGEND_TYPE_SIMPLE) then\n theSymbols = theLegend.GetSymbols\n ThemeHeight = XSymRows + 0.2\n if (theSymbols.Get(0).Is(Marker)) then\n if (theSymbols.Get(0).GetSize > 18) then\n ThemeHeight = (theSymbols.Get(0).GetSize/72)\n end\n end\n else\n ThemeHeight = XThemeSyms + ThemeTitleHeight\n for each s in 0..((theSymbols.Count) - 1)\n if ((theLegend.IsNoDataClassDisplayed.Not) and (theClasses.Get(s).GetLabel = \"No Data\")) then\n continue\n end \n ThemeHeight = ThemeHeight + XSymRows + 0.2\n if (theSymbols.Get (s).Is(Marker)) then\n if (theSymbols.Get(s).GetSize > 18) then\n ThemeHeight = ThemeHeight + (theSymbols.Get(s).GetSize/72) + XThemes\n end\n end\n end \n end\n elseif (tt.Is(ITheme)) then\n ThemeHeight = XSymRows + 0.2\n else\n continue\n end\n ThemeHeights.Add((ThemeHeight))\n TotalHeight = TotalHeight + ThemeHeight \n ThemeHeight = 0 \n end\n\n MinColumnHeight = TotalHeight / MaxNumCols \n NextGraphicOrigin = (100@100)\n SetRunningH eightToZero = false\n RunningHeightTotal = 0\n if (LegendHasTitle) then\n NextGraphicOrigin = NextGraphicOrigin + (0@XTitleLegend)\n theTitle = GraphicText.Make(DefTitle,NextGraphicOrigin)\n theTitle.GetSymbol.SetFont(Font.Make(TitleFont,TitleStyle))\n theTitle.GetSymbol.SetSize(TitleSize)\n theTitle.SetDisplay(theLayout.GetDisplay)\n theTitle.SetObjectTag(\"cl\")\n theTitle.SetSelected(false)\n NextGraphicOrigin = NextGraphicOrigin - (0@XTitleLegend)\n end\n TitleList = {}\n FirstGroup = true \n for each thm in theThemesToUse\n StartedANewColumn = false\n tt = theView.FindTheme(thm)\n if ((tt.Is(FTheme)) OR (tt.GetClass.GetClassName = \"DBTheme\") OR (tt.GetClass.GetClassName = \"GTheme\") OR (tt.GetClass.GetClassName = \"BaseMapTheme\")) then\n theLegend = tt.GetLegend\n theClasses = theLegend.GetClassifications\n theSymbols = theLegend.GetSymbols\n if (theLegend.GetLegendType = #LEGEND_TYPE_SIMPLE) then\n ThemeHasTitle = false\n else\n ThemeHasTitle = true\n end\n \n if (ThemeHasTitle) then\n '** Check to see if there's room at the bottom of the column to start another theme\n if (RunningHeightTotal >= (MinColumnHeight - (ThemeTitleHeight + XThemeSyms + 0.2 + XSymRows)) ) then\n Lgraphics.GroupSelected\n if (Lgraphics.GetSelected.Count = 0) then\n jh = Lgraphics.FindAllByObjectTag(\"cl\")\n if (jh <> nil) then \n for each gy in jh\n gy.SetSelected(true)\n en d\n Lgraphics.GroupSelected\n end\n end\n Lgraphics.GetSelected.Get(0).SetObjectTag(\"cl\")\n PartsSoFar = Lgraphics.FindAllByObjectTag(\"cl\")\n for each h in PartsSoFar\n h.SetSelected(true)\n end\n Lgraphics.GroupSelected\n WidthSoFar = Lgraphics.GetSelected.Get(0).GetBounds.GetWidth\n Lgraphics.UngroupSelected\n NextGraphicOrigin = ((100+XColumns)@100) + (WidthSoFar@0)\n Lgraphics.UnSelectAll\n RunningHeightTotal = 0\n StartedANewColumn = true \n end\n \n theThemeTitle = GraphicText.Make(thm,NextGraphicOrigin)\n theThemeTitle.GetSymbol.SetSize(12)\n theThemeTitle.GetSymbol.SetFont(Font.Make(TitleFont,FontNorm))\n theThemeTitle.SetDisplay(thelayout.GetDisplay)\n theTitleHeight = theThemeTitle.GetBounds.GetHeight\n Lgraphics.AddBatch(theThemeTitle)\n theThemeTitle.SetObjectTag(\"cl\")\n theThemeTitle.SetName(\"ThemeTitle\")\n theThemeTitle.SetSelected(false)\n NextGraphicOrigin = NextGraphicOrigin - (0@(XThemeSyms + theTitleHeight))\n RunningHeightTotal = RunningHeightTotal + XThemeSyms + theTitleHeight\n end\n for each c in 0..((theClasses.Count) - 1)\n if ((theLegend.IsNoDataClassDisplayed.Not) and (theClasses.Get(c).GetLabel = \"No Data\")) then\n continue\n end \n itemLabel = theClasses.Get(c).GetLabel\n if ((itemLabel = Nil) or (itemLabel = \"\")) then 'Handle for SingleSymbo l Legends with No Label\n itemLabel = thm\n end\n theLabel = GraphicText.Make( itemLabel,( NextGraphicOrigin + ((XSymWidth + XSymsLabels)@0.05) ) )\n theLabel.GetSymbol.SetFont(Font.make(TitleFont,FontNorm))\n theLabel.GetSymbol.SetSize(10)\n theLabel.SetDisplay(thelayout.GetDisplay)\n theSym = theSymbols.Get(c).Clone\n ss = XSymRows + 0.2\n if (theSym.Is(Fill)) then\n if (PolysAsRects) then\n newgraphic = GraphicShape.Make(Rect.Make( NextGraphicOrigin,(lsw@0.2))) 'Standard Rect\n elseif (PolysAsOvals) then\n newgraphic = GraphicShape.Make(Oval.Make(NextGraphicOrigin,(lsw@0.2))) 'Oval\n elseif (PolysAsSquares) then\n newgraphic = GraphicShape.Make(Rect.Make( (NextGraphicOrigin + ((0.25*lsw)@0)) ,(0.2@0.2) )) 'Standard Rect\n end\n elseif (theSym.Is(Pen)) then\n if (LinesAsEsses) then\n newgraphic = GraphicShape.Make(PolyLine.Make({{(0@0),(0.125@0.625),(0.25@0.875),(0.3 75@0.97),(0.5@1),(0.625@0.97),(0.75@0.875),(0.875@0.725),(1@0.5),(1.125@0.275),(1.25@0.125),(1.375@0.03),(1.5@0),(1.625@0.03),(1.75@0.125),(1.875@0.375),(2@1)}})) 'Squiggle \n newgraphic.SetOrigin(NextGraphicOrigin)\n newgraphic.SetBounds(Rect.Make(NextGraphicOrigin,(XSymWidth@0.2)))\n newGraphic.SetExtent(XSymWidth@llh)\n elseif (LinesAsHorz) then\n newgraphic = GraphicShape.Make(Line.Make( (NextGraphicOrigin + (0@0.11)),(NextGraphicOrigin +(XSymWidth@0 .11)) ) )\n elseif (LinesAsZigZag) then\n newgraphic = GraphicShape.Make(PolyLine.Make({{(0@0),(0.133334@0.2),(0.2666667@0),(0.4@0.2)}}))\n newgraphic.SetOrigin(NextGraphicOrigin)\n newGraphic.SetExtent(XSymWidth@llh)\n end\n elseif (theSym.Is(Marker)) then \n newgraphic = GraphicShape.Make(NextGraphicOrigin + ( ((lsw/2))@0.1) )\n if(thesym.GetSize > 18) then\n ss = thesym.GetSize/72\n end\n elseif (theSym.I s(TextSymbol)) then\n newgraphic = GraphicText.Make(\"Text\",NextGraphicOrigin)\n end \n newgraphic.SetSymbol(thesym)\n newgraphic.GetSymbol.SetColorLock(true)\n newgraphic.SetObjectTag(\"cl\")\n theLabel.SetObjectTag(\"cl\")\n Lgraphics.AddBatch(theLabel)\n Lgraphics.AddBatch(newgraphic)\n newgraphic.SetSelected(true)\n theLabel.SetSelected(true)\n NextGraphicOrigin = NextGraphicOrigin - (0@ss)\n RunningHeightTotal = RunningHeightTotal + ss\n if (RunningHeightTotal >= MinColumnHeight)then\n Lgraphics.GroupSelected\n Lgraphics.GetSelected.Get(0).SetObjectTag(\"cl\")\n components = Lgraphics.GetSelected.Get(0)\n ComponentsWidth = components.GetBounds.GetWidth\n PartsSoFar = Lgraphics.FindAllByObjectTag(\"cl\")\n for each h in PartsSoFar\n h.SetSelected(true)\n end\n Lgraphics.GroupSelected\n WidthSoFar = Lgraphics.GetSelected.Get(0).GetBounds.GetWidth\n Lgraphics.UngroupSelected\n NextGraphicOrigin = ((100+XColumns)@100) + (WidthSoFar@0)\n Lgraphics.UnSelectAll\n RunningHeightTotal = 0\n StartedANewColumn = true \n end \n end \n elseif (tt.Is(ITheme)) then\n itemLabel = thm\n theLabel = GraphicText.Make( itemLabel,( NextGraphicOrigin + ((XSymWidth + XSymsLabels)@0.05) ) )\n theLabel.GetSymbol.SetFont(Font.make(TitleFont,FontNorm))\n theLabel.GetSymbol.SetSize(10)\n theLabel.SetDi splay(thelayout.GetDisplay)\n newgraphic = GraphicText.Make(\" Image\",(NextGraphicOrigin + (0@0.05)))\n newgraphic.GetSymbol.SetFont(Font.make(TitleFont,FontNorm))\n newgraphic.GetSymbol.SetSize(10)\n newgraphic.SetDisplay(thelayout.GetDisplay)\n newgraphic.GetSymbol.SetColorLock(true)\n newgraphic.SetObjectTag(\"cl\")\n theLabel.SetObjectTag(\"cl\")\n Lgraphics.AddBatch(theLabel)\n Lgraphics.AddBatch(newgraphic)\n newgraphic.SetSelected(true)\n theLabel.SetSelected(t rue)\n NextGraphicOrigin = NextGraphicOrigin - (0@ss)\n RunningHeightTotal = RunningHeightTotal + ss\n themeHasTitle = false \n else\n continue\n end\n \n if (RunningHeightTotal >= MinColumnHeight) then\n Lgraphics.GroupSelected\n Lgraphics.GetSelected.Get(0).SetObjectTag(\"cl\")\n PartsSoFar = Lgraphics.FindAllByObjectTag(\"cl\")\n for each h in PartsSoFar\n h.SetSelected(true)\n end\n Lgraphics.GroupSelected\n WidthSoFar = Lgraphics.GetSelected. Get(0).GetBounds.GetWidth\n Lgraphics.UngroupSelected\n NextGraphicOrigin = ((100+XColumns)@100) + (WidthSoFar@0)\n Lgraphics.UnSelectAll\n RunningHeightTotal = 0\n StartedANewColumn = true \n end\n \n\n if (RunningHeightTotal <> 0) then\n NextGraphicOrigin = (NextGraphicOrigin - (0@XThemes))\n end\n \n PartsSoFar = Lgraphics.FindAllByObjectTag(\"cl\")\n for each h in PartsSoFar\n h.SetSelected(true)\n end\n if (SetRunningHeightToZero.Not) then\n Lgraphics .UnSelectAll\n else \n Lgraphics.GroupSelected\n Lgraphics.GetSelected.Get(0).SetObjectTag(\"cl\")\n LGraphics.UnSelectAll\n end\n \n end ' For each Theme \nend\n\n'***************************************\n'* If the Legend has a title, this is *\n'* when we position it relative to the *\n'* rest of the legend. *\n'***************************************\n\nif (legendHasTitle) then\n 'Get All the graphics and group them\n lg = Lgraphics.FindAllByObjectTag(\"cl\")\n for each l in lg\n l.SetSelected(true)\n end\n Lgraphics.GroupSelected\n AllButTitle = Lgraphics.GetSelected.Get(0)\n AllButTitle.SetObjectTag(\"cl\")\n \n Lgraphics.Add(theTitle)\n TitleWidth = theTitle.GetBounds.GetWidth\n TitleHeight = theTitle.GetBounds.GetHeight\n AllButTitleWidth = AllButTitle.GetBounds.GetWidth\n AllButTitleHeight = AllButTitle.GetBounds.GetHeight\n AllButTitleOrigin = AllButTitle.GetOrigin\n \n if (UC) then\n if (AllButTitleWidth >= TitleWidth) then\n oldOrigin = theTitle.GetOrigin\n newOrigi n = oldOrigin + ( ((AllButTitleWidth - TitleWidth)/2)@0 )\n theTitle.SetOrigin(newOrigin)\n else\n oldOrigin = AllButTitle.GetOrigin\n newOrigin = oldOrigin + ( ((TitleWidth - AllButTitleWidth)/2)@0 )\n AllButTitle.SetOrigin(newOrigin)\n end\n elseif (CL) then \n if (AllButTitleWidth >= TitleWidth) then\n oldOrigin = theTitle.GetOrigin\n newOrigin = oldOrigin + ( ((AllButTitleWidth - TitleWidth)/2)@(-AllButTitleHeight) )\n theTitle.SetOrigin(newOrigin)\n AllButTitle.Se tOrigin(AllButTitleOrigin + (0@(TitleHeight + XTitleLegend)))\n else\n oldOrigin = AllButTitle.GetOrigin\n newOrigin = oldOrigin + ( ((TitleWidth - AllButTitleWidth)/2)@(-AllButTitleHeight) )\n AllButTitle.SetOrigin(newOrigin)\n AllButTitle.SetOrigin(AllButTitleOrigin + (0@(TitleHeight + XTitleLegend)))\n end\n elseif (UL) then \n 'Do Nothing since that's where it is anyway\n elseif (LC) then \n oldOrigin = theTitle.GetOrigin\n newOrigin = oldOrigin - ( 0@( (AllButTitleHei ght/2) + (TitleHeight/(1.4)) ) )\n theTitle.SetOrigin(newOrigin)\n AllButTitle.SetOrigin(AllButTitleOrigin + ((TitleWidth + XTitleLegend)@0))\n elseif (LL) then \n oldOrigin = theTitle.GetOrigin\n newOrigin = oldOrigin + ( 0@(-AllButTitleHeight) )\n theTitle.SetOrigin(newOrigin)\n AllButTitle.SetOrigin(AllButTitleOrigin + (0@(TitleHeight + XTitleLegend )))\n elseif (UR) then \n oldOrigin = theTitle.GetOrigin\n newOrigin = oldOrigin + ( (AllButTitleWidth - TitleWidth)@0 )\n theTitle.SetOrigin(newOrigin)\n elseif (RC) then \n oldOrigin = theTitle.GetOrigin\n newOrigin = oldOrigin + ( (AllButTitleWidth + XTitleLegend)@( -((AllButTitleHeight/2) + (TitleHeight/(1.4))) ) )\n theTitle.SetOrigin(newOrigin)\n elseif (RL) then \n oldOrigin = theTitle.GetOrigin\n newOrigin = oldOrigin + ( (AllButTitleWidth - TitleWidth)@(-(AllButTitleHeight+(0)) ) )\n theTitle.SetOrigin(newOrigin)\n AllButTitle.SetOrigin(AllButTitleOrigin + (0@(TitleHeight + XTitleLeg end)))\n end\nend\n\n \n \ntheLegParts = Lgraphics.FindAllByObjectTag(\"cl\")\nfor each gi in theLegParts\n gi.SetSelected(true)\nend\n \n\n \n'Place Bounding Box behind legend\n \nLgraphics.GroupSelected\nif (Lgraphics.GetSelected.Count = 0) then\n jh = Lgraphics.FindAllByObjectTag(\"cl\")\n for each gy in jh\n gy.SetSelected(true)\n end\n Lgraphics.GroupSelected\nend\n\ntheLeg = Lgraphics.GetSelected.Get(0)\ntheLeg.SetName(\"cl\")\nbrect = theLeg.GetBounds.Clone\ncursize = brect.ReturnSize\nbrect.SetSize( (cursize + (0.5@0.4)) )\ncurorig = brect.ReturnOrigin\nbrect.SetOrigin( (curorig - (0.25@0.25)) )\n\nBlackList = {0,0,0}\nDRedList = {150,0,0}\nDGreenList = {0,150,0}\nDBlueList = {0,0,150}\nDGrayList = {120,120,120}\nBrownList = {150,120,50}\nWhiteList = {255,255,255}\nLYellowList = {255,255,220}\nLGreenList = {220,255,220}\nLBlueList = {220,220,255}\nLGrayList = {220,220,220}\nBeigeList = {240,220,200}\n\nBGColor = Color.Make\nOLColor = Color.Make\nif (BorderOLColor = \"Black\") then\n OLColor.SetRGBList(BlackList)\nelseif(BorderOLColor = \"Dark Re d\") then\n OLColor.SetRGBList(DRedList)\nelseif(BorderOLColor = \"Dark Green\") then\n OLColor.SetRGBList(DGreenList)\nelseif(BorderOLColor = \"Dark Blue\") then\n OLColor.SetRGBList(DBlueList)\nelseif(BorderOLColor = \"Dark Gray\") then\n OLColor.SetRGBList(DGrayList)\nelseif(BorderOLColor = \"Brown\") then\n OLColor.SetRGBList(BrownList)\nend\n\nif (BorderBGColor = \"White\") then\n BGColor.SetRGBList(WhiteList)\nelseif(BorderBGColor = \"Light Yellow\") then\n BGColor.SetRGBList(LYellowList)\nelseif(BorderBGColor = \"Light Gre en\") then\n BGColor.SetRGBList(LGreenList)\nelseif(BorderBGColor = \"Light Blue\") then\n BGColor.SetRGBList(LBlueList)\nelseif(BorderBGColor = \"Light Gray\") then\n BGColor.SetRGBList(LGrayList)\nelseif(BorderBGColor = \"Beige\") then\n BGColor.SetRGBList(BeigeList)\nend\ntrnc = Color.Make\ntrnc.SetTransparent(true)\n\n\nLGraphics.EndBatch\n\nif (RoundCorners) then\n BGShp = av.Run(\"Graphic.RoundRectCorners\",{brect, 0.1875})\n BGRect = GraphicShape.Make(BGShp)\n BGRect.SetBounds(brect.Clone)\nelseif (RoundCorners.Not) then \n BGRect = GraphicShape.Make(brect) \nend\nbgfill = RasterFill.Make\nbgfill.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\nbgfill.SetColor(trnc)\nbgfill.SetBGColor(BGColor)\nbgfill.SetOLColor(OLColor)\nbgfill.SetOLWidth(BorderWidth)\nBGRect.SetSymbol(bgfill)\nBGRect.SetDisplay(thelayout.GetDisplay) \n\n\nif (BorderStyle = 0) then\n \n LGraphics.Add(BGRect)\n LGraphics.MoveSelectedToFront\n BGRect.SetSelected(True)\n LGraphics.GroupSelected\n LGraphics.GetSelected.Get(0).SetOrigin(RectOrigin)\n BGRect.Invalidate\n if (UseD ropShadow) then\n theRest = LGraphics.GetSelected.Get(0)\n theRest.SetSelected(false)\n DSS = BGRect.GetShape.Clone\n DS = GraphicShape.Make(DSS)\n DSO = DS.GetBounds.ReturnOrigin.Clone\n DS.SetBounds(Rect.Make(DSO + (0.1875@(-0.1875)),theRest.GetExtent ))\n DSColor = Color.Make\n DSColor.SetRGBList(DGrayList)\n DS.SetSymbol(bgfill.clone)\n DS.GetSymbol.SetBGColor(DSColor)\n DS.GetSymbol.SetOLColor(DSColor)\n LGraphics.Add(DS)\n DS.SetSelected(true)\n LGraphics.MoveSelectedToBack \n theRest.SetSelected(True)\n LGraphics.GroupSelected\n LGraphics.GetSelected.Get(0).Invalidate\n end\n\nelse\n BiggerRect = BGRect.GetShape.Clone\n BGRect1 = GraphicShape.Make(BiggerRect)\n BRB = BGRect1.GetBounds.Clone\n BRB.ExpandBy(BorderWidth/36)\n BGRect1.SetBounds(BRB)\n BGRect1.SetSymbol(bgfill.Clone)\n BGRect.GetSymbol.SetOLWidth(0.2)\n BGrect1.GetSymbol.SetOLWidth(0.2)\n if (BorderStyle = 2) then\n BGRect.GetSymbol.SetOLWidth(3)\n end\n LGraphics.Add(BGRect)\n LGraphics.MoveSelectedToFront\n BGRect.SetSelected(True)\n LGraphics.GroupSelected\n LGraphics.Add(BGRect1)\n LGraphics.MoveSelectedToFront\n BGRect1.SetSelected(True)\n LGraphics.GroupSelected \n LGraphics.GetSelected.Get(0).SetOrigin(RectOrigin)\n \n if (UseDropShadow) then\n theRest = LGraphics.GetSelected.Get(0)\n theRest.SetSelected(false)\n DSS = BGRect1.GetShape.Clone\n DS = GraphicShape.Make(DSS)\n DSO = DS.GetBounds.ReturnOrigin.Clone\n DS.SetBounds(Rect.Make(DSO + (0.1875@(-0.1875)),theRest.GetExtent ))\n DSColor = Color.Make\n DSColor.SetRGBList(DGrayList)\n DS.SetSymbol(bgfill.clone)\n DS.GetSymbol.SetBGColor(DSColor)\n DS.GetSymbol.SetOLColor(DSColor)\n LGraphics.Add(DS)\n DS.SetSelected(true)\n LGraphics.MoveSelectedToBack\n theRest.SetSelected(True)\n LGraphics.GroupSelected\n end\n\n LGraphics.GetSelected.Get(0).SetName(\"_Try_It\")\n LGraphics.MoveSelectedToFront \n LGraphics.GetSelected.Get(0).Invalidate\n \nend\n\nLGraphics.GetSelected.Get(0).SetName(\"_Try_It\")\nNextButton.SetEnabled(true)\nNext Button.SetLabel(\"Remove\")\nNextButton.SetHelp(\"Removes the preview of the legend from the layout\")\nBackButton.SetEnabled(false)\nSelf.SetLabel(\"Finish\")\nSelf.SetHelp(\"Accept this legend and close the Custom Legend Wizard\")\n\n\n " ) (Script.197 Name: "Legends.AddDrop Themes" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nFinishButton = MTD.FindByName(\"LFinish\")\nNextButton = MTD.FindByName(\"LNext\")\n\nThemeList = MTD.FindByName(\"ThemeList\")\nLegThemes = MTD.FindByName(\"LegThemes\")\nAddThemes = MTD.FindByName(\"AddThemes\")\nRemoveThemes = MTD.FindByName(\"RemoveThemes\")\n\nThemesToAdd = ThemeList.GetSelection\nThemesToDrop = LegThemes.GetSelection\n\nif ((ThemesToAdd = nil) and (Self.GetName = \"AddThemes\")) then\n return nil\nend\nif ((ThemesToDrop = nil) and (Self.GetName = \"RemoveThemes \")) then\n return nil\nend\n\nif ( (ThemesToAdd.Count <> 0) and (Self.GetName = \"AddThemes\") ) then \n CurrentThemesInLegend = LegThemes.GetList\n ThemesToChooseFrom = ThemeList.GetList\n for each xx in ThemesToAdd\n CurrentThemesInLegend.Add(xx)\n ThemesToChooseFrom.RemoveObj(xx)\n end\n LegThemes.DefineFromList(CurrentThemesInLegend)\n ThemeList.DefineFromList(ThemesToChooseFrom)\nend\nif ( ( ThemesToDrop.Count <> 0) and (Self.GetName = \"RemoveThemes\") ) then \n CurrentThemesInLegend = LegThemes.GetList\n ThemesToChooseFrom = ThemeList.GetList\n for each yy in ThemesToDrop\n CurrentThemesInLegend.RemoveObj(yy)\n ThemesToChooseFrom.Add(yy)\n end\n LegThemes.DefineFromList(CurrentThemesInLegend)\n ThemeList.DefineFromList(ThemesToChooseFrom)\nend\n\nif (LegThemes.GetList.Count <> 0) then\n FinishButton.SetEnabled(true)\n NextButton.SetEnabled(true)\nelse\n FinishButton.SetEnabled(false)\n NextButton.SetEnabled(false)\nend" ) (Script.198 Name: "Legends.Change Title Font" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\nTitleFont = MTD.FindByName(\"TitleFont\").GetSelection\nTitleStyle = MTD.FindByName(\"TitleStyle\")\n\n\nfontName = nil\n\nif (Self.GetName = \"TitleFont\") then\n fontName = TitleFont\nend\n\n\nif (fontName <> nil) then\n Styles = FontManager.The.ReturnStyles(fontName)\n \n if (Self.GetName = \"TitleFont\") then\n TitleStyle.DefineFromList(Styles.DeepClone)\n end\nend\n" ) (Script.199 Name: "Legends.Change View" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nCancelButton = MTD.FindByName(\"LCancel\")\nBackButton = MTD.FindByName(\"LBack\")\nNextButton = MTD.FindByName(\"LNext\")\nFinishButton = MTD.FindByName(\"LFinish\")\n\nVFrame = MTD.FindByName(\"Vname\")\nNumCols = MTD.FindByName(\"NumCols\")\nThemeList = MTD.FindByName(\"ThemeList\")\nLegThemes = MTD.FindByName(\"LegThemes\")\nAddThemes = MTD.FindByName(\"AddThemes\")\nRemoveThemes = MTD.FindByName(\"RemoveThemes\")\nLegTitle = MTD.FindByName(\"LegTitle\")\n\nfv = VFrame.GetCurrentValue\nt l = {}\nfor each t in av.FindDoc(fv).GetThemes\n if ((t.GetClass.GetClassName = \"BaseMapTheme\") OR (t.GetClass.GetClassName = \"TTheme\")) then\n continue\n end\n tl.Add(t.GetName)\nend\nLegTitle.SetText(fv)\nThemeList.DefineFromList(tl)\nncols = {\"One per theme\"}\nnThemes = tl.Count\nfor each xx in 1..nThemes\n ncols.Add(xx.AsString)\nend\nNumcols.DefineFromList(ncols)\nNumcols.SelectCurrent\nLegThemes.DefineFromList({})" ) (Script.200 Name: "Legends.Open" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nCancelButton = MTD.FindByName(\"LCancel\")\nBackButton = MTD.FindByName(\"LBack\")\nNextButton = MTD.FindByName(\"LNext\")\nFinishButton = MTD.FindByName(\"LFinish\")\nFinishButton.SetLabel(\"Preview\")\nFinishButton.SetHelp(\"Preview the legend using the current settings\") \n\nNextButton.SetLabel(\"Next >>\")\nNextButton.SetHelp(\"Show the next panel of the Custom Legend Wizard\")\n\nIntroPanel = MTD.FindByName(\"IntroPanel\")\nThemePanel = MTD.FindByName(\"ThemePanel\")\nTitlePanel = MTD.FindByName(\"TitlePanel\")\nBorderPanel = MTD.FindByName(\"BorderPanel\")\nSymbolPanel = MTD.FindByName(\"SymbolPanel\")\nSpacingPanel = MTD.FindByName(\"SpacingPanel\")\n\nVFrame = MTD.FindByName(\"Vname\")\nNumCols = MTD.FindByName(\"NumCols\")\nThemeList = MTD.FindByName(\"ThemeList\")\nLegThemes = MTD.FindByName(\"LegThemes\")\nLegTitle = MTD.FindByName(\"LegTitle\")\nTitleFont = MTD.FindByName(\"TitleFont\")\nTitleSize = MTD.FindByName(\"TitleSize\")\nTitleStyle = MTD.FindByName(\"TitleStyle\")\nTitleJustLab = MTD.FindByName(\"TitleJus tLab\")\nUL = MTD.FindByName(\"UL\")\nUC = MTD.FindByName(\"UC\")\nUR = MTD.FindByName(\"UR\")\nLC = MTD.FindByName(\"LC\")\nRC = MTD.FindByName(\"RC\")\nLL = MTD.FindByName(\"LL\")\nCL = MTD.FindByName(\"CL\")\nRL = MTD.FindByName(\"RL\")\n\nBorderStyle = MTD.FindByName(\"BorderStyle\")\nBorderWidth = MTD.FindByName(\"BorderWidth\")\nBorderOLColor = MTD.FindByName(\"BorderOLColor\")\nBorderBGColor = MTD.FindByName(\"BorderBGColor\")\nUseDropShadow = MTD.FindByName(\"UseDropShadow\")\nRoundCorners = MTD.FindByName(\"RoundCorners\")\n\nPolysAsRects = MT D.FindByName(\"PolysAsRects\")\nPolysAsSquares = MTD.FindByName(\"PolysAsSquares\")\nPolysAsOvals = MTD.FindByName(\"PolysAsOvals\")\nLinesAsHorz = MTD.FindByName(\"LinesAsHorz\")\nLinesAsZigZag = MTD.FindByName(\"LinesAsZigZag\")\nLinesAsEsses = MTD.FindByName(\"LinesAsEsses\")\n\nXTitleLegend = MTD.FindByName(\"XTitleLegend\")\nXColumns = MTD.FindByName(\"XColumns\")\nXThemes = MTD.FindByName(\"XThemes\")\nXThemeSyms = MTD.FindByName(\"XThemeSyms\")\nXSymsLabels = MTD.FindByName(\"XSymsLabels\")\nXSymRows = MTD.FindByName(\"XSymRows\")\nXSym Width = MTD.FindByName(\"XSymWidth\")\n\naIconBox1 = MTD.FindByName(\"aIconBox1\")\nif (System.GetOSVariant = #SYSTEM_OSVARIANT_MSW16) then\n \nelse\n aIf = \"$AVHOME/tools/bitmaps/legwiz1.bmp\".AsFileName\n if (File.Exists(aIf)) then\n WizIcon = Icon.Make(aIf)\n aIconBox1.SetIcon(WizIcon)\n end\nend\n\naIconBox30 = MTD.FindByName(\"aIconBox30\")\naIc = \"$AVHOME/tools/bitmaps/ltp.bmp\".AsFileName\nif (File.Exists(aIc)) then\n PosIcon = Icon.Make(aIc)\n aIconBox30.SetIcon(PosIcon)\nend\n\nFinishButton.SetEnabled(false) 'Gets moved to true when themes are selected \nBackButton.SetEnabled(false)\nCancelButton.SetEnabled(true)\nNextButton.SetEnabled(true)\nMTD.FindByName(\"LegTitle\").SetObjectTag(false)\n\nif (LegTitle.GetText = \"\") then\n TitleFont.SetEnabled(false)\n TitleSize.SetEnabled(false)\n TitleStyle.SetEnabled(false)\n TitleJustLab.SetEnabled(false)\nelse \n TitleFont.SetEnabled(true)\n TitleSize.SetEnabled(true)\n TitleStyle.SetEnabled(true)\n TitleJustLab.SetEnabled(true)\nend\n\n\nncols = {\"One per theme\"}\nnThemes = ThemeList. GetList.Count\nfor each xx in 1..40\n ncols.Add(xx.AsString)\nend\nNumcols.DefineFromList(ncols)\nNumcols.SelectCurrent\nLegThemes.DefineFromList({})\n\nSysFonts = FontManager.The.ReturnFamilies\nTOCF = TOC.GetDefaultSymbol.GetFont\nfontName = TOCF.GetFamily\nstyleName = TOCF.GetStyle\n\nSysFonts.Insert(fontName)\nTitleFont.DefineFromList(SysFonts)\n\n\nStyles = FontManager.The.ReturnStyles(fontName)\nStyles.Insert(styleName)\nTitleStyle.DefineFromList(Styles.DeepClone)\n\n\n\nUC.Select\n\nUseDropShadow.SetSelected(false)\nRoundCor ners.SetSelected(false)\n\nifn1 = \"$AVHOME/tools/bitmaps/solid.bmp\".AsFileName\nifn2 = \"$AVHOME/tools/bitmaps/double.bmp\".AsFileName\nifn3 = \"$AVHOME/tools/bitmaps/dtt.bmp\".AsFileName\nif (File.Exists(ifn1)) then\n Icon1 = Icon.Make(ifn1)\n Icon2 = Icon.Make(ifn2)\n Icon3 = Icon.Make(ifn3)\n Icon1.SetName(\"Single line\")\n Icon2.SetName(\"Uniform double line\")\n Icon3.SetName(\"Thick|Thin double line\")\n BStyles = {Icon1,Icon2,Icon3}\nend\nBorderStyle.DefineFromList(BStyles)\nBorderStyle.FitRows((0..2),false)\n\nLineWei ghts1 = {\"0.1\",\"0.2\",\"0.25\",\"0.5\",\"0.75\",\"1.0\",\"1.25\",\"1.5\",\"2.0\",\"2.5\",\"3.0\"}\nLineWeights2 = {\"3.0\",\"2.5\",\"2.0\",\"1.5\",\"1.25\",\"1.0\",\"0.75\",\"0.5\",\"0.25\",\"0.2\",\"0.1\"}\nBorderWidth.DefineFromList(LineWeights1)\nBOLC = {\"Black\",\"Dark Red\",\"Dark Green\",\"Dark Blue\",\"Dark Gray\",\"Brown\"}\nBorderOLColor.DefineFromList(BOLC)\nBBGC = {\"White\",\"Light Yellow\",\"Light Green\", \"Light Blue\",\"Light Gray\",\"Beige\"}\nBorderBGColor.DefineFromList(BBGC)\n\n\nLabelSizes = {\"18\"}\nfor each h in 10..36\n LabelSizes.Add(h.AsString)\nend\nTitleS ize.DefineFromList(LabelSizes.DeepClone)\n\nPolysAsRects.Select\nLinesAsHorz.Select\n\nLegWideFact = (av.GetProject.GetTOCWidthScale) * 0.4\nif (LegWideFact < 0.15) then\n LegWideFact = 0.4\nend\nXSymWidth.SetText(LegWideFact.AsString)\n\n\nVert = 18\nHorz = 170\n\nIntroPanel.MoveTo(Horz,Vert)\nIntroPanel.SetEnabled(true)\nThemePanel.MoveTo(700,800)\nTitlePanel.MoveTo(1400,400)\nSpacingPanel.MoveTo(700,800)\nBorderPanel.MoveTo(1100,800)\nSymbolPanel.MoveTo(1400,800)\n\nThemePanel.SetEnabled(false)\nTitlePanel.SetEnabled(false)\nBo rderPanel.SetEnabled(false)\nSymbolPanel.SetEnabled(false)\nSpacingPanel.SetEnabled(false)" ) (Script.201 Name: "Legends.Close" SourceCode: "if (av.GetProject.isClosing) then\n return nil\nend\nthelayout = av.GetActiveDoc\nif ( Not (theLayout.is(Layout))) then\n Msgbox.Info(\"Your Preview legend could not be removed because your layout document was not active.\",\"Oops\")\n return nil\nend\n\nMTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nl = av.GetActiveDoc\ntl = l.GetGraphics.FindAllByName(\"_Try_It\")\nif (tl <> nil) then\n for each gxd in tl\n l.GetGraphics.RemoveGraphic(gxd)\n end\nend\n" ) (Script.202 Name: "Legends.Show" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nMTD.SetTitle(\"Custom Legend\")\n\nCancelButton = MTD.FindByName(\"LCancel\")\nBackButton = MTD.FindByName(\"LBack\")\nNextButton = MTD.FindByName(\"LNext\")\nFinishButton = MTD.FindByName(\"LFinish\")\n\nThemePanel = MTD.FindByName(\"ThemePanel\")\nTitlePanel = MTD.FindByName(\"TitlePanel\")\nBorderPanel = MTD.FindByName(\"BorderPanel\")\nSymbolPanel = MTD.FindByName(\"SymbolPanel\")\nSpacingPanel = MTD.FindByName(\"SpacingPanel\")\n\nVFrame = MTD.FindByName(\"Vname\")\nNumCols = MTD.FindBy Name(\"NumCols\")\nThemeList = MTD.FindByName(\"ThemeList\")\nLegTitle = MTD.FindByName(\"LegTitle\")\n\nthelayout = av.GetActiveDoc\nif(theLayout.Is(Layout).Not) then return nil end\nLgraphics = thelayout.GetGraphics\nLgraphics.UnselectAll\nRectOrigin = theLayout.GetDisplay.ReturnUserPoint\n\nFinishButton.SetObjectTag(RectOrigin)\n\nvfl = {}\nfor each d in av.GetProject.GetDocs\n if (d.Is(View)) then\n if (d.GetThemes.Count > 0) then\n vfl.Add(d.GetName)\n end\n end\nend\n\nif (vfl.Count = 0) then\n Msgbox.Info(\"You mus t have at least one view in your project to use this tool\",\"Cannot continue\")\n return nil\nend\nVFrame.DefineFromList(vfl)\nfv = vfl.Get(0)\ntl = {}\nfor each t in av.FindDoc(fv).GetThemes\n if ((t.GetClass.GetClassName = \"BaseMapTheme\") OR (t.GetClass.GetClassName = \"TTheme\") OR (t.GetClass.GetClassName = \"STheme\")) then\n continue\n end\n tl.Add(t.GetName)\nend\nThemeList.DefineFromList(tl)\nLegTitle.SetText(fv)\nMTD.Open\n" ) (Script.203 Name: "Legends.Theme List Update" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nFinishButton = MTD.FindByName(\"LFinish\")\n\nThemeList = MTD.FindByName(\"ThemeList\")\nLegThemes = MTD.FindByName(\"LegThemes\")\n\nIf (Self.GetName = \"ThemeList\") then\n LegThemes.SetSelection(Rect.MakeEmpty,false)\nelse\n ThemeList.SetSelection(Rect.MakeEmpty,false)\nend" ) (Script.204 Name: "Legends.Title Update" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nSelf.SetObjectTag(true)\n\nLegTitle = MTD.FindByName(\"LegTitle\").GetText\n\nTitleFont = MTD.FindByName(\"TitleFont\")\nTitleSize = MTD.FindByName(\"TitleSize\")\nTitleStyle = MTD.FindByName(\"TitleStyle\")\nTitleJustLab = MTD.FindByName(\"TitleJustLab\")\n\nif (LegTitle = \"\") then\n TitleFont.SetEnabled(false)\n TitleSize.SetEnabled(false)\n TitleStyle.SetEnabled(false)\n TitleJustLab.SetEnabled(false)\nelse \n TitleFont.SetEnabled(true)\n TitleSize.SetEnabled(true)\n Titl eStyle.SetEnabled(true)\n TitleJustLab.SetEnabled(true)\nend" ) (Script.205 Name: "Legends.Update Panel" SourceCode: "MTD = av.FindDialog(\"Legends Multi-Column Legend\")\n\nthelayout = av.GetActiveDoc\nif ( Not (theLayout.is(Layout))) then\n Msgbox.Info(\"Please make your layout active again.\",\"Oops\")\n return nil\nend\n\n\nCancelButton = MTD.FindByName(\"LCancel\")\nBackButton = MTD.FindByName(\"LBack\")\nNextButton = MTD.FindByName(\"LNext\")\nFinishButton = MTD.FindByName(\"LFinish\")\nNumCols = MTD.FindByName(\"NumCols\").GetSelection\nVFrame = MTD.FindByName(\"Vname\").GetSelection\ntheView = av.GetProject.FindDoc(VFrame)\ntheThemesToUse = MTD.F indByName(\"LegThemes\").GetList\n\nIntroPanel = MTD.FindByName(\"IntroPanel\")\nThemePanel = MTD.FindByName(\"ThemePanel\")\nTitlePanel = MTD.FindByName(\"TitlePanel\")\nBorderPanel = MTD.FindByName(\"BorderPanel\")\nSymbolPanel = MTD.FindByName(\"SymbolPanel\")\nSpacingPanel = MTD.FindByName(\"SpacingPanel\")\n\nNumCols = MTD.FindByName(\"NumCols\").GetSelection\nXThemes = MTD.FindByName(\"XThemes\")\nLegThemes = MTD.FindByName(\"LegThemes\")\n\npanels = {IntroPanel, ThemePanel, TitlePanel, BorderPanel, SymbolPanel, SpacingPanel}\nTitles = {\"Custom Legend\",\n \"Custom Legend - Step 1 of 5: Basic Settings\",\n \"Custom Legend - Step 2 of 5: Title Settings\",\n \"Custom Legend - Step 3 of 5: Border Settings\",\n \"Custom Legend - Step 4 of 5: Symbol Settings\",\n \"Custom Legend - Step 5 of 5: Spacing Settings\"}\n\nLegTitle = MTD.FindByName(\"LegTitle\")\nif ((LegTitle.GetObjectTag) = false) then\n if ((theThemesToUse.Count = 1) and (Self.GetName = \"LNext\") and (Self.GetLabel = \"Next >>\")) then\n tt = theView.FindT heme(theThemesToUse.Get(0)).GetName\n LegTitle.SetText(tt)\n elseif ((theThemesToUse.Count > 1) and (Self.GetName = \"LNext\") and (Self.GetLabel = \"Next >>\")) then\n LegTitle.SetText(theView.GetName)\n end\nend\n\nif (self.Getname = \"LCancel\") then\n MTD.Close\n l = av.GetActiveDoc\n tl = l.GetGraphics.FindAllByName(\"_Try_It\")\n if (tl <> nil) then\n for each gxd in tl\n l.GetGraphics.RemoveGraphic(gxd)\n end\n end\n NextButton.SetLabel(\"Next >>\")\n NextButton.SetHelp(\"Show the next panel of the Cus tom Legend Wizard\")\n FinishButton.SetLabel(\"Preview\") \n FinishButton.SetHelp(\"Preview the legend using the current settings\") \n if (IntroPanel.IsEnabled.Not) then\n BackButton.SetEnabled(true)\n end\n return nil\nend\n\nif ((NextButton.GetLabel = \"Remove\") and (Self.GetName = \"LNext\")) then\n l = av.GetActiveDoc\n tl = l.GetGraphics.FindAllByName(\"_Try_It\")\n if (tl <> nil) then\n for each gxd in tl\n l.GetGraphics.RemoveGraphic(gxd)\n end\n end\n NextButton.SetLabel(\"Next >>\")\n NextButton.SetHel p(\"Show the next panel of the Custom Legend Wizard\")\n FinishButton.SetLabel(\"Preview\") \n FinishButton.SetHelp(\"Preview the legend using the current settings\") \n if (IntroPanel.IsEnabled.Not) then\n BackButton.SetEnabled(true)\n end\n if(SpacingPanel.IsEnabled) then\n NextButton.SetEnabled(false)\n end\n return nil\nend\n\n\nif (NumCols = \"One per theme\") then\n XThemes.SetEnabled(false)\n MTD.FindByName(\"aTextLabel22\").SetEnabled(false)\nelse\n XThemes.SetEnabled(true)\n MTD.FindByName(\"aTextLabel22\").Set Enabled(true)\nend\n\npCount = 0\npIdx = 0\nfor each p in panels\n if (p.IsEnabled) then\n pIdx = pCount\n end\n pCount = pCount + 1\nend \n\n'Move the current panel out of the way\npanels.Get(pIdx).Move(900,300)\npanels.Get(PIdx).SetEnabled(False)\n\nif (Self.GetName = \"LNext\") then\n pIdx = pIdx + 1\nelseif (Self.Getname = \"LBack\") then\n pIdx = pIdx - 1\nelse\n MTD.Close\nend\n\nFinishButton.SetEnabled(true)\nif (pIdx = 0) then\n BackButton.SetEnabled(false)\n NextButton.SetEnabled(true)\nelse\n BackButton.SetEnabled(tru e)\nend\nif ((pIdx = (panels.Count -1)) or ((pIdx = (1)) and (Self.GetName <> \"LBack\") ) ) then\n NextButton.SetEnabled(false)\n FinishButton.SetEnabled(false)\nelse\n NextButton.SetEnabled(true) \n FinishButton.SetEnabled(True)\nend\n\n if (LegThemes.GetList.Count > 0) then\n NextButton.SetEnabled(true)\n FinishButton.SetEnabled(True)\n else\n if (Pidx <> 0) then\n NextButton.SetEnabled(false)\n else\n NextButton.SetEnabled(true) \n end\n FinishButton.SetEnabled(false)\n end\n\n\n'Move th e requested panel into position\npanels.Get(pIdx).SetEnabled(true)\nif(SpacingPanel.IsEnabled) then\n NextButton.SetEnabled(false)\nend\n\npanels.Get(pIdx).MoveTo(170,18)\nMTD.SetTitle(Titles.Get(pIdx))\n" ) (Script.206 Name: "Legends.Help" SourceCode: "av.Help.SetAVFile \nav.Help.ShowTopic(\"Layout_Advanced_Legend_Tool\") \n" ) (Script.207 Name: "Legends.CanUnload" SourceCode: "return (true)" ) (Script.208 Name: "Legends.Unload" SourceCode: "Dialog.DetachFromExtension(self)" ) (Script.209 Name: "Legends.Install" SourceCode: "if (av.getproject=nil) then return nil end\n\nif(Self.GetPreferences.Get(\"Loaded\") = true) then\n return nil\nend\n\ntheLayoutGUI = av.GetProject.FindGUI(\"Layout\")\nif (theLayoutGUI = nil) then\n listOfLayoutGUIs = av.GetProject.FindGUIsFor(Layout)\n LayoutGUIs2Use = Msgbox.MultiList(listOfLayoutGUIs,\"Choose one or more View document types to add Internet extension interface components to:\",\"Extension Loading\")\nelse\n LayoutGUIs2Use = {theLayoutGUI}\nend\n\n\nfor each LayoutDocGUI in LayoutGUIs2Use\n Tidx = LayoutDoc GUI.GetToolBar.GetControls.Count - 1\n LayoutDocGUI.GetToolBar.Add(Self.Get(0).Clone, Tidx)\n LayoutDocGUI.SetModified(true)\nend\n\nif (LayoutGUIs2Use.Count > 0) then\n Self.GetPreferences.Set(\"Loaded\",true)\n Self.GetPreferences.Set(\"Version\",(3.1))\n av.getproject.setmodified(true)\nend\n\n" ) (Script.210 Name: "Legends.Uninstall" SourceCode: "if (av.GetProject = nil) then\n return nil\nend\n\nif (av.GetProject.IsClosing) then\n return nil\nend\n\nlistOfLayoutGUIs = av.GetProject.FindGUIsFor(Layout)\n\nfor each aDocGUI in (listOfLayoutGUIs)\n c3 = aDocGUI.GetToolBar.FindByScript(\"Legends.Show\")\n if (c3 <> nil) then\n aDocGUI.GetToolBar.Remove(c3)\n end\nend\n\nav.getproject.setmodified(true)\n\n" )