/3.0 (Extension.1 Name: "Labeling" FirstRootClassName: "ToolMenu" Roots: 2 Roots: 9 Roots: 15 Roots: 20 Roots: 21 Roots: 22 Roots: 23 Roots: 24 Roots: 25 Roots: 26 Roots: 27 Version: 30 About: "Contains tools for labeling and adding text to views and layouts." InstallScript: 28 UninstallScript: 29 ExtVersion: 1 ) (ToolMenu.2 InternalName: "avlabel.ViewLabelToolMenu" Help: "Click on a feature and drag in the direction you want the label to appear." Update: "avlabel.GeneralUpdate" Icon: 3 Cursor: "Cursors.Tag" Apply: "avlabel.BlurbLabelTool" Child: 4 Child: 5 Child: 7 ) (AVIcon.3 Name: "blurb.bmp" Data: 4e442049 6d616765 00010012 000f0000 Data: 0348c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6000000 Data: 000000c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 00000000 00000000 Data: 00c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c600 0000c6c6 c6000000 000000c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c60000 Data: 00c6c6c6 c6c6c600 00000000 00c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6000000 Data: 00000000 00000000 00000000 c6c6c6c6 Data: c6c6c6c6 c6000000 00000000 00000000 Data: 00000000 00000000 00000000 00c6c6c6 Data: 0000c6c6 c6000000 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c60000 00c6c6c6 0000c6c6 c6000000 Data: c6c6c600 0000c6c6 c6000000 000000c6 Data: c6c60000 00000000 c6c6c6c6 c6c60000 Data: 00000000 000000c6 c6c60000 00c6c6c6 Data: 0000c6c6 c6000000 c6c6c6c6 c6c60000 Data: 00000000 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 000000c6 c6c60000 00000000 c6c6c6c6 Data: c6c60000 00c6c6c6 0000c6c6 c6000000 Data: c6c6c6c6 c6c60000 00000000 c6c6c6c6 Data: c6c60000 00000000 000000c6 c6c6c6c6 Data: c6000000 000000c6 c6c60000 00c6c6c6 Data: 0000c6c6 c6000000 c6c6c600 00000000 Data: 00c6c6c6 000000c6 c6c60000 00c6c6c6 Data: 000000c6 c6c60000 00000000 000000c6 Data: c6c60000 00c6c6c6 0000c6c6 c6000000 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c60000 00c6c6c6 Data: 0000c6c6 c6000000 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c60000 00c6c6c6 0000c6c6 c6000000 Data: 00000000 00000000 00000000 00000000 Data: 00000000 00000000 00000000 00000000 Data: 00000000 00000000 00000000 00c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 00000000 00000001 Data: 00180007 00200001 00020000 00000000 Data: 0000 ) (Tool.4 Help: "Click on a feature and drag in the direction you want the label to appear." Update: "avlabel.GeneralUpdate" Icon: 3 Cursor: "Cursors.Tag" Apply: "avlabel.BlurbLabelTool" ) (Tool.5 Help: "Click on a feature and drag in the direction you want the label to appear." Update: "avlabel.GeneralUpdate" Icon: 6 Cursor: "Cursors.Tag" Apply: "avlabel.BulletLeaderLabelTool" ) (AVIcon.6 Name: "bltldr.bmp" Data: 4e442049 6d616765 00010012 000f0000 Data: 0348c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6000000 Data: 00000000 0000c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6000000 00000000 0000c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6000000 Data: 00000000 0000c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 000000c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: 00000000 0000c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c600 0000c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c600 0000c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c600 00000000 Data: 00c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c60000 00c6c6c6 000000c6 Data: c6c60000 00c6c6c6 00000000 00000000 Data: 00c6c6c6 00000000 00000000 00c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c60000 Data: 00c6c6c6 00000000 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c60000 00c6c6c6 00000000 Data: 0000c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c600 Data: 00000000 00c6c6c6 00000000 00000000 Data: 00c6c6c6 c6c6c600 00000000 00c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 000000c6 c6c60000 00c6c6c6 Data: 000000c6 c6c60000 00c6c6c6 00000000 Data: 00000000 00c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 00000000 00000001 Data: 00180007 00200001 00020000 00000000 Data: 0000 ) (Tool.7 Help: "Click on a feature you want to label." Update: "avlabel.GeneralUpdate" Icon: 8 Cursor: "Cursors.Tag" Apply: "avlabel.ShadowBoxLabelTool" ) (AVIcon.8 Name: "shdbox.bmp" Data: 4e442049 6d616765 00010012 000f0000 Data: 0348c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: 84848484 84848484 84848484 84848484 Data: 84848484 84848484 84848484 84848484 Data: 84848484 84848484 84848484 84c6c6c6 Data: 0000c6c6 c6000000 00000000 00000000 Data: 00000000 00000000 00000000 00000000 Data: 00000000 00000000 00000000 00000000 Data: 00008484 84c6c6c6 0000c6c6 c6000000 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c600 00008484 84c6c6c6 Data: 0000c6c6 c6000000 c6c6c600 0000c6c6 Data: c6000000 c6c6c600 00000000 00000000 Data: c6c6c600 00000000 00000000 c6c6c600 Data: 00008484 84c6c6c6 0000c6c6 c6000000 Data: c6c6c600 00000000 00c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6000000 c6c6c600 00000000 Data: 00c6c6c6 c6c6c600 00008484 84c6c6c6 Data: 0000c6c6 c6000000 c6c6c6c6 c6c60000 Data: 00000000 c6c6c600 00000000 00000000 Data: c6c6c6c6 c6c60000 00000000 c6c6c600 Data: 00008484 84c6c6c6 0000c6c6 c6000000 Data: c6c6c600 0000c6c6 c6000000 c6c6c600 Data: 0000c6c6 c6000000 c6c6c600 00000000 Data: 00000000 c6c6c600 00008484 84c6c6c6 Data: 0000c6c6 c6000000 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c600 Data: 00008484 84c6c6c6 0000c6c6 c6000000 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c600 00008484 84c6c6c6 Data: 0000c6c6 c6000000 00000000 00000000 Data: 00000000 00000000 00000000 00000000 Data: 00000000 00000000 00000000 00000000 Data: 0000c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 00000000 00000001 Data: 00180007 00200001 00020000 00000000 Data: 0000 ) (ToolMenu.9 InternalName: "avlabel.ViewTextToolMenu" Help: "Click and Drag to where you want your text to appear, then enter the text." Update: "View.GraphicToolUpdate" Icon: 3 Cursor: "Cursors.Bullseye" Apply: "avlabel.BlurbTextTool" Click: "SymWin.DisplayFontPanel" Child: 10 Child: 11 Child: 12 Child: 13 ) (Tool.10 Help: "Click and Drag to where you want your text to appear, then enter the text." Update: "View.GraphicToolUpdate" Icon: 3 Cursor: "Cursors.Bullseye" Apply: "avlabel.BlurbTextTool" Click: "SymWin.DisplayFontPanel" ) (Tool.11 Help: "Click and Drag to where you want your text to appear, then enter the text." Update: "View.GraphicToolUpdate" Icon: 6 Cursor: "Cursors.Bullseye" Apply: "avlabel.BulletLeaderTextTool" Click: "SymWin.DisplayFontPanel" ) (Tool.12 Help: "Click where you want your label to appear and enter your text." Update: "View.GraphicToolUpdate" Icon: 8 Cursor: "Cursors.Target" Apply: "avlabel.ShadowBoxTextTool" Click: "SymWin.DisplayFontPanel" ) (Tool.13 Help: "Click where you want your label to appear and enter your text." Update: "View.GraphicToolUpdate" Icon: 14 Cursor: "Cursors.Target" Apply: "avlabel.CreateDropShadowText" Click: "SymWin.DisplayFontPanel" ) (AVIcon.14 Name: "shdtxt.bmp" Data: 4e442049 6d616765 00010012 000f0000 Data: 0348c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 00000084 8484c6c6 Data: c6c6c6c6 00000084 8484c6c6 c6000000 Data: 00000084 8484c6c6 c6000000 00000000 Data: 00000000 00848484 0000c6c6 c6c6c6c6 Data: 00000000 00008484 84000000 00000084 Data: 84840000 00000000 00000000 00008484 Data: 84000000 848484c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c600 00008484 Data: 84000000 848484c6 c6c60000 00848484 Data: c6c6c600 00008484 84000000 848484c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c600 00000000 00000000 848484c6 Data: c6c6c6c6 c6c6c6c6 c6c6c600 00008484 Data: 84000000 00000084 8484c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c60000 Data: 00848484 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c600 00008484 84c6c6c6 00000084 Data: 84848484 84c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c60000 00848484 c6c6c6c6 Data: c6c6c6c6 c6000000 00000000 00008484 Data: 84c6c6c6 00000000 00008484 84848484 Data: 0000c6c6 c6c6c6c6 c6c6c600 00000000 Data: 00000000 c6c6c6c6 c6c60000 00848484 Data: c6c6c600 00008484 84c6c6c6 c6c6c600 Data: 00000000 00848484 0000c6c6 c6c6c6c6 Data: c6c6c600 00008484 84000000 848484c6 Data: c6c60000 00848484 c6c6c600 00008484 Data: 84c6c6c6 c6c6c6c6 c6c60000 00848484 Data: 0000c6c6 c6c6c6c6 00000000 00008484 Data: 84000000 00000084 84840000 00848484 Data: c6c6c600 00008484 84c6c6c6 c6c6c6c6 Data: c6c60000 00848484 0000c6c6 c6c6c6c6 Data: 00000084 8484c6c6 c6c6c6c6 00000084 Data: 84840000 00848484 c6c6c600 00008484 Data: 84000000 00000000 00000000 00848484 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 0000c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: 0000c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 c6c6c6c6 c6c6c6c6 Data: c6c6c6c6 c6c6c6c6 00000000 00000001 Data: 00180007 00200001 00020000 00000000 Data: 0000 ) (ToolMenu.15 InternalName: "avlabel.LayoutTextTool" Help: "Draws text with a box and leader around it." Icon: 3 Cursor: "Cursors.Bullseye" Apply: "avlabel.BlurbTextTool" Click: "SymWin.DisplayFontPanel" Child: 16 Child: 17 Child: 18 Child: 19 ) (Tool.16 Help: "Draws text with a box and leader around it." Icon: 3 Cursor: "Cursors.Bullseye" Apply: "avlabel.BlurbTextTool" Click: "SymWin.DisplayFontPanel" ) (Tool.17 Help: "Draws text with a bullet and leader" Icon: 6 Cursor: "Cursors.Bullseye" Apply: "avlabel.BulletLeaderTextTool" Click: "SymWin.DisplayFontPanel" ) (Tool.18 Help: "Creates text with a box and shadow around it" Icon: 8 Cursor: "Cursors.Target" Apply: "avlabel.ShadowBoxTextTool" Click: "SymWin.DisplayFontPanel" ) (Tool.19 Help: "Creates text where each letter has a drop-shadow." Icon: 14 Cursor: "Cursors.Target" Apply: "avlabel.CreateDropShadowText" Click: "SymWin.DisplayFontPanel" ) (Script.20 Name: "avlabel.BlurbLabelTool" SourceCode: "' Name: BlurbLabelTool\n' \n' Headline: Makes label blurbs with leader, outline, and shadow using the value of the\n' feature of the active theme(s).\n' \n' Self:\n' \n' Returns:\n' \n' Description: This script should be used in view document GUI as a tool. Use this \n' script as the Apply Event Use the Symbolwin.DisplayFontPanel script as the click event. \n' When using this tool, click on the feature you want to make a label for and drag in the \n' direction you want your descriptive text to be place d. Additionally, you may define\n' your text, foreground, and background colors by pressing and holding down the Shift\n' key while you click and drag; you will be prompted via a series of messageboxes as to\n' which colors to use. \n' \n' The label that is returned is a graphic group. You may select this group and then use\n' the symbol window to change its colors. Foreground only changes the foreground color, \n' background only changes the background color, the outline changes the outline color, and\n' text changes the text color.\n' \n' Topics: Views, Symbols, Graphics\n' \n' Search Keys: Labeling, Text\n' \n' Requires: There must be a view or layout document active.\n' \n' History: ESRI ArcView 3.0\n\ncbox=NIL\ntheView = av.GetActiveDoc\n\nif (theView.GetGraphics.EditText.Not) then\n\n ul = theView.ReturnUserLine\n if (ul.IsNull) then return nil end\n\n if (System.IsShiftKeyDown) then\n shiftcheck=TRUE\n else\n shiftcheck=FALSE\n end\n pt1 = ul.ReturnStart\n pt2 = ul.ReturnEnd\n t = GraphicText.Make(\"\" , pt2)\n t.SetDisplay(theView.GetDisplay)\n theView.GetDisplay.HookUpSymbol(t.GetSymbol)\n theView.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n \n blurbstring = \"\"\n DoneThis = 0\n for each athm in theView.GetActiveThemes\n thelabelfield=athm.getlabelfield\n if(athm.CanSelect) then\n ListofFound = athm.FindByPoint(pt1)\n else\n return nil\n end\n if (ListofFound.Count = 0) then return nil end\n for each Found in ListofFound\n if (DoneThis > 0) then\n blurbstring = blurbstrin g + nl\n end\n blurbstring = blurbstring + athm.GetFTab.ReturnValueString(thelabelfield, Found)\n DoneThis = DoneThis + 1\n end\n end\n t.SetText(blurbstring)\n if (t.gettext.count < 1) then return nil end\n \n dg = Color.Make\n dg.SetRGBList({100,100,100})\n bgbc = dg\n fgbc = Color.GetWhite\n tc = Color.GetBlack\n \n ' Test if shift is down, if it is then use custom colors\n \n if (shiftcheck) then\n ColorDict = Dictionary.Make(10)\n ColorDict.Add(\"White\",{255,255,255})\n ColorDict .Add(\"Black\",{0,0,0})\n ColorDict.Add(\"Red\",{255,0,0})\n ColorDict.Add(\"Yellow\",{255,255,0})\n ColorDict.Add(\"Green\",{0,255,0})\n ColorDict.Add(\"Blue\",{0,0,255})\n ColorDict.Add(\"Purple\",{255,0,255})\n ColorDict.Add(\"Cyan\",{0,255,255})\n ColorDict.Add(\"Gray\",{100,100,100})\n colorDict.add(\"Pale Yellow\",{252,252,203})\n \n 'Make a List of the color names\n \n cs={\"Black\",\"White\",\"Gray\",\"Red\",\"Green\",\"Blue\",\"Cyan\",\"Yellow\",\"Pale Yellow\",\"Purple\"}\n \n 'Get the text color\n \n t cs = Msgbox.ChoiceAsString(cs,\"Choose a Text Color\",\"Text Color\")\n \n if (tcs=NIL) then return nil end\n \n 'Reorder selection to make more sense here\n \n cs={\"Pale Yellow\",\"White\",\"Black\",\"Gray\",\"Red\",\"Green\",\"Blue\",\"Cyan\",\"Yellow\",\"Purple\"}\n \n 'Get the foreground color\n \n fgs = Msgbox.ChoiceAsString(cs,\"Choose a Box Color\",\"Text Color\")\n \n if (fgs=NIL) then return nil end\n \n 'Reorder selection to make more sense here\n \n cs={\"Gray\",\"White\",\"Black\",\"Red\",\"Green\",\" Blue\",\"Cyan\",\"Yellow\",\"Pale Yellow\",\"Purple\"}\n \n 'Get the shading color\n \n bgs = Msgbox.ChoiceAsString(cs,\"Choose a Shade Color\",\"Text Color\")\n \n if (bgs=NIL) then return nil end\n \n bgbc = Color.Make\n fgbc = Color.Make\n tc = Color.Make\n \n 'Make the colors\n \n bgbc.SetRGBList(ColorDict.Get(bgs))\n fgbc.SetRGBList(ColorDict.Get(fgs))\n tc.SetRGBList(ColorDict.Get(tcs))\n end\n \n 'Determine which side of leader to position box\n \n if ((pt1.GetX <= pt2.GetX) and (pt1.GetY <= pt2.GetY)) then \n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n theView.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.08)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n 'Where to place the leader...\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n llo = (boxoriginx@(boxoriginy + (bh*0.31)))\n o = (boxoriginx@boxoriginy)\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = (boxoriginx@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(llo),(o),(lr),(ur),(ul),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = (boxoriginx@boxoriginy)\n llo = ((boxoriginx + (bw/6))@boxoriginy)\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxori ginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + ((bw/6)*2))@(boxoriginy))\n cbox = Polygon.Make({{(pt1),(llo),(o),(ul),(ur),(lr),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n elseif ((pt1.GetX >= pt2.GetX) and (pt1.GetY <= pt2.GetY)) then \n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n ntx = t.GetBounds.GetWidth\n t.SetOrigin(((t.GetOrigin.GetX - ntx)@t.GetOrigin.GetY))\n theVie w.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.05)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n o = (boxoriginx@boxoriginy)\n llo = ((boxoriginx + bw)@(boxoriginy + (bh*0.31)))\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + bw)@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(o),(ul),(ur),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = (boxoriginx@boxoriginy)\n llo = ((boxoriginx + ((bw/6)*5))@boxoriginy)\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + ((bw/6)*4))@( boxoriginy))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(ur),(ul),(o),(rlo)}}) \n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n elseif ((pt1.GetX <= pt2.GetX) and (pt1.GetY > pt2.GetY)) then\n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n ntx = t.GetBounds.GetHeight\n t.SetOrigin((t.GetOrigin.GetX@(t.GetOrigin.GetY - ntx)))\n theView.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOri gin.GetY\n bw = ((bb.GetWidth) * 1.05)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n o = ((boxoriginx )@(boxoriginy))\n ull = ((boxoriginx)@(boxoriginy + (bh*0.31)))\n lr = ((boxoriginx + bw)@(boxoriginy))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n ul = ((boxoriginx)@(boxoriginy + bh))\n rlo = ((boxoriginx)@(boxoriginy + (bh/2)))\n cbox = Poly gon.Make({{(pt1),(ull),(o),(lr),(ur),(ul),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = ((boxoriginx )@(boxoriginy))\n ull = ((boxoriginx + (bw/12))@(boxoriginy+bh))\n ul = ((boxoriginx )@(boxoriginy+bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n ll = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + ((bw/12)*2))@(boxoriginy + bh))\n cbox = Polygon.Make({{(pt1),(ull),(ul),(o),(ll),(ur),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n elseif ((pt1.GetX > pt2.GetX) and (pt1.GetY > pt2.GetY)) then\n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n ntx = t.GetBounds.GetWidth\n t.SetOrigin(((t.GetOrigin.GetX - ntx)@t.GetOrigin.GetY))\n theView.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.05)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n o = ((boxoriginx)@(boxoriginy))\n llo = ((boxoriginx + bw)@(boxoriginy + (bh*0.31)))\n ul = ((boxoriginx)@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@(boxoriginy))\n rlo = ((boxoriginx + bw)@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(o),(ul),(ur),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxo riginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = ((boxoriginx + bw)@(boxoriginy + bh))\n llo = ((boxoriginx + ((bw/12)*10))@(boxoriginy + bh))\n ul = ((boxoriginx + bw)@(boxoriginy))\n ur = ((boxoriginx)@(boxoriginy))\n lr = ((boxoriginx)@(boxoriginy + bh))\n rlo = ((boxoriginx + ((bw/12)*11))@(boxoriginy + bh))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(ur),(ul),(o),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n end\nend\n\nNumLines = t.GetText.AsTokens(nl).Count\nif (NumLines > 1) then\n NumLines = 2\nend\nBgRect = t.GetBounds.Clone \nCurrentWidth = BgRect.GetWidth \nCurrentHeight = BgRect.GetHeight\nBgO = BgRect.ReturnOrigin\nadjustment = ((CurrentWidth*(-(0.05)))@( (CurrentHeight*(-(0.05*((NumLines*NumLines)*0.9))))/(2)))\nt.GetBounds.SetOrigin(BgO + adjustment)\n\n'do foreground box color\n\ncboxgs = GraphicShape.Make(cbox)\nfs = RasterFill.Make\nfs.SetStyle(#RASTERFILL_STYLE_SOLID)\nfs.SetColor(fgbc)\ncboxgs.SetSymbol(f s)\n\n'Do Background box color\n\nbbox = GraphicShape.Make(cbox)\nbs = RasterFill.Make\nbs.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\nbs.SetOutLined(FALSE)\nbs.SetColor(bgbc)\nbbox.SetSymbol(bs)\nbbo = bbox.GetOrigin\nbbb = bbox.GetBounds\nbxm = (bbb.GetWidth)/50\nbxo = (bbo.GetX) + bxm + (bxm * 0.5)\nbyo = (bbo.GetY) - bxm + (bxm * 0.2)\nbbox.SetOrigin((bxo@byo))\ntheshape=bbox.getshape\nk=theshape.snap(pt1,bxm*2.5)\nchangebox=Graphicshape.make(theshape)\nbs.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\nbgbg = color.Make\nbgbg.Se tTransparent(true)\nbs.SetColor(bgbg)\nbs.SetBGColor(bgbc)\nbs.SetOutLined(FALSE)\nchangebox.setsymbol(bs) \ntheView.GetGraphics.Add(changebox) 'background\ntheView.GetGraphics.Add(cboxgs) 'foreground\n\n'Position the graphics and then group them\n\nbbox.SetSelected(false)\ncboxgs.SetSelected(false)\nt.SetSelected(true)\ntheView.GetGraphics.MoveSelectedToFront\nchangebox.setselected(true) 'background\ncboxgs.SetSelected(true) 'foreground\ntheView.GetGraphics.GroupSelected\ntheView.GetGr aphics.GetSelected.Get(0).Invalidate\ntheView.GetGraphics.UnselectAll\n\n\n\n\n\n\n\n" ) (Script.21 Name: "avlabel.BlurbTextTool" SourceCode: "' Name: BlurbTextTool\n' \n' Headline: Makes label blurbs with leader, outline, and shadow with text you enter\n' using the text tool\n' \n' Self:\n' \n' Returns:\n' \n' Description: This script can either be used in the layout or view document GUIs as\n' a tool. Use this script as the Apply Event Use the Symbolwin.DisplayFontPanel script \n' as the click event. When using this tool, click on the feature you want to make a \n' label for and drag in the direction you want your descriptive text to be pla ced. The\n' text tool will be opened and you can enter your text. Additionally, you may define\n' your text, foreground, and background colors by pressing and holding down the Shift\n' key while you click and drag; you will be prompted via a series of messageboxes as to\n' which colors to use. \n' \n' The label that is returned is a graphic group. You may select this group and then use\n' the symbol window to change its colors. Foreground only changes the foreground color, \n' background only changes th e background color, the outline changes the outline color, and\n' text changes the text color.\n' \n' Topics: Views, Layouts, Symbols, Graphics\n' \n' Search Keys: Labeling, Text\n' \n' Requires: There must be a view or layout document active.\n' \n' History: ESRI ArcView 3.0\n\ncbox=NIL\ntheLayout = av.GetActiveDoc\n\nif (theLayout.GetGraphics.EditText.Not) then\n\n 'do it slightly differently if using a view document.\n\n if (theLayout.Is(Layout)) then\n ul = theLayout.GetDisplay.ReturnUserLine\n elseif (the Layout.Is(View)) then\n ul = theLayout.ReturnUserLine\n end\n if (ul.IsNull) then return nil end\n \n 'Test if shift is down, if it is then use custom colors \n if (System.IsShiftKeyDown) then\n shiftcheck=TRUE\n else\n shiftcheck=FALSE\n end\n \n pt1 = ul.ReturnStart\n pt2 = ul.ReturnEnd\n t = GraphicText.Make(\"\", pt2)\n t.SetDisplay(theLayout.GetDisplay)\n theLayout.GetDisplay.HookUpSymbol(t.GetSymbol)\n theLayout.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n \n if ((t.EditText).not) then return nil end \n if (t.GetText.Count < 1) then return nil end\n \n dg = Color.Make\n dg.SetRGBList({100,100,100}) 'This is the gray for the default background\n bgbc = dg\n fgbc = Color.GetWhite\n tc = Color.GetBlack\n \n if (shiftcheck) then\n ColorDict = Dictionary.Make(10)\n ColorDict.Add(\"White\",{255,255,255})\n ColorDict.Add(\"Black\",{0,0,0})\n ColorDict.Add(\"Red\",{255,0,0})\n ColorDict.Add(\"Yellow\",{255,255,0})\n ColorDict.Add(\"Green\",{0,255,0})\n ColorDict.Add(\"Blue\",{0,0,255})\n ColorDi ct.Add(\"Purple\",{255,0,255})\n ColorDict.Add(\"Cyan\",{0,255,255})\n ColorDict.Add(\"Gray\",{100,100,100})\n colorDict.add(\"Pale Yellow\",{252,252,203})\n \n 'Make a List of the color names\n \n cs={\"Black\",\"White\",\"Gray\",\"Red\",\"Green\",\"Blue\",\"Cyan\",\"Yellow\",\"Pale Yellow\",\"Purple\"}\n \n 'Get the text color\n \n tcs = Msgbox.ChoiceAsString(cs,\"Choose a Text Color\",\"Text Color\")\n \n if (tcs=NIL) then return nil end\n \n 'Reorder selection to make more sense here\n \n cs={\"Pale Ye llow\",\"White\",\"Black\",\"Gray\",\"Red\",\"Green\",\"Blue\",\"Cyan\",\"Yellow\",\"Purple\"}\n \n 'Get the foreground color\n \n fgs = Msgbox.ChoiceAsString(cs,\"Choose a Box Color\",\"Text Color\")\n \n if (fgs=NIL) then return nil end\n \n 'Reorder selection to make more sense here\n \n cs={\"Gray\",\"White\",\"Black\",\"Red\",\"Green\",\"Blue\",\"Cyan\",\"Yellow\",\"Pale Yellow\",\"Purple\"}\n \n 'Get the shading color\n \n bgs = Msgbox.ChoiceAsString(cs,\"Choose a Shade Color\",\"Text Color\")\n \n if (bgs=NIL) then return nil end\n \n bgbc = Color.Make\n fgbc = Color.Make\n tc = Color.Make\n \n 'Make the colors\n \n bgbc.SetRGBList(ColorDict.Get(bgs))\n fgbc.SetRGBList(ColorDict.Get(fgs))\n tc.SetRGBList(ColorDict.Get(tcs))\n end\n \n 'Determine which side of leader to position box\n \n if ((pt1.GetX <= pt2.GetX) and (pt1.GetY <= pt2.GetY)) then \n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n theLayout.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX \n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.08)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n 'Where to place the leader...\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n llo = (boxoriginx@(boxoriginy + (bh*0.31)))\n o = (boxoriginx@boxoriginy)\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = (boxori ginx@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(llo),(o),(lr),(ur),(ul),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = (boxoriginx@boxoriginy)\n llo = ((boxoriginx + (bw/6))@boxoriginy)\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + ((bw/6)*2))@(boxoriginy))\n cbox = Polygon.Make({{(pt1),(llo),(o),(ul),(ur), (lr),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n elseif ((pt1.GetX >= pt2.GetX) and (pt1.GetY <= pt2.GetY)) then \n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n ntx = t.GetBounds.GetWidth\n t.SetOrigin(((t.GetOrigin.GetX - ntx)@t.GetOrigin.GetY))\n theLayout.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.05)\n bh = ((bb.GetHeight) * 1. 1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n o = (boxoriginx@boxoriginy)\n llo = ((boxoriginx + bw)@(boxoriginy + (bh*0.31)))\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + bw)@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(o),(ul),(ur),(rlo)}})\n BgRect = Rec t.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = (boxoriginx@boxoriginy)\n llo = ((boxoriginx + ((bw/6)*5))@boxoriginy)\n ul = (boxoriginx@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + ((bw/6)*4))@(boxoriginy))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(ur),(ul),(o),(rlo)}}) \n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n elseif ((pt1.GetX <= pt2.GetX) and (pt1.GetY > pt2.GetY)) then\n z=t.getsymbol\n z.SetColor(tc)\n t.SetSymbol(z)\n ntx = t.GetBounds.GetHeight\n t.SetOrigin((t.GetOrigin.GetX@(t.GetOrigin.GetY - ntx)))\n theLayout.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.05)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n if ((pt1.GetY >= (pt2.GetY - bh )) and (pt1.GetY <= (pt2.GetY + bh))) then\n o = ((boxoriginx )@(boxoriginy))\n ull = ((boxoriginx)@(boxoriginy + (bh*0.31)))\n lr = ((boxoriginx + bw)@(boxoriginy))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n ul = ((boxoriginx)@(boxoriginy + bh))\n rlo = ((boxoriginx)@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(ull),(o),(lr),(ur),(ul),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = ((boxoriginx )@(box originy))\n ull = ((boxoriginx + (bw/12))@(boxoriginy+bh))\n ul = ((boxoriginx )@(boxoriginy+bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n ll = ((boxoriginx + bw)@boxoriginy)\n rlo = ((boxoriginx + ((bw/12)*2))@(boxoriginy + bh))\n cbox = Polygon.Make({{(pt1),(ull),(ul),(o),(ll),(ur),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n elseif ((pt1.GetX > pt2.GetX) and (pt1.GetY > pt2.GetY)) then\n z=t.getsymbol\n z.SetCol or(tc)\n t.SetSymbol(z)\n ntx = t.GetBounds.GetWidth\n t.SetOrigin(((t.GetOrigin.GetX - ntx)@t.GetOrigin.GetY))\n theLayout.GetGraphics.AddName(t)\n bb = t.GetBounds.Clone\n bo_x = bb.ReturnOrigin.GetX\n bo_y = bb.ReturnOrigin.GetY\n bw = ((bb.GetWidth) * 1.05)\n bh = ((bb.GetHeight) * 1.1)\n boxoriginx = bo_x - (bw / 10)\n boxoriginy = bo_y - (bh / 5)\n if ((pt1.GetY >= (pt2.GetY - bh)) and (pt1.GetY <= (pt2.GetY + bh))) then\n o = ((boxoriginx)@(boxoriginy))\n llo = ((boxor iginx + bw)@(boxoriginy + (bh*0.31)))\n ul = ((boxoriginx)@(boxoriginy + bh))\n ur = ((boxoriginx + bw)@(boxoriginy + bh))\n lr = ((boxoriginx + bw)@(boxoriginy))\n rlo = ((boxoriginx + bw)@(boxoriginy + (bh/2)))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(o),(ul),(ur),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n else\n o = ((boxoriginx + bw)@(boxoriginy + bh))\n llo = ((boxoriginx + ((bw/12)*10))@(boxoriginy + bh))\n ul = ( (boxoriginx + bw)@(boxoriginy))\n ur = ((boxoriginx)@(boxoriginy))\n lr = ((boxoriginx)@(boxoriginy + bh))\n rlo = ((boxoriginx + ((bw/12)*11))@(boxoriginy + bh))\n cbox = Polygon.Make({{(pt1),(llo),(lr),(ur),(ul),(o),(rlo)}})\n BgRect = Rect.MakeXY(boxoriginx,boxoriginy,(boxoriginx + bw),(boxoriginy + bh))\n end\n end\nend\n\nNumLines = t.GetText.AsTokens(nl).Count\nif (NumLines > 1) then\n NumLines = 2\nend\nBgRect = t.GetBounds.Clone \nCurrentWidth = BgRect.GetWidth \nCurrentHeight = BgRect.GetHeight\nBgO = BgRect.ReturnOrigin\nadjustment = ((CurrentWidth*(-(0.05)))@( (CurrentHeight*(-(0.05*((NumLines*NumLines)*0.9))))/(2)))\nt.GetBounds.SetOrigin(BgO + adjustment)\n\n'do foreground box color\n\ncboxgs = GraphicShape.Make(cbox)\nfs = RasterFill.Make\nfs.SetStyle(#RASTERFILL_STYLE_SOLID)\nfs.SetColor(fgbc)\ncboxgs.SetSymbol(fs)\n\n'Do Background box color\n\nbbox = GraphicShape.Make(cbox)\nbs = RasterFill.Make\nbs.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\nbs.SetOutLined(FALSE)\nbs.SetColor(bgbc)\nbbox.S etSymbol(bs)\nbbo = bbox.GetOrigin\nbbb = bbox.GetBounds\nbxm = (bbb.GetWidth)/50\nbxo = (bbo.GetX) + bxm + (bxm * 0.5)\nbyo = (bbo.GetY) - bxm + (bxm * 0.2)\nbbox.SetOrigin((bxo@byo))\ntheshape=bbox.getshape\nk=theshape.snap(pt1,bxm*2.5)\nchangebox=Graphicshape.make(theshape)\nbs.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\nbgbg = color.Make\nbgbg.SetTransparent(true)\nbs.SetColor(bgbg)\nbs.SetBGColor(bgbc)\nbs.SetOutLined(FALSE)\nchangebox.setsymbol(bs) \ntheLayout.GetGraphics.Add(changebox) 'background\ntheLayout.GetGrap hics.Add(cboxgs) 'foreground\n\n'Position the graphics and then group them\n\nbbox.SetSelected(false)\ncboxgs.SetSelected(false)\nt.SetSelected(true)\ntheLayout.GetGraphics.MoveSelectedToFront\nchangebox.setselected(true) 'background\ncboxgs.SetSelected(true) 'foreground\ntheLayout.GetGraphics.GroupSelected\ntheLayout.GetGraphics.GetSelected.Get(0).Invalidate\ntheLayout.GetGraphics.UnselectAll\n\n\n\n\n\n\n\n\n" ) (Script.22 Name: "avlabel.BulletLeaderTextTool" SourceCode: "' Name: BulletLeaderTextTool\n' \n' Headline: Makes label blurbs with dot leader and background with optional outline. \n' \n' Self:\n' \n' Returns:\n' \n' Description: This script can either be used in the layout or view document GUIs as\n' a tool. Use this script as the Apply Event Use the Symbolwin.DisplayFontPanel script \n' as the click event. When using this tool, click on the feature you want to make a \n' label for and drag in the direction you want your descriptive text to be placed. The\n' text tool will be opened and you can enter your text. Optionally, you may hold the\n' shift key down to cause an outline to be drawn around the label text. \n' \n' The label that is returned is a graphic group. You may select this group and then use\n' the symbol window to change its colors. Foreground only changes the dot and leader color, \n' and text changes the text color.\n' \n' Topics: Views, Layouts, Symbols, Graphics\n' \n' Search Keys: Labeling, Text\n' \n' Requires: There must be a view or la yout document active.\n' \n' History: ESRI ArcView 3.0\n\ncbox=NIL\ntheDoc = av.GetActiveDoc\n\nif (theDoc.GetGraphics.EditText.Not) then\n\n 'do it slightly differently if using a view document.\n\n if (theDoc.Is(Layout)) then\n ul = theDoc.GetDisplay.ReturnUserLine\n elseif (theDoc.Is(View)) then\n ul = theDoc.ReturnUserLine\n end\n \n if (ul.IsNull) then return nil end\n \n if (System.IsShiftKeyDown) then\n IsOutLined = true\n HasBox = true\n else\n IsOutLined = false\n HasBox = false\n end\n\n pt1 = ul.ReturnStart\n pt2 = ul.ReturnEnd\n t = GraphicText.Make(\"\", pt2)\n t.SetDisplay(theDoc.GetDisplay)\n theDoc.GetDisplay.HookUpSymbol(t.GetSymbol)\n theDoc.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n \n if ((t.EditText).not) then\n return nil\n end \n \n if (t.gettext.count < 1) then return nil end\n \n fgbc = Color.GetWhite\n tc = Color.GetBlack\n \n BulletSymbol = av.GetSymbolWin.GetPalette.GetList(#PALETTE_LIST_MARKER).Get(0)\n BulletSymbol.Setsize(3)\n BulletSymbol.SetColor(Color.GetBlack)\n gb = GraphicShape.Make(pt1)\n gb.SetSymbol(BulletSymbol)\n \n LeaderPen = BasicPen.Make\n LeaderPen.SetColor(Color.GetBlack)\n LeaderPen.SetSize(0.25)\n gl = GraphicShape.Make(ul)\n gl.SetSymbol(LeaderPen)\n \n BgFill = Rasterfill.Make\n BgFill.SetStyle(#RASTERFILL_STYLE_SOLID)\n BgFill.SetColor(Color.GetWhite) 'Set the background color here!!\n if (IsOutLined) then\n BgFill.SetOutlined(true)\n BgFill.SetOLColor(Color.GetBlack)\n BgFill.SetOLWidth(0.25)\n else\n BgFill.SetOutLined (false)\n end\n \n 'Determine which side of leader to position box\n \n if (((pt1.GetX <= pt2.GetX) and (pt1.GetY <= pt2.GetY)) or \n ((pt1.GetX <= pt2.GetX) and (pt1.GetY > pt2.GetY))) then\n \n 'Adjust Text Position with respect to end of leader line\n XAdjustmentDistance = (t.GetBounds.GetHeight)/2\n t.GetBounds.Move(0,-XAdjustmentDistance)\n BgRect = t.GetBounds.Clone 'This becomes background Rect\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidth * 1.05\n YNewSize = CurrentHeight * 1.1\n BgRect.SetSize(XNewSize@YNewSize)\n tbg = GraphicShape.Make(BgRect)\n tbg.SetSymbol(BgFill) \n BgCenterX = BgRect.ReturnCenter.GetX\n BgCenterY = BgRect.ReturnCenter.GetY\n TxtXOMove = CurrentWidth/2\n TxtYOMOve = CurrentHeight/2\n if (theDoc.Is(Layout)) then\n FontSizeAdjustment = (t.ReturnSymbols.Get(0).GetSize)/(5*72)\n else\n FontSizeAdjustment = (CurrentHeight - t.GetBounds.GetHeight)/1.6\n end \n NewTextOrigin X = BgCenterX - TxtXOMove\n NewTextOriginY = BgCenterY - TxtYOMove + FontSizeAdjustment\n t.GetBounds.SetOrigin(NewTextOriginX@NewTextOriginY)\n \n elseif (((pt1.GetX >= pt2.GetX) and (pt1.GetY <= pt2.GetY)) or\n ((pt1.GetX > pt2.GetX) and (pt1.GetY > pt2.GetY))) then \n \n 'Adjust Text Position with respect to end of leader line\n XAdjustmentDistance = (t.GetBounds.GetHeight)/2\n t.GetBounds.Move(0,-XAdjustmentDistance)\n BgRect = t.GetBounds.Clone 'This becomes background Re ct\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidth * 1.05\n YNewSize = CurrentHeight * 1.1\n BgRect.SetSize(XNewSize@YNewSize)\n BgRect.Move(-(BgRect.GetWidth),0)\n tbg = GraphicShape.Make(BgRect)\n tbg.SetSymbol(BgFill) \n 'Centering Routine\n BgCenterX = BgRect.ReturnCenter.GetX\n BgCenterY = BgRect.ReturnCenter.GetY\n TxtXOMove = CurrentWidth/2\n TxtYOMOve = CurrentHeight/2\n if (theDoc.Is(Layout)) then\n FontSizeAdjustment = (t.ReturnSymbols.Get(0).GetSize)/(5*72)\n else\n FontSizeAdjustment = (CurrentHeight - t.GetBounds.GetHeight)/1.6\n end \n NewTextOriginX = BgCenterX - TxtXOMove\n NewTextOriginY = BgCenterY - TxtYOMove + FontSizeAdjustment\n t.GetBounds.SetOrigin(NewTextOriginX@NewTextOriginY)\n\n end\n\n\n'Exactly center text within the background box\n\n \nend\n\nif (HasBox) then\n theDoc.GetGraphics.Add(tbg)\nend\ntheDoc.GetGraphics.Add(gb)\ntheDoc.GetGraphics.Add(gl)\ntheDoc.GetGraphics.Add(t)\n\ngb.SetSelected(false )\ngl.SetSelected(false)\ntbg.SetSelected(false)\nt.SetSelected(true)\ntheDoc.GetGraphics.MoveSelectedToFront\ngl.setselected(true)\ngb.SetSelected(true)\ntbg.SetSelected(true)\ntheDoc.GetGraphics.GroupSelected\ntheDoc.GetGraphics.GetSelected.Get(0).Invalidate\ntheDoc.GetGraphics.UnselectAll\n\n\n\n\n\n" ) (Script.23 Name: "avlabel.BulletLeaderLabelTool" SourceCode: "' Name: BulletLeaderLabelTool\n' \n' Headline: Makes label blurbs with dot leader and background with optional outline. \n' \n' Self:\n' \n' Returns:\n' \n' Description: This script should be used in the view document GUI as a tool. Use this \n' script as the Apply Event. Use the Symbolwin.DisplayFontPanel script as the click event. \n' When using this tool, click on the feature you want to make a label for and drag in the \n' direction you want your descriptive text to be placed. Optionally, you ma y hold the\n' shift key down to cause a box to be drawn around the label text. \n' \n' The label that is returned is a graphic group. You may select this group and then use\n' the symbol window to change its colors. Foreground only changes the dot and leader color, \n' and text changes the text color.\n' \n' Topics: Views, Symbols, Graphics\n' \n' Search Keys: Labeling, Text\n' \n' Requires: There must be a view or layout document active.\n' \n' History: ESRI ArcView 3.0\n\ncbox=NIL\ntheDoc = av.GetActive Doc\n\nif (theDoc.GetGraphics.EditText.Not) then\n\n ul = theDoc.ReturnUserLine\n if (ul.IsNull) then return nil end\n \n if (System.IsShiftKeyDown) then\n IsOutLined = true\n HasBox = true\n else\n IsOutLined = false\n HasBox = false\n end\n\n pt1 = ul.ReturnStart\n pt2 = ul.ReturnEnd\n t = GraphicText.Make(\"\", pt2)\n t.SetDisplay(theDoc.GetDisplay)\n theDoc.GetDisplay.HookUpSymbol(t.GetSymbol)\n theDoc.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n \n blurbstring = \"\"\n DoneThis = 0\n for each athm i n theDoc.GetActiveThemes\n thelabelfield=athm.getlabelfield\n if(athm.CanSelect) then\n ListofFound = athm.FindByPoint(pt1)\n else\n return nil\n end\n if (ListofFound.Count = 0) then return nil end\n for each Found in ListofFound\n if (DoneThis > 0) then\n blurbstring = blurbstring + nl\n end\n blurbstring = blurbstring + athm.GetFTab.ReturnValueString(thelabelfield, Found)\n DoneThis = DoneThis + 1\n end\n end\n t.SetText(blurbstring)\n \n if (t.gettext.count < 1) then return nil end\n \n fgbc = Color.GetWhite\n tc = Color.GetBlack\n \n BulletSymbol = av.GetSymbolWin.GetPalette.GetList(#PALETTE_LIST_MARKER).Get(0)\n BulletSymbol.Setsize(3)\n BulletSymbol.SetColor(Color.GetBlack)\n gb = GraphicShape.Make(pt1)\n gb.SetSymbol(BulletSymbol)\n \n LeaderPen = BasicPen.Make\n LeaderPen.SetColor(Color.GetBlack)\n LeaderPen.SetSize(0.25)\n gl = GraphicShape.Make(ul)\n gl.SetSymbol(LeaderPen)\n \n BgFill = Rasterfill.Make\n BgFill.SetStyle(#RASTERFILL_STYLE_SOLID)\n BgFill. SetColor(Color.GetWhite) 'Set the background color here!!\n if (IsOutLined) then\n BgFill.SetOutlined(true)\n BgFill.SetOLColor(Color.GetBlack)\n BgFill.SetOLWidth(0.25)\n else\n BgFill.SetOutLined(false)\n end\n \n 'Determine which side of leader to position box\n \n if (((pt1.GetX <= pt2.GetX) and (pt1.GetY <= pt2.GetY)) or \n ((pt1.GetX <= pt2.GetX) and (pt1.GetY > pt2.GetY))) then\n \n 'Adjust Text Position with respect to end of leader line\n XAdjustmentDistance = ( t.GetBounds.GetHeight)/2\n t.GetBounds.Move(0,-XAdjustmentDistance)\n BgRect = t.GetBounds.Clone 'This becomes background Rect\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidth * 1.05\n YNewSize = CurrentHeight * 1.1\n BgRect.SetSize(XNewSize@YNewSize)\n tbg = GraphicShape.Make(BgRect)\n tbg.SetSymbol(BgFill) \n BgCenterX = BgRect.ReturnCenter.GetX\n BgCenterY = BgRect.ReturnCenter.GetY\n TxtXOMove = CurrentWidth/2\n TxtYOMOve = CurrentHeight/2\n if (theDoc.Is(Layout)) then\n FontSizeAdjustment = (t.ReturnSymbols.Get(0).GetSize)/(5*72)\n else\n FontSizeAdjustment = (BgRect.GetHeight - t.GetBounds.GetHeight)*(2 - (theDoc.GetActiveThemes.Count/3))\n end \n NewTextOriginX = BgCenterX - TxtXOMove\n NewTextOriginY = BgCenterY - TxtYOMove + FontSizeAdjustment\n t.GetBounds.SetOrigin(NewTextOriginX@NewTextOriginY)\n \n elseif (((pt1.GetX >= pt2.GetX) and (pt1.GetY <= pt2.GetY)) or\n ((pt1.GetX > pt2.GetX) and (pt1.GetY > pt2.GetY))) then \n \n 'Adjust Text Position with respect to end of leader line\n XAdjustmentDistance = (t.GetBounds.GetHeight)/2\n t.GetBounds.Move(0,-XAdjustmentDistance)\n BgRect = t.GetBounds.Clone 'This becomes background Rect\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidth * 1.05\n YNewSize = CurrentHeight * 1.1\n BgRect.SetSize(XNewSize@YNewSize)\n BgRect.Move(-(BgRect.GetWidth),0)\n tbg = GraphicShape.Make (BgRect)\n tbg.SetSymbol(BgFill) \n 'Centering Routine\n BgCenterX = BgRect.ReturnCenter.GetX\n BgCenterY = BgRect.ReturnCenter.GetY\n TxtXOMove = CurrentWidth/2\n TxtYOMOve = CurrentHeight/2\n if (theDoc.Is(Layout)) then\n FontSizeAdjustment = (t.ReturnSymbols.Get(0).GetSize)/(5*72)\n else\n FontSizeAdjustment = (BgRect.GetHeight - t.GetBounds.GetHeight)\n end \n NewTextOriginX = BgCenterX - TxtXOMove\n NewTextOriginY = BgCenterY - TxtYOMove + FontSizeAdjustment\n t.GetB ounds.SetOrigin(NewTextOriginX@NewTextOriginY)\n\n end\n\n\n'Exactly center text within the background box\n\n \nend\n\nif (HasBox) then\n theDoc.GetGraphics.Add(tbg)\nend\ntheDoc.GetGraphics.Add(gb)\ntheDoc.GetGraphics.Add(gl)\ntheDoc.GetGraphics.Add(t)\n\ngb.SetSelected(false)\ngl.SetSelected(false)\ntbg.SetSelected(false)\nt.SetSelected(true)\ntheDoc.GetGraphics.MoveSelectedToFront\ngl.setselected(true)\ngb.SetSelected(true)\ntbg.SetSelected(true)\ntheDoc.GetGraphics.GroupSelected\ntheDoc.GetGraphics.GetSelected.Get(0).Invalida te\ntheDoc.GetGraphics.UnselectAll\n\n\n\n\n" ) (Script.24 Name: "avlabel.ShadowBoxLabelTool" SourceCode: "' Name: ShadowBoxLabelTool\n' \n' Headline: Makes a label with an outline and shadow using the value of the feature\n' of the active theme(s).\n' \n' Self:\n' \n' Returns:\n' \n' Description: This script should be used in view document GUI as a tool. Use this \n' script as the Apply Event Use the Symbolwin.DisplayFontPanel script as the click event. \n' When using this tool, click where you want to make a label. Additionally, you may \n' define your text, foreground, and background colors by pressing and holding down the \n' Shift key while you click and drag; you will be prompted via a series of messageboxes \n' as to which colors to use. \n' \n' The label that is returned is a graphic group. You may select this group and then use\n' the symbol window to change its colors. Foreground only changes the foreground color, \n' background only changes the background color, the outline changes the outline color, and\n' text changes the text color.\n' \n' Topics: Views, Symbols, Graphics\n' \n' Search Keys: Labeling, Text\n' \n' Requires: There must be a view or layout document active.\n' \n' History: ESRI ArcView 3.0\n' \nagrey={100,100,100}\n\ntheDoc = av.GetActiveDoc\ncolors = {\"Pale Yellow\",\"White\",\"Black\",\"Red\",\"Green\",\"Blue\",\"Orange\",\"Yellow\",\"Cyan\",\"Purple\"}\ncrgblists = {{252,252,203},{255,255,255},{0,0,0},{255,195,195},{195,255,195},{201,195,255},{255,199,174},{255,251,195},{195,252,255},{250,195,255}}\n\ncolors2 = {\"Gray\",\"Pale Yellow\",\"White\",\"Black\",\"Red\",\"Green\",\"Blue\",\"Orange\",\"Yellow\",\"Cyan\",\"Purple\" }\ncrgblists2 = {{100,100,100},{252,252,203},{255,255,255},{0,0,0},{255,195,195},{195,255,195},{201,195,255},{255,199,174},{255,251,195},{195,252,255},{250,195,255}}\n\ncolors3 = {\"Black\",\"Gray\",\"Pale Yellow\",\"White\",\"Red\",\"Green\",\"Blue\",\"Orange\",\"Yellow\",\"Cyan\",\"Purple\"}\ncrgblists3 = {{0,0,0},{100,100,100},{252,252,203},{255,255,255},{255,195,195},{195,255,195},{201,195,255},{255,199,174},{255,251,195},{195,252,255},{250,195,255}}\n\nif(theDoc.GetGraphics.EditText.Not) then\n pt = theDoc.GetDisplay.ReturnUserPo int\n if (System.IsShiftKeyDown) then shiftcheck=true else shiftcheck=FALSE end\n t = GraphicText.Make(\"\", pt)\n t.SetDisplay(theDoc.GetDisplay)\n theDoc.GetDisplay.HookUpSymbol(t.GetSymbol)\n theDoc.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n \n blurbstring = \"\"\n DoneThis = 0\n for each athm in theDoc.GetActiveThemes\n thelabelfield=athm.getlabelfield\n if(athm.CanSelect) then\n ListofFound = athm.FindByPoint(pt)\n else\n return nil\n end\n if (ListofFound.Count = 0) then return nil end\n for each Found in ListofFound\n if (DoneThis > 0) then\n blurbstring = blurbstring + nl\n end\n blurbstring = blurbstring + athm.GetFTab.ReturnValueString(thelabelfield, Found)\n DoneThis = DoneThis + 1\n end\n end\n t.SetText(blurbstring)\n\n if (t.gettext.count<1) then return nil end\n theDoc.GetGraphics.AddName(t)\n BgRect = t.GetBounds.Clone 'This becomes background Rect\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidt h * 1.05\n YNewSize = CurrentHeight * 1.1\n BgRect.SetSize(XNewSize@YNewSize)\n if (shiftcheck=TRUE) then\n textcolorname= Msgbox.ChoiceAsString(colors3,\"Choose the text color:\",\"Boxed Text Tool\")\n if (textcolorname = nil) then return nil end\n fgc = Msgbox.ChoiceAsString(colors,\"Choose the box color:\",\"Boxed Text Tool\")\n if (fgc = nil) then return nil end\n isOutlined=Msgbox.YesNoCancel(\"Do you want an outline on the box?\",\"Boxed Text Tool\",true)\n if (IsOutlined = nil) then return nil end \n IsShadowed = Msgbox.YesNoCancel(\"Add a Shadow to the box?\",\"Boxed Text Tool\",true)\n if (IsShadowed = nil) then return nil end\n fgc2=\"Black\"\n if (isShadowed=TRUE) then\n fgc2= Msgbox.ChoiceAsString(colors2,\"Choose the shadow color:\",\"Boxed Text Tool\")\n if (fgc2 = nil) then return nil end \n end\n else\n fgc=\"White\"\n fgc2=\"Gray\"\n textcolorname=\"Black\"\n isoutlined=TRUE\n isshadowed=TRUE\n end\n\n fgrgbi = colors.FindByValue(fgc)\n fgcolor = Color.Make\n fgcolor.SetRGBList (crgblists.Get(fgrgbi))\n fgrgbi2 = colors2.FindByValue(fgc2)\n fgcolor2 = Color.Make\n fgcolor2.SetRGBList(crgblists2.Get(fgrgbi2))\n agrey=crgblists2.Get(fgrgbi2)\n cnamenum = colors3.FindByValue(textcolorname)\n textcolor1 = Color.Make\n textcolor1.SetRGBList(crgblists3.Get(cnamenum))\n NumLines = t.GetText.AsTokens(nl).Count\n t.getsymbol.setcolor(textcolor1)\n boxgsfill = RasterFill.Make\n boxgsfill.SetStyle(#RASTERFILL_STYLE_SOLID)\n boxgsfill.SetColor(fgcolor)\n if (IsOutlined) then\n boxgsfill.Set Outlined(true)\n boxgsfill.SetOLWidth(0.5)\n boxgsfill.SetOLColor(Color.GetBlack)\n else\n boxgsfill.SetOutlined(false)\n end\n BgRect = t.GetBounds.Clone 'This becomes background Rect\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidth * 1.05\n YNewSize = CurrentHeight * 1.05\n BgRect.SetSize(XNewSize@YNewSize)\n BgO = BgRect.ReturnOrigin\n NewWidth = BgRect.GetWidth\n NewHeight = BgRect.GetHeight\n adjustment = ((NewWidth - CurrentWidth)/2)@((NewHe ight*(0.45))/(2*NumLines))\n BgRect.SetOrigin(BgO - adjustment)\n boxgs = GraphicShape.Make(BgRect)\n boxgs.SetSymbol(boxgsfill)\n boxgs.SetDisplay(theDoc.GetDisplay)\n if (IsShadowed) then\n sbox = BgRect.Clone\n mdist = ((sbox.GetHeight)/7)\n nofr = t.GetFillObject.AsTokens((nl.AsASCII).AsChar).Count\n sbox.Move((mdist/nofr),(0 - (mdist/nofr)))\n shbox = GraphicShape.Make(sbox)\n shboxfill = RasterFill.Make\n shboxfill.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\n shboxfill.SetOutlined(false )\n shcolor = Color.Make\n shcolor.SetRGBList(agrey)\n transc = Color.Make\n transc.SetTransparent(true)\n shboxfill.SetColor(transc)\n shboxfill.SetBGColor(shcolor)\n shbox.SetSymbol(shboxfill)\n shbox.SetDisplay(theDoc.GetDisplay)\n end\n if(IsShadowed) then\n theDoc.GetGraphics.Add(shbox)\n shbox.SetSelected(FALSE)\n end\n thedoc.GetGraphics.Add(boxgs)\n boxgs.SetSelected(FALSE)\n t.SetSelected(TRUE)\n theDoc.GetGraphics.MoveSelectedToFront\n if(IsShadowed) then\n shbox.SetSelected( TRUE)\n end \n boxgs.SetSelected(TRUE)\n theDoc.GetGraphics.GroupSelected\n\nend\n\ntheDoc.getgraphics.unselectall\n\n\n" ) (Script.25 Name: "avlabel.ShadowBoxTextTool" SourceCode: "' Name: ShadowBoxTextTool\n' \n' Headline: Makes a label with an outline and shadow using text you enter\n' with the text tool\n' \n' Self:\n' \n' Returns:\n' \n' Description: This script can either be used in the layout or view document GUIs as\n' a tool. Use this script as the Apply Event Use the Symbolwin.DisplayFontPanel script \n' as the click event. When using this tool, click where you want to make a label. The\n' text tool will be opened and you can enter your text. Additionally, you may defi ne\n' your text, foreground, and background colors by pressing and holding down the Shift\n' key while you click and drag; you will be prompted via a series of messageboxes as to\n' which colors to use. \n' \n' The label that is returned is a graphic group. You may select this group and then use\n' the symbol window to change its colors. Foreground only changes the foreground color, \n' background only changes the background color, the outline changes the outline color, and\n' text changes the text color. \n' \n' Topics: Views, Layouts, Symbols, Graphics\n' \n' Search Keys: Labeling, Text\n' \n' Requires: There must be a view or layout document active.\n' \n' History: ESRI ArcView 3.0\n' \nagrey={100,100,100}\n\ntheDoc = av.GetActiveDoc\ncolors = {\"Pale Yellow\",\"White\",\"Black\",\"Red\",\"Green\",\"Blue\",\"Orange\",\"Yellow\",\"Cyan\",\"Purple\"}\ncrgblists = {{252,252,203},{255,255,255},{0,0,0},{255,195,195},{195,255,195},{201,195,255},{255,199,174},{255,251,195},{195,252,255},{250,195,255}}\n\ncolors2 = {\"Gray\",\"Pale Yellow\", \"White\",\"Black\",\"Red\",\"Green\",\"Blue\",\"Orange\",\"Yellow\",\"Cyan\",\"Purple\"}\ncrgblists2 = {{100,100,100},{252,252,203},{255,255,255},{0,0,0},{255,195,195},{195,255,195},{201,195,255},{255,199,174},{255,251,195},{195,252,255},{250,195,255}}\n\ncolors3 = {\"Black\",\"Gray\",\"Pale Yellow\",\"White\",\"Red\",\"Green\",\"Blue\",\"Orange\",\"Yellow\",\"Cyan\",\"Purple\"}\ncrgblists3 = {{0,0,0},{100,100,100},{252,252,203},{255,255,255},{255,195,195},{195,255,195},{201,195,255},{255,199,174},{255,251,195},{195,252,255},{250,195,255}}\n\nif(theDo c.GetGraphics.EditText.Not) then\n pt = theDoc.GetDisplay.ReturnUserPoint\n if (System.IsShiftKeyDown) then shiftcheck=true else shiftcheck=FALSE end\n t = GraphicText.Make(\"\", pt)\n t.SetDisplay(theDoc.GetDisplay)\n theDoc.GetDisplay.HookUpSymbol(t.GetSymbol)\n theDoc.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n if (t.EditText) then\n if (t.gettext.count<1) then return nil end\n NumLines = t.GetText.AsTokens(nl).Count\n theDoc.GetGraphics.AddName(t)\n BgRect = t.GetBounds.Clone 'This b ecomes background Rect\n CurrentWidth = BgRect.GetWidth\n CurrentHeight = BgRect.GetHeight\n XNewSize = CurrentWidth * 1.05\n YNewSize = CurrentHeight * 1.05\n BgRect.SetSize(XNewSize@YNewSize)\n BgO = BgRect.ReturnOrigin\n NewWidth = BgRect.GetWidth\n NewHeight = BgRect.GetHeight\n adjustment = ((NewWidth - CurrentWidth)/2)@((NewHeight*(0.45))/(2*NumLines))\n BgRect.SetOrigin(BgO - adjustment)\n if (shiftcheck=TRUE) then\n textcolorname= Msgbox.ChoiceAsString(colors3,\"Choose the t ext color:\",\"Boxed Text Tool\")\n if (textcolorname = nil) then return nil end\n fgc = Msgbox.ChoiceAsString(colors,\"Choose the box color:\",\"Boxed Text Tool\")\n if (fgc = nil) then return nil end\n isOutlined=Msgbox.YesNoCancel(\"Do you want an outline on the box?\",\"Boxed Text Tool\",true)\n if (IsOutlined = nil) then return nil end \n IsShadowed = Msgbox.YesNoCancel(\"Add a Shadow to the box?\",\"Boxed Text Tool\",true)\n if (IsShadowed = nil) then return nil end\n fgc2=\"Black\"\n if (isShadowed=TRUE) then\n fgc2= Msgbox.ChoiceAsString(colors2,\"Choose the shadow color:\",\"Boxed Text Tool\")\n if (fgc2 = nil) then return nil end \n end\n else\n fgc=\"White\"\n fgc2=\"Gray\"\n textcolorname=\"Black\"\n isoutlined=TRUE\n isshadowed=TRUE\n end\n\n fgrgbi = colors.FindByValue(fgc)\n fgcolor = Color.Make\n fgcolor.SetRGBList(crgblists.Get(fgrgbi))\n fgrgbi2 = colors2.FindByValue(fgc2)\n fgcolor2 = Color.Make\n fgcolor2.SetRGBList(crgblists2 .Get(fgrgbi2))\n agrey=crgblists2.Get(fgrgbi2)\n cnamenum = colors3.FindByValue(textcolorname)\n textcolor1 = Color.Make\n textcolor1.SetRGBList(crgblists3.Get(cnamenum))\n t.getsymbol.setcolor(textcolor1)\n boxgs = GraphicShape.Make(BgRect)\n boxgsfill = RasterFill.Make\n boxgsfill.SetStyle(#RASTERFILL_STYLE_SOLID)\n boxgsfill.SetColor(fgcolor)\n if (IsOutlined) then\n boxgsfill.SetOutlined(true)\n boxgsfill.SetOLWidth(0.5)\n boxgsfill.SetOLColor(Color.GetBlack)\n else\n boxgsfill.SetOutlined(false)\n end\n boxgs.SetSymbol(boxgsfill)\n boxgs.SetDisplay(theDoc.GetDisplay)\n if (IsShadowed) then\n sbox = BgRect.Clone\n mdist = ((sbox.GetHeight)/7)\n nofr = t.GetFillObject.AsTokens((nl.AsASCII).AsChar).Count\n sbox.Move((mdist/nofr),(0 - (mdist/nofr)))\n shbox = GraphicShape.Make(sbox)\n shboxfill = RasterFill.Make\n shboxfill.SetStyle(#RASTERFILL_STYLE_OPAQUESTIPPLE)\n shboxfill.SetOutlined(false)\n shcolor = Color.Make\n shc olor.SetRGBList(agrey)\n transc = Color.Make\n transc.SetTransparent(true)\n shboxfill.SetColor(transc)\n shboxfill.SetBGColor(shcolor)\n shbox.SetSymbol(shboxfill)\n shbox.SetDisplay(theDoc.GetDisplay)\n end\n if(IsShadowed) then\n theDoc.GetGraphics.Add(shbox)\n shbox.SetSelected(FALSE)\n end\n thedoc.GetGraphics.Add(boxgs)\n boxgs.SetSelected(FALSE)\n t.SetSelected(TRUE)\n theDoc.GetGraphics.MoveSelectedToFront\n if(IsShadowed) then\n shbox.SetSelected( TRUE)\n end \n boxgs.SetSelected(TRUE)\n theDoc.GetGraphics.GroupSelected\n end\nend\n\ntheDoc.getgraphics.unselectall\n\n\n" ) (Script.26 Name: "avlabel.CreateDropShadowText" SourceCode: "theLayout = av.GetActiveDoc\n\nif (theLayout.GetGraphics.EditText.Not) then\n pt = theLayout.GetDisplay.ReturnUserPoint\n t = GraphicText.Make(\"\", pt)\n t.SetDisplay(theLayout.GetDisplay)\n theLayout.GetGraphics.UnselectAll\n t.SetSelected(TRUE)\n\n if (t.EditText) then\n theLayout.GetGraphics.AddName(t)\n \n 'get the current textsymbol size\n z=t.getsymbol.getsize\n \n 'determine offsets for drop shadow\n xfac = (z/72)/20\n yfac = (z/72)/30\n\n \n 'make the text red if current color is black, transp arent, or white\n if ((t.GetSymbol.GetColor = Color.GetBlack) or\n (t.GetSymbol.GetColor.IsTransparent) or\n (t.GetSymbol.GetColor = Color.GetWhite)) then\n t.getsymbol.SetColor(Color.GetRed)\n end\n \n 'duplicate the original object\n t2=t.clone\n \n 'add the drop shadow text to the layout\n theLayout.GetGraphics.AddName(t2)\n \n 'reposition it\n t2.offset(point.make(xfac,-yfac))\n\n 'clear selection\n theLayout.GetGraphics.UnselectAll\n \n 'select the drop shadow\n t2. SetSelected(TRUE)\n \n 'set its color\n t2.GetSymbol.SetColor(Color.GetBlack)\n \n 'move it to the back\n theLayout.GetGraphics.MoveSelectedToBack\n \n 'select the original text too\n t.SetSelected(TRUE)\n \n 'put the two together into a group\n theLayout.GetGraphics.GroupSelected\n\n end\nend\n" ) (Script.27 Name: "avlabel.GeneralUpdate" SourceCode: "theView = av.GetActiveDoc\nif (theView.GetEditableTheme <> NIL) then\n SELF.SetEnabled(FALSE)\n return nil\nend\nfor each t in theView.GetActiveThemes\n if (t.IsVisible and (t.CanLabel) and (t.GetLabelField <> NIL)) then\n SELF.SetEnabled(TRUE)\n return nil\n end\nend\nSELF.SetEnabled(FALSE)\n" ) (Script.28 Name: "avlabel.Install" SourceCode: "if (av.GetProject = nil) then\n return nil\nend\nViewGUIToolBar = av.GetProject.FindGUI(\"View\").GetToolBar\nLayoutGUIToolBar = av.GetProject.FindGUI(\"Layout\").GetToolBar\n\nif ((ViewGUIToolBar = nil) or (LayoutGUIToolBar = nil)) then\n Msgbox.Error(\"A toolbar must be present for \"+NL+\n \"both view and layout documents.\",\n \"Labeling Extension could not be loaded\")\n return nil\nend\n\nnewViewLabelToolMenu = Self.Get(0)\nnewViewTextToolMenu = Self.Get(1)\nnewLayoutTextToolMenu = Self.Get(2)\n\n ViewGUIToolBar.Add(newViewLabelToolMenu,(ViewGUIToolBar.GetControls.Count -1))\nViewGUIToolBar.Add(newViewTextToolMenu,(ViewGUIToolBar.GetControls.Count -1))\nLayoutGUIToolBar.Add(NewLayoutTextToolMenu,(LayoutGUIToolBar.GetControls.Count -1))\n" ) (Script.29 Name: "avlabel.Uninstall" SourceCode: "if ((av.GetProject = nil) or (av.GetProject.IsClosing)) then\n return nil\nend\n\nfor each g in av.GetProject.FindGUIsFor(View)\n g.GetToolBar.Remove(g.GetToolBar.FindByScript(\"avlabel.BlurbTextTool\"))\n g.GetToolBar.Remove(g.GetToolBar.FindByScript(\"avlabel.BlurbLabelTool\"))\nend\nfor each g in av.GetProject.FindGUIsFor(Layout)\n g.GetToolBar.Remove(g.GetToolBar.FindByScript(\"avlabel.BlurbTextTool\"))\nend\n" )