This project is read-only.

Breaking Changes

Jan 12, 2011 at 6:40 PM

I am changing

SetInverseFlattening() in DotSpatial.Project.Spheroid
to a property

I feel it is more natural to write 

InverseFlattening = x; 
than
SetInverseFlattening(x);
Feel free to discuss this.
Jan 12, 2011 at 6:43 PM

I just came up with an argument as to why this might not be wise. This method requires that

EquatorialRadius

is set before it is called.

 

Jan 12, 2011 at 8:09 PM

 ProjectionInfo.ToProj4String() has a similar counterpart: GeographicInfo.Datum.Spheroid.GetProj4String();

I think we should pick one prefix and stick with it.

Jan 12, 2011 at 9:15 PM

I think ToProj4String is probably better.

Ted

 

Jan 12, 2011 at 10:19 PM

ReadProj4String() in ProjectionInfo will be marked private. To instantiate a new ProjectionInfo with a proj4string, please use this sample.

 ProjectionInfo test = new ProjectionInfo(value);
Jan 12, 2011 at 10:45 PM
shade1974 wrote:

I think ToProj4String is probably better.

Ted

 

Thanks. I'll be using that for consistency.

Jun 22, 2011 at 6:57 PM

We will be introducing a breaking change (aimed at plugin developers)

MenuStrip mainMenu,
ToolStrip mainToolStrip,
ToolStripContainer toolStripContainer,
Ribbon ribbon
Will all be removed from 
MapPluginArgs
in favor of using
appManager.HeaderControl
This removes the requirement that plugin developers implement separate logic for all of the possible menu and ribbon configurations.
Jun 22, 2011 at 7:21 PM
Why not version the interface?

IPlugIn
IPlugInV2

Then depreciate the interface later

On Wed, Jun 22, 2011 at 10:57 AM, mudnug <notifications@codeplex.com> wrote:
> From: mudnug
>
> We will be introducing a breaking change (aimed at plugin developers)
>
> MenuStrip mainMenu,
>
> ToolStrip mainToolStrip,
>
> ToolStripContainer toolStripContainer,
>
> Ribbon ribbon
>
> Will all be removed from
>
> MapPluginArgs
>
> in favor of using
>
> appManager.HeaderControl
>
> This removes the requirement that plugin developers implement separate logic
> for all of the possible menu and ribbon configurations.
>
> Read the full discussion online.
>
> To add a post to this discussion, reply to this email
> ([email removed])
>
> To start a new discussion for this project, email
> [email removed]
>
> You are receiving this email because you subscribed to this discussion on
> CodePlex. You can unsubscribe or change your settings on codePlex.com.
>
> Please note: Images and attachments will be removed from emails. Any posts
> to this discussion will also be available online at codeplex.com
Jun 22, 2011 at 8:16 PM
Edited Jun 22, 2011 at 8:24 PM

The scenario that has been presented to me is that we are actually still working on V1 one of the plugin interface. The changes will bring it in line so that we can encourage developers to start creating plugins.

These aformentioned properties will also be removed from AppManager

Any more thoughts here?

Jun 23, 2011 at 4:32 AM

We still haven't released version 1 of DotSpatial but this gets us closer.

- Dan
--------
Daniel P. Ames Ph.D.
Idaho State University Dept. of Geosciences
dan.ames@isu.edu
--------
Sent from my Droid

On Jun 22, 2011 1:17 PM, "mudnug" <notifications@codeplex.com> wrote:
> From: mudnug
>
> The scenario that has been presented to me is that we are actually still working on V1 one of the plugin interface. The changes will bring it in line so that we can encourage developers to start creating plugins.Any more thoughts here?
>
>
Jun 27, 2011 at 9:49 PM

I have marked MenuStrip, Ribbon, and ToolStrip as obsolete (http://dotspatial.codeplex.com/SourceControl/changeset/changes/a30063c45359). They will be removed at some point in the future.

Aug 2, 2011 at 11:16 PM

We are preparing to make breaking changes to the plugin API to make it more consistent and easier to use. IMapPluginArgs and the Initialize method will no longer be used. The Activate method (which is already present) will be recommended along with a new property ('App'). "IsEnabled" has been renamed to "IsActive"

Here is an example for the ShapeEditorPlugin

 

    public class ShapeEditorPlugin : Extension
    {
        private ButtonHandler _myHandler;

        /// <inheritdoc/>
        public override void Activate()
        {
            _myHandler = new ButtonHandler(this.App) { Map = App.Map };
            base.Activate();
        }

        /// <inheritdoc/>
        public override void Deactivate()
        {
            if (App.HeaderControl != null) { App.HeaderControl.RemoveItems(); }

            if (_myHandler != null) { _myHandler.Dispose(); }
            base.Deactivate();
        }
    }

 

 

Below is the old version for comparison:

    public class ShapeEditorPlugin : Extension, IMapPlugin
    {
        #region Private Variables

        private IMapPluginArgs _host; // caches useful information about the host application
        private ButtonHandler _myHandler;

        #endregion Private Variables

        /// <summary>
        /// The initialization is where this plugin can cache the necessary information about the MapWindow
        /// project.  This includes, for instance, the Map or Legend that is associated with the GeoPlugin
        /// Manager.  This can be useful for trapping events or accessing member values like the MapFrame
        /// or figuring out what layers are currently in the map, or even getting to the dataset for
        /// each layer.
        /// </summary>
        /// <param name="args">The IMapPluginArgs replaces the g_MapWin concept and has the necessary application info.</param>
        public void Initialize(IMapPluginArgs args)
        {
            _host = args;
            _myHandler = new ButtonHandler(args.AppManager) { Map = args.Map };
        }

        /// <inheritdoc/>
        protected override void OnActivate()
        {
            base.OnActivate();
        }

        /// <inheritdoc/>
        protected override void OnDeactivate()
        {
            if (_host.AppManager.HeaderControl != null) { _host.AppManager.HeaderControl.RemoveItems(); }

            if (_myHandler != null) { _myHandler.Dispose(); }

            base.OnDeactivate();
        }
    }
}

Aug 4, 2011 at 12:14 AM
AppEnableMethod will now have the following three values.

 

        /// <summary>
        /// The "Extensions" menu item will appear on the HeaderControl.  Clicking it launches the AppDialog.
        /// </summary>
        Default = 0,
 
        /// <summary>
        /// A "plugin" glyph will appear suspended in the lower right corner of the map.  Clicking it launches
        /// the AppDialog.
        /// </summary>
        MapGlyph,
 
        /// <summary>
        /// The AppDialog will button not be shown. This allows the application developer to provide a custom implementation.
        /// </summary>
        None,

AppEnableMethod will also be renamed to ShowExtensionsDialog
Sep 20, 2011 at 6:38 PM

I'm going to be reorganizing projects so that they are no longer in paths like C:\dev\DotSpatial\DotSpatial.Analysis\DotSpatial.Analysis\DotSpatial.Analysis.csproj

and are now more like C:\dev\DotSpatial\DotSpatial.Analysis\DotSpatial.Analysis.csproj

Oct 3, 2011 at 9:12 PM

Instead of using 

new ProjectionInfo(proj4String)

You'll now need to use:

ProjectionInfo.FromProj4String(proj4String)

Similarly, the following methods are now available:
FromEpsgCode
FromEsriString

Oct 4, 2011 at 4:44 PM
Edited Oct 4, 2011 at 5:44 PM

Does It mean that I can get the EPSGCode from the ProjectionInfo?

Oct 4, 2011 at 11:07 PM

Not at this time. There is no .ToEpsgCode();

ProjectionInfo has a EpsgCode property which you can set for your own use.

Oct 10, 2011 at 9:50 PM

We're marking SpatialStatusStrip as obsolete:

[System.Obsolete("Load the DotSpatial.Plugins.MenuBar into a form that implements IHeaderControl instead. Or, just use a regular .Net StatusStrip.")]
    public partial class SpatialStatusStrip : StatusStripIProgressHandler
Oct 18, 2011 at 4:40 PM

When using a 'regular .Net StatusStrip' how do I link this to the map? None of the progress handlers will use the progressbar on the .Net StatusStrip.

Terry

Oct 19, 2011 at 1:32 AM

 You will need to implement 

IProgressHandler or IStatusControl.
See the example in DemoMap.
If you have further questions on this issue, please do create a new thread so that this one contains information related to breaking changes.

 

 

 

Oct 19, 2011 at 11:27 PM

A reference to DotSpatial.Extensions is now required for plugins. Hopefully, it will eventually be the primary reference they need, but we will have to reorganize additional code to make that happen.

Oct 20, 2011 at 4:19 PM
Edited Oct 20, 2011 at 4:20 PM

Is there sample code of how to link a progressbar to a map or legend? Previously we linked a spatialstatusstrip to monitor load progess in the label and progress controls.

Oops, will post a new thread.

Oct 26, 2011 at 8:42 PM

Members have been added to IDockManager. This will require that extensions be recompiled.

Oct 31, 2011 at 9:20 PM

There will no longer be a DataManager property on ApplicationManager.

An extension will be created that instantiates a DataManager.

If you want to get a list of IDataProviders, you can use 

App.CompositionContainer.GetExportedValues<IDataProvider>()
Nov 1, 2011 at 6:32 PM

Loaded Event renamed to
ExtensionsActivated
to match the new
OnExtensionsActivating
event.
Nov 1, 2011 at 9:00 PM

AppManager.ExtensionsDirectory will be marked private. Use
AppManager.AbsolutePathToExtensions instead
Nov 15, 2011 at 5:55 PM

Removed ColorFromHsl from DotSpatial.Symbology.SymbologyGlobal as it is a duplicate of the same method in DotSpatial.Data.Global

Nov 16, 2011 at 12:40 AM

Removed SelectionInverse, a duplicate of FeatureSelection.InvertSelection

Nov 16, 2011 at 12:55 AM

Removed 

 ConvertT
GetNumericType
MaximumValue
MinimumValue
SafeCastTo
ParseEnum

from DotSpatial.Symbology.SymbologyGlobal as they were duplicates of the same methods in DotSpatial.Data.Global
Nov 16, 2011 at 3:02 AM

Removed duplicate classes:

WKBReader

WKBWriter

WKBGeometryTypes

from DotSpatial.Data.

Use DotSpatial.Topology.Utilities.WkbReader, DotSpatial.Topology.Utilities.WkbWriter, DotSpatial.Topology.Utilities.WkbGeometryTypes instead.

Nov 16, 2011 at 9:19 PM

Removed

DotSpatial.Common.Global

as it was a duplicate of DotSpatial.Data.Global



        
    
Nov 29, 2011 at 9:43 PM

Changes in DotSpatial.Controls.Header:

1. Added an event: IHeaderControl.RootItemSelected

This event occurs when the user clicks on a ribbon tab or clicks on a root menu item.

2. Added a method: SimpleActionItem.Toggle()

This method is used for toggle items. Calling Toggle() will set the button to checked if it's unchecked and it will set the button to unchecked if it's checked. This method has no effect if ToggleGroupKey is null.

3. Added an event: SimpleActionItem.Toggling. This event occurs when a SimpleActionItem is being checked or unchecked.

4. Added a method: SimpleActionItem.OnToggling. This method can be used to raise the Toggling event.

Nov 30, 2011 at 6:48 PM

Change in DotSpatial.Controls.IMap:

Added an event: FunctionModeChanged

This event occurs when the function mode of the map is changed. For example, when user changes from "Zoom" to "Select" or from "Pan" to "Measure" function mode.

Jan 5, 2012 at 8:45 PM

Removed obsolete method from ToolManager.

LoadSettings()

Jan 5, 2012 at 8:50 PM

Used 

ToolManager_NodeMouseDoubleClick

instead of 

protected override void OnDoubleClick(EventArgs e)

in ToolManager
Jan 5, 2012 at 11:05 PM

This was a bit of a change, and important so that DotSpatial.Controls does not reference any 3rd party Dlls.

Made Serialization Manager extensible so that extensions can be used to save and open project files.(DataProviders are for adding layers, so this introduces IOpenProjectFileProvider and ISaveProjectFileProvider)

Moved The MapWindow 4 compatibility code out of the core and into an extension.

Jan 10, 2012 at 11:29 PM

Removed Map Function Mode Measure. This allowed us to move the measure tool to an extension.