/3.0 (Extension.1 Name: "Overview Utility" FirstRootClassName: "BShSym" Roots: 2 Roots: 7 Roots: 47 Roots: 48 Roots: 49 Roots: 50 Roots: 51 Roots: 52 Roots: 53 Roots: 54 Roots: 55 Roots: 56 Roots: 57 Roots: 58 Roots: 59 Roots: 60 Roots: 61 Version: 30 About: "Allows you to create overviews. You can add this functionality to one or more DocGUIs for views." InstallScript: 62 UninstallScript: 63 ExtVersion: 1 ) (BShSym.2 Color: 3 Outline: 1 OutlineColor: 4 OutlineWidth: 2.00000000000000 BgColor: 5 Style: 0x03 Stipple: 6 ) (TClr.3 Red: 0xffff Green: 0xffff ) (TClr.4 Red: 0xffff Green: 0xffff ) (TClr.5 Name: "Transparent" ) (Stipple.6 Columns: 8 Rows: 8 Bits: aa55aa55 aa55aa55 ) (DocGUI.7 Name: "Overview" DocBaseName: "Overview for " Type: "View" Modified: 1 MenuBar: 8 ButnBar: 18 Popups: 24 ToolBar: 43 NewScript: "View.New" OpenScript: "Doc.Open" ActionScript: "Doc.Action" NewUpdateScript: "Doc.NewUpdate" OpenUpdateScript: "Doc.OpenUpdate" ActionUpdateScript: "Doc.ActionUpdate" Title: "Overviews" Icon: 46 ) (MenuBar.8 Child: 9 Child: 13 ) (PMenu.9 InternalName: "Edit" Child: 10 Child: 11 Child: 12 Label: "&Edit" ) (Choice.10 Help: "Displays the TOC so you can delete or changed themes." Update: "OverView.DisplayTOCUpdate" Label: "Display TOC" Click: "Overview.DisplayTOC" Shortcut: "Keys.None" ) (Choice.11 Help: "Removes the active themes from the view" HelpTopic: "Delete_Themes" Update: "View.ActiveDeletableThemesUpdate" Label: "De&lete Themes" Click: "View.DeleteThemes" Shortcut: "Keys.None" ) (Space.12 ) (PMenu.13 InternalName: "Help" Child: 14 Child: 15 Child: 16 Child: 17 Label: "&Help" ) (Choice.14 Help: "Displays the dialog for browsing and searching ArcView's help system" HelpTopic: "Help_on_Help_Topics" Label: "Help &Topics..." Click: "Project.HelpTopics" Shortcut: "Keys.None" ) (Choice.15 Help: "Provides instructions for how to obtain help from ArcView" HelpTopic: "Help_on_How_to_Get_Help" Label: "&How to Get Help..." Click: "Project.HelpHelp" Shortcut: "Keys.None" ) (Space.16 ) (Choice.17 Help: "Provides information about ArcView" HelpTopic: "About" Label: "&About ArcView..." Click: "Project.About" Shortcut: "Keys.None" ) (ButnBar.18 Child: 19 Child: 21 Child: 22 ) (Butn.19 Help: "Save Project//Saves the current project" HelpTopic: "Save_Project" Icon: 20 Click: "Project.Save" ) (AVIcon.20 Name: "Save" Res: "Icons.Save" ) (Space.21 ) (Butn.22 Help: "Help//Gets help about the next button, tool, or menu choice you click" HelpTopic: "Help_button" Icon: 23 Click: "Help.Tool" ) (AVIcon.23 Name: "HelpTool" Res: "Icons.HelpTool" ) (PopupSet.24 Child: 25 ) (Popup.25 Child: 26 Child: 27 Child: 28 Child: 29 Child: 30 Child: 31 Child: 32 Child: 33 Child: 34 Child: 35 Child: 36 Child: 37 Child: 38 Child: 39 Child: 40 Child: 41 Child: 42 Label: "Menu" ) (Choice.26 Disabled: 1 Invisible: 1 Help: "Deletes the last entered point on the line or polygon being drawn" Update: "View.DelLastPointUpdate" Label: "Delete Last Point" Click: "View.DeleteLastPoint" Shortcut: "Keys.None" ) (Choice.27 Help: "Undo the last edit to graphics on a view" HelpTopic: "Undo_Graphic_Edit_on_a_view" Update: "View.UndoEditUpdate" Label: "Undo Graphic Edit" Click: "View.UndoEdit" Shortcut: "Keys.None" ) (Choice.28 Disabled: 1 Invisible: 1 Help: "Redo the last edit operation on a theme that was undone" Update: "View.RedoEditUpdate" Label: "Redo Feature Edit" Click: "View.RedoEdit" Shortcut: "Keys.None" ) (Space.29 ) (Choice.30 Disabled: 1 Invisible: 1 Help: "Turns general snapping on" Update: "View.ToggleGeneralSnapUpdate" Label: "Enable General Snapping" Click: "View.ToggleGeneralSnap" Shortcut: "Keys.None" ) (Choice.31 Disabled: 1 Invisible: 1 Help: "Turns interactive snapping on" Update: "View.ToggleInteractiveSnapUpdate" Label: "Enable Interactive Snapping" Click: "View.ToggleInteractiveSnap" Shortcut: "Keys.None" ) (Space.32 ) (Choice.33 Disabled: 1 Invisible: 1 Help: "Snaps the next entered point to the nearest vertex within the user tolerance" Update: "View.InteractiveSnapUpdate" Label: "Snap to Vertex" Click: "View.SnapToVertex" Shortcut: "Keys.None" ) (Choice.34 Disabled: 1 Invisible: 1 Help: "Snaps the next entered point to the nearest line segment" Update: "View.InteractiveSnapUpdate" Label: "Snap to Boundary" Click: "View.SnapToBoundary" Shortcut: "Keys.None" ) (Choice.35 Disabled: 1 Invisible: 1 Help: "Snaps the next entered point to the nearest node common to two or more features" Update: "View.InteractiveSnapUpdate" Label: "Snap to Intersection" Click: "View.SnapToIntersection" Shortcut: "Keys.None" ) (Choice.36 Disabled: 1 Invisible: 1 Help: "Snaps the next entered point to the nearest endpoint of an existing line" Update: "View.SnapToEndPointUpdate" Label: "Snap to Endpoint" Click: "View.SnapToEndPoint" Shortcut: "Keys.None" ) (Space.37 ) (Choice.38 Help: "Unselects the selected features in all active themes" Update: "View.AttributeThemesUpdate" Label: "Clear Selection" Click: "View.ClearSelect" Shortcut: "Keys.None" ) (Choice.39 Help: "Zooms in at point where you click to bring up popup menu" Update: "View.HasDataUpdate" Label: "Zoom In" Click: "View.PopupZoomIn" Shortcut: "Keys.None" ) (Choice.40 Help: "Zooms out from point where you click to bring up popup menu" Update: "View.HasDataUpdate" Label: "Zoom Out" Click: "View.PopupZoomOut" Shortcut: "Keys.None" ) (Choice.41 Help: "Zooms to the extent of the selected features" Update: "View.SelectableThemesUpdate" Label: "Zoom to Selected" Click: "View.ZoomToSelected" Shortcut: "Keys.None" ) (Choice.42 Help: "Centers display on point where you click to bring up popup" Update: "View.HasDataUpdate" Label: "Pan" Click: "View.PopupPan" Shortcut: "Keys.None" ) (ToolBar.43 Child: 44 ) (Tool.44 Help: "Pointer//Selects, moves, and resizes graphics" HelpTopic: "Pointer_tool" Update: "View.HasDataUpdate" Icon: 45 Cursor: "Cursors.Select" Apply: "Overview.ResizeBox" Click: "View.SelectTool" ) (AVIcon.45 Name: "Select" Res: "Icons.Select" ) (AVIcon.46 Name: "O" Res: "Icons.O" ) (Choice.47 InternalName: "Overview" Help: "Creates an overview window for this view." Update: "Overview.MakeDelUpdate" Label: "Create overview" Click: "OverView.MakeOverview" Shortcut: "Keys.None" ) (Choice.48 InternalName: "Overview" Disabled: 1 Help: "Displays the overview window for this view." Update: "Overview.IsOverviewUpdate" Label: "Display overview" Click: "Overview.DisplayOverview" Shortcut: "Keys.None" ) (Script.49 Name: "Overview.CloseView" SourceCode: "\noverview = _Overview_status.Get( self )\noverview.GetWin.Close" ) (Script.50 Name: "Overview.DeleteOverview" SourceCode: "\n' Overview.Deleteoverview\n\ntheView = av.GetActiveDoc\nover = _overview_status.Get( theView )\n_overview_status.Remove( theView )\ntheView.SetUpdateScript( \"\")\ntheView.SetOpenScript( \"\" )\ntheView.SetCloseScript( \"\" )\nav.GetProject.RemoveDoc( over )\n" ) (Script.51 Name: "Overview.DisplayOverview" SourceCode: "theView = av.GetActiveDoc\n_overview_status.Get( theView ).Getwin.Open\n" ) (Script.52 Name: "Overview.DisplayTOC" SourceCode: "' Overview.DisplayTOC\ntheOverview = av.GetActiveDoc\ntheOverview.SetTOCUnResizable( false )\ntheOverview.SetTOCWidth( 100 )" ) (Script.53 Name: "OverView.DisplayTOCUpdate" SourceCode: "theOverview = av.GetActiveDoc\nif (theOverview.IsTOCUnresizable) then\n self.SetLabel( \"Display TOC\" )\n self.SetClick( \"Overview.DisplayTOC\" )\n self.SetHelp( \"Displays the TOC so you can delete or changed themes.\")\nelse\n self.SetLabel( \"Hide TOC\" )\n self.SetClick( \"Overview.HideTOC\")\n self.SetHelp( \"Hides the TOC.\")\nend" ) (Script.54 Name: "Overview.HideTOC" SourceCode: "' Overview.HideTOC \ntheOverview = av.GetActiveDoc\ntheOverview.SetTOCWidth( 0 )\ntheOverview.SetTOCUnresizable( true )" ) (Script.55 Name: "Overview.IsOverviewUpdate" SourceCode: "theView = av.GetActiveDoc\nself.SetEnabled( _overview_status.Get(theView) <> nil)\n" ) (Script.56 Name: "Overview.MakeDelUpdate" SourceCode: "theView = av.GetActiveDoc\nif (av.GetProject.FindDoc( \"Overview for\"++theView.GetName ) <> nil) then\n self.SetLabel( \"Delete overview\" )\n self.SetClick( \"OverView.DeleteOverview\" )\n self.SetHelp( \"Deletes the overview window for this view\")\nelse\n self.SetLabel( \"Create overview\" )\n self.SetClick( \"OverView.MakeOverview\" )\n self.SetHelp( \"Creates an overview window for this view.\")\nend\n" ) (Script.57 Name: "Overview.MakeOverview" SourceCode: "theView = av.GetActiveDoc\n\n' Create the overview view\nover = theView.clone\nover.SetName( \"Overview for\"++theView.GetName )\nover.GetDisplay.SetExtent( theView.ReturnExtent )\nover.SetGUI( \"Overview\" )\nover.SetTOCWidth( 0 )\nover.SetTocUnresizable( true )\nover.SetObjectTag(theView)\nav.GetProject.AddDoc( over )\n\n' Set size and position\nx = av.ReturnExtent.GetX\nover.GetWin.Resize( 265, 230)\nover.GetWin.MoveTo((x - 265), 1)\n\n' Add extent graphic\nover.GetGraphics.Empty\nbox = GraphicShape.Make( theView.GetDisplay.Re turnVisExtent )\nbox.SetSymbol( _overview_raster.clone )\nover.GetGraphics.Add( box )\n\nover.GetWin.Open\n\n' Associate overview with view\n_Overview_status.Add( theView, over )\ntheView.SetOpenScript( \"Overview.OpenView\" )\ntheView.SetCloseScript( \"Overview.CloseView\" )\ntheView.SetUpdateScript( \"Overview.UpdateView\" )\nav.GetProject.Update\ntheView.GetWin.Activate" ) (Script.58 Name: "Overview.OpenView" SourceCode: "\noverview = _overview_status.Get( self )\noverview.GetWin.Open" ) (Script.59 Name: "Overview.ResizeBox" SourceCode: "\ntheOverview = av.GetActiveDoc\nbox1 = theOverview.GetGraphics.Get(0).GetShape\ntheOverview.Select\n\ntheView = theOverview.GetObjectTag\nif (theOverview.GetGraphics.Count = 0) then\n av.run( \"Overview.UpdateOverview\", theOverview)\nelse \n box = theOverview.GetGraphics.Get(0).GetShape\n if (box1 <> box) then\n ' Set extent on the view \n theView.GetDisplay.SetExtent( box )\n theView.SetAOI( box )\n end\nend" ) (Script.60 Name: "Overview.UpdateOverview" SourceCode: "\n' Update overview when change occurs in View\ntheView = self.GetObjectTag\nnewExtent = theView.GetDisplay.ReturnVisExtent\nif (newExtent <> self.GetGraphics.Get(0).GetShape) then\n self.GetGraphics.Get(0).Invalidate\n self.GetGraphics.Get(0).SetShape(newExtent)\n self.GetGraphics.Get(0).Invalidate\nend" ) (Script.61 Name: "Overview.UpdateView" SourceCode: "\nav.run( \"OverView.UpdateOverview\", _overview_status.Get( self ))" ) (Script.62 Name: "Install" SourceCode: "\n' Install ONLY if there is an active project\nif (av.GetProject = nil) then\n return nil\nend\n\nOVPrefs = self.GetPreferences\n\n' Already been loaded - don't install controls\nif (OVPrefs.Count > 0) then\n _overview_status = OVPrefs.Get( \"Saved_Overviews\" )\n _overview_raster = self.Get(0)\n \n ' Install the DocGUI and restore its modified state\n av.GetProject.AddGUI( self.Get(1))\n self.Get(2).SetModified( FALSE )\n \n return nil\nend\n\n' Create preferences\n_overview_status = Dictionary.Make( 20 )\n_overview_ras ter = self.Get(0)\nOVPrefs.Add( \"Saved_Overviews\", _overview_status )\nOVPrefs.Add( \"Version\", self.GetExtVersion )\n\n' Select DocGUIs to install to\nviewGUIs = msgbox.MultiList( av.GetProject.FindGUIsFor( View ), \"Select DocGUIs\", \"Overview Install\" )\nif (viewGUIs = nil) then\n return nil\nend\n\n' Install the DocGUI and restore its modified state\nav.GetProject.AddGUI( self.Get(1))\nself.Get(2).SetModified( FALSE )\n\nx = 0\nfor each g in viewGUIs\n viewMenu = g.GetMenuBar.FindByLabel( \"View\" )\n if (viewMenu = nil) then\n msgbox.Info( g.GetName++\"has no VIEW menu\", \"NOT INSTALLED IN\"++g.GetName )\n continue\n end \n newChoice1 = self.Get( 2 ).clone\n newChoice2 = self.Get( 3 ).clone\n viewMenu.Add( newChoice1, 1)\n viewMenu.Add( newChoice2, 2)\n x = x + 1\n g.SetModified( true )\nend\n\nif (x = 0) then\n msgbox.error( \"Nothing installed\", \"UNLOADING\" )\n self.Unload\nend" ) (Script.63 Name: "Uninstall" SourceCode: "'No current project - nothing to uninstall from\nif (av.GetProject = nil) then\n return NIL\nend\n\n'Project is closing - no need to uninstall controls\nif (av.GetProject.IsClosing) then\n return NIL\nend\n\n' Delete controls from all DocGUIs for Views\nfor each d in av.GetProject.FindGUIsFor( View )\n\n ' Delete any choices\n for each m in d.GetMenuBar.GetControls.Clone \n c = m.FindByName( \"Overview\" ) \n while (c <> nil) \n m.Remove( c ) \n c = m.FindByName( \"Overview\" ) \n end \n if (m.GetControls.Count = 0 ) then \n d.GetMenuBar.Remove( m ) \n end \n end\nend\n\n' Clean up views and delete all overview views\nkeys = _overview_status.ReturnKeys\nfor each v in keys\n v.SetUpdateScript( \"\" )\n v.SetOpenScript( \"\" )\n v.SetCloseScript( \"\" )\n av.GetProject.RemoveDoc( _overview_status.Get( v ))\nend\n\n' Remove DocGUI\nav.GetProject.RemoveGUI( self.Get(1).GetName )\n\n \n" )