MapWindow 4 - Plugins : MapWindow Discussion Forum
Hello everyone, The MapWindow team has just completed developement of a new layout engine for the MapWindow 4 application. It is based on code developed for the new MapWindow 6 and should give you a taste of some of the new functionality that we are developing. The layout files gener
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: March 23, 2010 08:40AM
Hi Everyone,
So its been a little while and I've gotten a few feature request for the layout engine. Some of them easier than others so heres a list of them why don't you guys give me some feedback on prioritizing them (in no particular order)
1) Make layout element list have varying sizes or two columns.
2) Graticules (lat/long) grid over map
3) Zoom in/out with mouse selection box
4) More north arrows (apparently mine aren't very pretty)
5) Brightness / Contrast / Saturation adjustment for bitmap elements
Any other ideas?
Brian
P.S. Tomc I didn't forget about that documentation for the atlas generator I've just been super busy.
Edited 1 time(s). Last edit at 03/23/2010 01:17PM by bmarch.
So its been a little while and I've gotten a few feature request for the layout engine. Some of them easier than others so heres a list of them why don't you guys give me some feedback on prioritizing them (in no particular order)
1) Make layout element list have varying sizes or two columns.
2) Graticules (lat/long) grid over map
3) Zoom in/out with mouse selection box
4) More north arrows (apparently mine aren't very pretty)
5) Brightness / Contrast / Saturation adjustment for bitmap elements
Any other ideas?
Brian
P.S. Tomc I didn't forget about that documentation for the atlas generator I've just been super busy.
Edited 1 time(s). Last edit at 03/23/2010 01:17PM by bmarch.
Re: MapWindow 4 Print Layout Plug-in
Posted by:
pmeems ()
Date: March 24, 2010 02:14AM
Brian,
Not only enhancements are reported, but also some bugs.
It would be nice if those could be fixed first.
Next could be the grid and the axes.
An export to a layered pdf would also be very nice.
Thanks,
Paul
--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group
Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.
---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS
Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl
*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn
Not only enhancements are reported, but also some bugs.
It would be nice if those could be fixed first.
Next could be the grid and the axes.
An export to a layered pdf would also be very nice.
Thanks,
Paul
--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group
Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.
---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS
Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl
*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: March 24, 2010 09:25AM
Hi Paul,
I should definitely look at those bugs, but fixing bugs isn't very fun = )
By Grid you mean graticules right? But what do you mean by axes (or axis) I'm not sure what you mean?
Export to layered PDF is kinda pointless for MW4 since it renders everything to a single bitmap. The best we could do is render each layout element to a separate layer but I don't think that is really what people want. In the MW6 version it would be possible because vector data is actually rendered to the Map Layout Element as vectors (which gave me a lot of trouble because not all printers support GDI+ vectors the same way) But I digress, the reason I never put any native PDF printing support into it was because we can't print vectors in PDFs from version 4 and if a PDF output is really needed a free utility like CutePDF is a much simpler solution. (Couple minutes to install it VS many hours to code something that does the same thing)
Brian
I should definitely look at those bugs, but fixing bugs isn't very fun = )
By Grid you mean graticules right? But what do you mean by axes (or axis) I'm not sure what you mean?
Export to layered PDF is kinda pointless for MW4 since it renders everything to a single bitmap. The best we could do is render each layout element to a separate layer but I don't think that is really what people want. In the MW6 version it would be possible because vector data is actually rendered to the Map Layout Element as vectors (which gave me a lot of trouble because not all printers support GDI+ vectors the same way) But I digress, the reason I never put any native PDF printing support into it was because we can't print vectors in PDFs from version 4 and if a PDF output is really needed a free utility like CutePDF is a much simpler solution. (Couple minutes to install it VS many hours to code something that does the same thing)
Brian
Re: MapWindow 4 Print Layout Plug-in
Posted by:
pmeems ()
Date: March 26, 2010 01:33AM
Brian,
With grid I mean graticules indeed.
With axis I mean something like this:
Gridlines and axis are related.
The image doesn't show to coordinates, but that should be possible as well.
If I'm still not clear, I'll try to explain it to you next week in Orlando ;)
Printing to CutePDF isn't to problem, but that generates a non-layered pdf. But I understand this isn't possible (yet) with MW4.
Thanks,
Paul
--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group
Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.
---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS
Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl
*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn
With grid I mean graticules indeed.
With axis I mean something like this:
Gridlines and axis are related.
The image doesn't show to coordinates, but that should be possible as well.
If I'm still not clear, I'll try to explain it to you next week in Orlando ;)
Printing to CutePDF isn't to problem, but that generates a non-layered pdf. But I understand this isn't possible (yet) with MW4.
Thanks,
Paul
--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group
Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.
---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS
Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl
*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: March 26, 2010 01:19PM
Hi Paul,
Not sure if those are called Axis, I thought they were called "Reference Grid" they usually have numbers in them for one direction and letters for the other and help people find things by looking for ex: Grid A5 etc...
Graticules I understand, they just show the corresponding map lat/long.
Brian
P.S. I updated the layout in MW6 to support saving paper info. We'll need to rebuild the MW4 plug-in now.
Not sure if those are called Axis, I thought they were called "Reference Grid" they usually have numbers in them for one direction and letters for the other and help people find things by looking for ex: Grid A5 etc...
Graticules I understand, they just show the corresponding map lat/long.
Brian
P.S. I updated the layout in MW6 to support saving paper info. We'll need to rebuild the MW4 plug-in now.
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: April 16, 2010 02:04PM
Hi Everyone,
I believe I have just fixed a bug which was causing the Print Layout plug-in to crash when inserting a Map in Windows 7 64bit.
Brian
I believe I have just fixed a bug which was causing the Print Layout plug-in to crash when inserting a Map in Windows 7 64bit.
Brian
Re: MapWindow 4 Print Layout Plug-in
Posted by:
dimpflmoser ()
Date: April 29, 2010 09:39AM
Hello again,
I'd like to start using the PrintPlugIn with my Access-ActiveX application. I tried to follow the Instructions, you gave me earlier in this thread, but I didn't even succeed to register the dll's (I'm working on Win 7 and Access 2007 and installed MapWinGIS47SRa-x86-Setup). So now I'm not sure weather the description still applies with the current version of your printLayout or not (As some of the file-names have changed as well). I downloaded the following files:
-MapWindow6.dll
-MapWinGeoProc.dll
-MapWinInterfaces.dll
-mwLayout.dll
If it's not too nasty of me I would appreciate if you could give an updated instruction ...
Thank you very much in advance
Helmut
I'd like to start using the PrintPlugIn with my Access-ActiveX application. I tried to follow the Instructions, you gave me earlier in this thread, but I didn't even succeed to register the dll's (I'm working on Win 7 and Access 2007 and installed MapWinGIS47SRa-x86-Setup). So now I'm not sure weather the description still applies with the current version of your printLayout or not (As some of the file-names have changed as well). I downloaded the following files:
-MapWindow6.dll
-MapWinGeoProc.dll
-MapWinInterfaces.dll
-mwLayout.dll
If it's not too nasty of me I would appreciate if you could give an updated instruction ...
Thank you very much in advance
Helmut
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: April 29, 2010 02:51PM
Hi Helmut,
I don't know if you are going to be able to use the layout engine in your application. What language is it written in?
Access-ActiveX sounds to me like Visual Basic Application. Which if I am not mistaken is a COM language. Now it is possible to call a .NET library from COM I've never done it mind you but I found a descent tutorial that you might be able to try.
[www.csharpfriends.com]
Let me know what language you're working in. From there I'll have a better idea of how to takle this.
Brian
I don't know if you are going to be able to use the layout engine in your application. What language is it written in?
Access-ActiveX sounds to me like Visual Basic Application. Which if I am not mistaken is a COM language. Now it is possible to call a .NET library from COM I've never done it mind you but I found a descent tutorial that you might be able to try.
[www.csharpfriends.com]
Let me know what language you're working in. From there I'll have a better idea of how to takle this.
Brian
Re: MapWindow 4 Print Layout Plug-in
Posted by:
dimpflmoser ()
Date: April 30, 2010 07:56AM
Hello Brian,
Thank you for your prompt reply, yes, your rightI'm working with vba ...
So now I'm not sure how to proceed for I've done quite a bit of database code. I think there are basically three options:
1) Rewrite the whole thing with MW6 - which is probably the best option on a longer sight.
2) Try to call the assembly from access (which I haven't done so far either) - I could try this, but I have no real idea how to do this, which methods to call etc...
3) Look for an easy way to print out the current window (or copy it to some jpg/png-picture and print that one (as in MapServer).I thimk this could be the short term cure ...
Thanks for your help and I would appreciate every hint and tipp
Helmut
Thank you for your prompt reply, yes, your rightI'm working with vba ...
So now I'm not sure how to proceed for I've done quite a bit of database code. I think there are basically three options:
1) Rewrite the whole thing with MW6 - which is probably the best option on a longer sight.
2) Try to call the assembly from access (which I haven't done so far either) - I could try this, but I have no real idea how to do this, which methods to call etc...
3) Look for an easy way to print out the current window (or copy it to some jpg/png-picture and print that one (as in MapServer).I thimk this could be the short term cure ...
Thanks for your help and I would appreciate every hint and tipp
Helmut
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: April 30, 2010 09:34AM
Hi Helmut,
I've tried to get mwLayout working from within VBA with little success. I finally managed to get a reference to it but it seems that there are no objects inside the library that can be used. I'm not sure why.
If all you need to do is get a screenshot of the map to put into a document you can quite easily do that with the snapshot() method on the map object. Its pretty straight forward to use and there is an example in the wiki.
Brian
I've tried to get mwLayout working from within VBA with little success. I finally managed to get a reference to it but it seems that there are no objects inside the library that can be used. I'm not sure why.
If all you need to do is get a screenshot of the map to put into a document you can quite easily do that with the snapshot() method on the map object. Its pretty straight forward to use and there is an example in the wiki.
Brian
Re: MapWindow 4 Print Layout Plug-in
Posted by:
dimpflmoser ()
Date: April 30, 2010 01:05PM
Hello Brian,
great - that's exactly what I needed so far!
Thank you for your help
Helmut
great - that's exactly what I needed so far!
Thank you for your help
Helmut
Re: MapWindow 4 Print Layout Plug-in
Posted by:
Russ Poncher ()
Date: June 16, 2010 04:51PM
bmarch Wrote:
-------------------------------------------------------
>
> The Complicated one:
>
> Now if you want to use the individual components
> of the layout, just right click in your toolbox
> click choose items and browse to
> MapWinInterfaces.dll then layout.dll you'll get a
> bunch of new stuff, some of them are for MapWindow
> 6 and probably wont work here. What you want are
> the items that start with Layout... There are two
> LayoutControl (You must use the one that ends with
> MW4 the other one is for MapWindow 6)
>
> Once you've done that you can drag and drog
> Layout... pieces onto your form. When you've
> gotten them all placed, click on the
> LayoutControlMW4 control that you placed and set
> all of the Misc properties to appropriate
> Layout... things. Even you aren't going to use one
> leave it blank.
>
> Next in code you must call
>
> LayoutControlMW4.Initialize(ref axMap1,ref legend,
> ref mapunit);
>
> Or the layout control wont be connected to a map.
>
>
> If you've got any questions just post them in here
> and I'll try and help you out. Please remember
> this very beta, so if you get some weird behavior
> please let me know.
>
> Brian
>
> Oh and everyone who is using the plug-in please
> play with it some more and make sure I didn't
> break anything with these modifications.
Brian,
Are there any examples of how to do this anywhere?
Thanks,
Russ
-------------------------------------------------------
>
> The Complicated one:
>
> Now if you want to use the individual components
> of the layout, just right click in your toolbox
> click choose items and browse to
> MapWinInterfaces.dll then layout.dll you'll get a
> bunch of new stuff, some of them are for MapWindow
> 6 and probably wont work here. What you want are
> the items that start with Layout... There are two
> LayoutControl (You must use the one that ends with
> MW4 the other one is for MapWindow 6)
>
> Once you've done that you can drag and drog
> Layout... pieces onto your form. When you've
> gotten them all placed, click on the
> LayoutControlMW4 control that you placed and set
> all of the Misc properties to appropriate
> Layout... things. Even you aren't going to use one
> leave it blank.
>
> Next in code you must call
>
> LayoutControlMW4.Initialize(ref axMap1,ref legend,
> ref mapunit);
>
> Or the layout control wont be connected to a map.
>
>
> If you've got any questions just post them in here
> and I'll try and help you out. Please remember
> this very beta, so if you get some weird behavior
> please let me know.
>
> Brian
>
> Oh and everyone who is using the plug-in please
> play with it some more and make sure I didn't
> break anything with these modifications.
Brian,
Are there any examples of how to do this anywhere?
Thanks,
Russ
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: June 18, 2010 01:45PM
Hi Russ,
The best example that has been written at the moment is the mwLayout plug-in form. Which is part of the layout plug-in. You can grab the source code for it from the mapwindow svn here: [svn.mapwindow.org]
If you were looking for a step by step tutorial unfortunatly none has been written so far. But if you look at the code in there for LayoutFormMW4.vb it shows you how all the layout components link together.
Brian
The best example that has been written at the moment is the mwLayout plug-in form. Which is part of the layout plug-in. You can grab the source code for it from the mapwindow svn here: [svn.mapwindow.org]
If you were looking for a step by step tutorial unfortunatly none has been written so far. But if you look at the code in there for LayoutFormMW4.vb it shows you how all the layout components link together.
Brian
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: October 05, 2010 12:08PM
Hi Everyone,
Its been some time since I've published any changes to the layout engine. I just finished some pretty big changes which hopefully you guys will find useful.
1) First I've fixed a bug which was causing the graphic patches that go beside the text in a legend to be too large and offset.
2) I've finished work on the vector rendering. Previously maps were rendered to bitmaps and then sent to the printer. Now there is the option of using a new vector rendering engine for both the map and the legend.
As usual my changes are committed to the SVN but they make take a little while to end up in a beta installer. So if you're feeling courageous please give it a try.
For those of you who may have been using the map renderer in the plug-in in your own projects. Please not that the method signatures have changed so that you can specify if they should use the new vector rendering.
I've got some other fixes coming along but they will have to wait until the layout plugin transitions to using the new DotSpatial libraries.
Brian
Its been some time since I've published any changes to the layout engine. I just finished some pretty big changes which hopefully you guys will find useful.
1) First I've fixed a bug which was causing the graphic patches that go beside the text in a legend to be too large and offset.
2) I've finished work on the vector rendering. Previously maps were rendered to bitmaps and then sent to the printer. Now there is the option of using a new vector rendering engine for both the map and the legend.
As usual my changes are committed to the SVN but they make take a little while to end up in a beta installer. So if you're feeling courageous please give it a try.
For those of you who may have been using the map renderer in the plug-in in your own projects. Please not that the method signatures have changed so that you can specify if they should use the new vector rendering.
I've got some other fixes coming along but they will have to wait until the layout plugin transitions to using the new DotSpatial libraries.
Brian
Re: MapWindow 4 Print Layout Plug-in
Posted by:
mkohlerpsl ()
Date: January 20, 2011 07:43AM
I am using MW 4.8.1 and have not been able to get the layout plug-in to load. When I go to the plug-in menu the Layout tool isn't there. I see it in the ProgramFiles\MapWindow\ApplicationPlugins\mwLayout.... but it's not loading.
The layout might be the only thing holding me back from proposing more solutions using Map Window. Please help.
thanks,
Mike
The layout might be the only thing holding me back from proposing more solutions using Map Window. Please help.
thanks,
Mike
Re: MapWindow 4 Print Layout Plug-in
Posted by:
pmeems ()
Date: January 24, 2011 04:16AM
Mike,
Because the plug-in is an application plug-in it is always loaded and it doesn't show up in the plug-ins menu.
If you hit the print button or go to File --> Print the lay-out plug-in should come up.
It might be wise to download the latest beta installer: tinyurl.com/mwMonthly
--
Paul
--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group
Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.
---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS
Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl
*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn
Because the plug-in is an application plug-in it is always loaded and it doesn't show up in the plug-ins menu.
If you hit the print button or go to File --> Print the lay-out plug-in should come up.
It might be wise to download the latest beta installer: tinyurl.com/mwMonthly
--
Paul
--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group
Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.
---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS
Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl
*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn
Re: MapWindow 4 Print Layout Plug-in
Posted by:
mmayo18 ()
Date: March 06, 2011 08:39AM
Brian;
I am trying to run the MW 4 Print Layout Plug-in but have so far been unsuccessful. I am running MW v4.7.909 (3/16/2009) 64 Bit Version on Windows Vista Home Premium SP2 64 Bit OS. I have downloaded all the files on
[svn.mapwindow.org] and placed the maplayout.dll in the ApplicationPlugins folder in C:\Program Files (x86)\MapWindow\ApplicationPlugins.
Is there an issues with this plugin with the 64 Bit OS? I am having issues with other plugins as well.
Regards
-Matt
I am trying to run the MW 4 Print Layout Plug-in but have so far been unsuccessful. I am running MW v4.7.909 (3/16/2009) 64 Bit Version on Windows Vista Home Premium SP2 64 Bit OS. I have downloaded all the files on
[svn.mapwindow.org] and placed the maplayout.dll in the ApplicationPlugins folder in C:\Program Files (x86)\MapWindow\ApplicationPlugins.
Is there an issues with this plugin with the 64 Bit OS? I am having issues with other plugins as well.
Regards
-Matt
Re: MapWindow 4 Print Layout Plug-in
Posted by:
jescott2 ()
Date: March 06, 2011 01:16PM
Kudos for the Print Layout Plug-in. Although I had problems getting Insert Map to work that was a problem related to a partial uninstall of an old version of MapWindow. I am using 4.8.1 (or is it 4.8.2) and the Plug-in seems to work as intended. I look forward to the inclusion of Grid lines (in feet, meters or Lat/Long) in the future. (In DotSpatial if it will every be a user platform?)
Joel
Joel
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: March 08, 2011 12:59PM
Hi Matt,
There no particular reason why it won't work on a 64bit system. Why are you using the SVN and not one of the installers that Paul has made?
The only thing to check is that you have .NET 3.5 installed and that all the required DLLs are present in the ApplicationPlugins\mwLayout folder. It should include the following two files at a minumum: MapWindow6.dll and mwLayout.dll
Brian M.
There no particular reason why it won't work on a 64bit system. Why are you using the SVN and not one of the installers that Paul has made?
The only thing to check is that you have .NET 3.5 installed and that all the required DLLs are present in the ApplicationPlugins\mwLayout folder. It should include the following two files at a minumum: MapWindow6.dll and mwLayout.dll
Brian M.
Re: MapWindow 4 Print Layout Plug-in
Posted by:
bmarch ()
Date: March 08, 2011 01:02PM
Hi Joel,
I'm glad that you got it to work nicely, I know it was giving people some trouble. The grid lines are on my list of things to do. There are a few other bugs that of higher priority for the moment but I'll hopefully get to it sooner or later.
Brian M.
I'm glad that you got it to work nicely, I know it was giving people some trouble. The grid lines are on my list of things to do. There are a few other bugs that of higher priority for the moment but I'll hopefully get to it sooner or later.
Brian M.
Sorry, only registered users may post in this forum.


