[mapguide-internals] generateplot bug in php api?
Walt Welton-Lair
walt.welton-lair at autodesk.com
Thu Mar 22 19:56:19 EDT 2007
The code which decides which version of GeneratePlot to call is
autogenerated SWIG code. Something must be wrong in the logic it uses.
-----Original Message-----
From: mapguide-internals-bounces at lists.osgeo.org
[mailto:mapguide-internals-bounces at lists.osgeo.org] On Behalf Of Paul
Spencer (External)
Sent: Friday, March 23, 2007 12:52 AM
To: MapGuide Internals Mail List
Subject: Re: [mapguide-internals] generateplot bug in php api?
I guess in this specific case I want to set the map extents by
bounding box or center and scale for some temporary operation and not
actually save it. This is useful only because of a bug in the
generateplot api bindings I guess. I hadn't noticed a lack of this
functionality before now ;)
I can't think of any other normal use case offhand where I couldn't
set the extents using the getvisiblemapextents operation in the
mapagent. It might be more convenient in some complex operations to
set it through the API while processing server-side code, but then
getting the change back to the client side would be problematic.
Overall I agree with the lack of this functionality in the API I
think. If you could fix the bug, then I would stop complaining!!!
Cheers
Paul
On 22-Mar-07, at 6:34 PM, Trevor Wekel wrote:
> Hi Paul,
>
> Setting the viewed extents from a web extensions script is a little
> tricky. Currently, the AJAX and DWF viewers drive changes in
> center and
> scale. Setting extents programmatically does change the center and
> scale for the map. This makes the viewer interaction model more
> complicated since there are now two driving mechanisms involved for
> two
> different viewers. What happens if a web extensions script executes a
> zoom while the user is panning? Which interaction should win?
>
>
> -----Original Message-----
> From: mapguide-internals-bounces at lists.osgeo.org
> [mailto:mapguide-internals-bounces at lists.osgeo.org] On Behalf Of Paul
> Spencer (External)
> Sent: Thursday, March 22, 2007 2:01 PM
> To: MapGuide Internals Mail List
> Subject: [mapguide-internals] generateplot bug in php api?
>
> Hi all,
>
> In the API documentation, there are three potential signatures for the
> generateplot function. It seems that the second signature will not
> work
> in PHP due to an error in the swig bindings:
>
> virtual MgByteReader * GeneratePlot (MgMap *map, MgCoordinate
> *center, double scale, MgPlotSpecification *plotSpec, MgLayout
> *layout,
> MgDwfVersion *dwfVersion)
>
> Calling this function results in a PHP Fatal error: Arguments passed
> did not match any overload for method
> _wrap_MgMappingService_GeneratePlot
>
> The other signatures seem to work. So in an effort to work around
> this,
> we decided it would be easier to temporarily zoom the map to a center
> point and scale and use GeneratePlot (MgMap *map, MgPlotSpecification
> *plotSpec, MgLayout *layout, MgDwfVersion
> *dwfVersion) that to calculate the extents from the center point and
> scale.
>
> Perhaps it is just me, but there is actually no way to change the
> extents of a MgMap object in the PHP API! It seems very odd that you
> cannot call SetExtents() or SetView() or something on the MgMap
> object!
> What have I overlooked?
>
> Cheers
>
> Paul
> +-----------------------------------------------------------------+
> |Paul Spencer pspencer at dmsolutions.ca |
> +-----------------------------------------------------------------+
> |Chief Technology Officer |
> |DM Solutions Group Inc http://www.dmsolutions.ca/ |
> +-----------------------------------------------------------------+
>
>
>
>
> _______________________________________________
> mapguide-internals mailing list
> mapguide-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-internals
>
> _______________________________________________
> mapguide-internals mailing list
> mapguide-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-internals
+-----------------------------------------------------------------+
|Paul Spencer pspencer at dmsolutions.ca |
+-----------------------------------------------------------------+
|Chief Technology Officer |
|DM Solutions Group Inc http://www.dmsolutions.ca/ |
+-----------------------------------------------------------------+
_______________________________________________
mapguide-internals mailing list
mapguide-internals at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapguide-internals
More information about the mapguide-internals
mailing list