User Tools

Site Tools


thinkgeo.mapsuite.core.extenthelper

This is an old revision of the document!


Table of Contents

ThinkGeo.MapSuite.Core.ExtentHelper

<!– Class –> This static class exposes a number of helpful methods when dealing with extents.

Inheritance Hierarchy

Members Summary

Public Constructors

Name Parameters DeclaringType Summary

Protected Constructors

Name Parameters DeclaringType Summary

Public Methods

Name Parameters DeclaringType Summary
Public MethodStatic MemberCenterAt RectangleShape, PointShape, Single, Single This is a static function that allows you to pass in a world rectangle, a world point to center on, and a height and width in screen units. The function will center the rectangle based on the point, then adjust the rectangle's ratio based on the height and width in screen coordinates.
Public MethodStatic MemberCenterAt RectangleShape, Feature, Single, Single This is a static function that allows you to pass in a world rectangle, a world point to center on, and a height and width in screen units. The function will center the rectangle based on the point, then adjust the rectangle's ratio based on the height and width in screen coordinates.
Public MethodStatic MemberCenterAt RectangleShape, Single, Single, Single, Single This method returns an adjusted extent centered on a point.
Public MethodEquals Object Object
Public MethodStatic MemberGetBoundingBoxOfItems IEnumerable<BaseShape> This API gets the BoundingBox of a group of BaseShapes.
Public MethodStatic MemberGetBoundingBoxOfItems IEnumerable<Feature> This API gets the BoundingBox of a group of Features.
Public MethodStatic MemberGetDrawingExtent RectangleShape, Single, Single This method returns an adjusted extent based on the ratio of the screen width and height.
Public MethodGetHashCode Object
Public MethodStatic MemberGetScale RectangleShape, Single, GeographyUnit This method returns the current scale.
Public MethodStatic MemberGetScale RectangleShape, Single, GeographyUnit, Single This method returns the current scale.
Public MethodStatic MemberGetScreenDistanceBetweenTwoWorldPoints RectangleShape, PointShape, PointShape, Single, Single This method returns the number of pixels between two world points.
Public MethodStatic MemberGetScreenDistanceBetweenTwoWorldPoints RectangleShape, Feature, Feature, Single, Single This method returns the number of pixels between two features.
Public MethodGetType Object
Public MethodStatic MemberGetWorldDistanceBetweenTwoScreenPoints RectangleShape, ScreenPointF, ScreenPointF, Single, Single, GeographyUnit, DistanceUnit This method returns the distance in world units between two screen points.
Public MethodStatic MemberGetWorldDistanceBetweenTwoScreenPoints RectangleShape, Single, Single, Single, Single, Single, Single, GeographyUnit, DistanceUnit This method returns the distance in world units between two screen points.
Public MethodStatic MemberPan RectangleShape, Single, Int32 This method returns a panned extent.
Public MethodStatic MemberPan RectangleShape, PanDirection, Int32 This method returns a panned extent.
Public MethodStatic MemberResizeExtent RectangleShape, Single, Single, Single, GeographyUnit, MapResizeMode This method returns a RectangleShape by resize parameters.
Public MethodStatic MemberSnapToZoomLevel RectangleShape, GeographyUnit, Single, Single, ZoomLevelSet This method returns an extent that is snapped to a zoom level in the provided zoom level set.
Public MethodStatic MemberToScreenCoordinate RectangleShape, Double, Double, Single, Single This method returns screen coordinates from world coordinates.
Public MethodStatic MemberToScreenCoordinate RectangleShape, RectangleShape, Single, Single This method returns Rectangle in screen coordinates from RectangleShape in world coordinates.
Public MethodStatic MemberToScreenCoordinate RectangleShape, PointShape, Single, Single This method returns screen coordinates from world coordinates.
Public MethodStatic MemberToScreenCoordinate RectangleShape, Feature, Single, Single This method returns screen coordinates from world coordinates.
Public MethodToString Object
Public MethodStatic MemberToWorldCoordinate RectangleShape, Single, Single, Single, Single This method returns world coordinates from screen coordinates.
Public MethodStatic MemberToWorldCoordinate RectangleShape, ScreenPointF, Single, Single This method returns world coordinates from screen coordinates.
Public MethodStatic MemberZoomIn RectangleShape, Int32 This method returns a new extent that is zoomed in by the percentage provided.
Public MethodStatic MemberZoomIntoCenter RectangleShape, Int32, PointShape, Single, Single This method returns an extent that is centered and zoomed in.
Public MethodStatic MemberZoomIntoCenter RectangleShape, Int32, Feature, Single, Single This method returns an extent that is centered and zoomed.
Public MethodStatic MemberZoomIntoCenter RectangleShape, Int32, Single, Single, Single, Single This method returns an extent that is centered and zoomed in.
Public MethodStatic MemberZoomIntoOffsetPoint RectangleShape, Single, Single, ScreenPointF, Int32 This method returns an extent that is keeping the offsetScreenPoint constant and zoomed.
Public MethodStatic MemberZoomOut RectangleShape, Int32 This method returns a new extent that is zoomed out by the percentage provided.
Public MethodStatic MemberZoomOutToCenter RectangleShape, Int32, PointShape, Single, Single This method returns an extent that is centered and zoomed out.
Public MethodStatic MemberZoomOutToCenter RectangleShape, Int32, Feature, Single, Single This method returns an extent that is centered and zoomed out.
Public MethodStatic MemberZoomOutToCenter RectangleShape, Int32, Single, Single, Single, Single This method returns an extent that is centered and zoomed out.
Public MethodStatic MemberZoomOutToOffsetPoint RectangleShape, Single, Single, ScreenPointF, Int32 This method returns an extent that is keeping the offsetScreenPoint constant and zoomed.
Public MethodStatic MemberZoomToScale Double, RectangleShape, GeographyUnit, Single, Single, ScreenPointF This method returns a extent that has been zoomed into a certain scale.
Public MethodStatic MemberZoomToScale Double, RectangleShape, GeographyUnit, Single, Single This method returns a extent that has been zoomed into a certain scale.

Protected Methods

Name Parameters DeclaringType Summary
Protected MethodFinalize Object
Protected MethodMemberwiseClone Object

Public Properties

Name Return DeclaringType Summary

Protected Properties

Name Return DeclaringType Summary

Public Events

Name Event Arguments DeclaringType Summary

Public Constructors

Protected Constructors

Public Methods

CenterAt(RectangleShape, PointShape, Single, Single)

<!– static –> This is a static function that allows you to pass in a world rectangle, a world point to center on, and a height and width in screen units. The function will center the rectangle based on the point, then adjust the rectangle's ratio based on the height and width in screen coordinates.

Overloads

This overload allows you to pass in a world point as the center.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an adjusted extent centered on a point.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the current extent you want to center.
worldPoint PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This parameter is the world point you want to center on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

CenterAt(RectangleShape, Feature, Single, Single)

<!– static –> This is a static function that allows you to pass in a world rectangle, a world point to center on, and a height and width in screen units. The function will center the rectangle based on the point, then adjust the rectangle's ratio based on the height and width in screen coordinates.

Overloads

This overload allows you to pass in a world point as the center.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an adjusted extent centered on a point.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the current extent you want to center.
centerFeature Feature<!– ThinkGeo.MapSuite.Core.Feature –> This parameter is the world point you want to center on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

CenterAt(RectangleShape, Single, Single, Single, Single)

<!– static –> This method returns an adjusted extent centered on a point.

Overloads

This overload allows you to pass in a screen point as the center.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an adjusted extent centered on a point.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the current extent you want to center.
screenX Single<!– System.Single –> This parameter is the X coordinate on the screen to center on.
screenY Single<!– System.Single –> This parameter is the Y coordinate on the screen to center on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

Equals(Object)

Return Value

Return Type Description
Boolean<!– System.Boolean –>

Parameters

Name Type Description
obj Object<!– System.Object –>

<!– System.Object –> Go Back

GetBoundingBoxOfItems(IEnumerable<BaseShape>)

<!– static –> This API gets the BoundingBox of a group of BaseShapes.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> The BoundingBox that contains all of the shapes you passed in.

Parameters

Name Type Description
shapes IEnumerable<BaseShape><!– System.Collections.Generic.IEnumerable{ThinkGeo.MapSuite.Core.BaseShape} –> The target group of BaseShapes to get the BoundingBox for.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetBoundingBoxOfItems(IEnumerable<Feature>)

<!– static –> This API gets the BoundingBox of a group of Features.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> The BoundingBox that contains all the features you passed in.

Parameters

Name Type Description
features IEnumerable<Feature><!– System.Collections.Generic.IEnumerable{ThinkGeo.MapSuite.Core.Feature} –> The target group of Features to get the BoundingBox for.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetDrawingExtent(RectangleShape, Single, Single)

<!– static –> This method returns an adjusted extent based on the ratio of the screen width and height.

Remarks

This function is used because the extent to draw must be the rame ratio as the screen width and height. If they are not, then the image drawn will be stretched or compressed. We always adjust the extent upwards to ensure that no matter how we adjust it, the original extent will fit within the new extent. This ensures that everything you wanted to see in the first extent is visible and maybe a bit more.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an adjusted extent based on the ratio of the screen width and height.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to adjust for drawing.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetHashCode()

Return Value

Return Type Description
Int32<!– System.Int32 –>

Parameters

Name Type Description

<!– System.Object –> Go Back

GetScale(RectangleShape, Single, GeographyUnit)

<!– static –> This method returns the current scale.

Return Value

Return Type Description
Double<!– System.Double –> This method returns the current scale.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to find the scale for.
screenWidth Single<!– System.Single –> This parameter is the screen width.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This parameter is the unit of the world extent.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetScale(RectangleShape, Single, GeographyUnit, Single)

<!– static –> This method returns the current scale.

Return Value

Return Type Description
Double<!– System.Double –> This method returns the current scale.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to find the scale for.
screenWidth Single<!– System.Single –> This parameter is the screen width.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This parameter is the unit of the world extent.
dpi Single<!– System.Single –> This parameter is the dpi of the world extent.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetScreenDistanceBetweenTwoWorldPoints(RectangleShape, PointShape, PointShape, Single, Single)

<!– static –> This method returns the number of pixels between two world points.

Return Value

Return Type Description
Single<!– System.Single –> This method returns the number of pixels between two world points.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
worldPoint1 PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This parameter is the first point – the one you want to measure from.
worldPoint2 PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This parameter is the second point – the one you want to measure to.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetScreenDistanceBetweenTwoWorldPoints(RectangleShape, Feature, Feature, Single, Single)

<!– static –> This method returns the number of pixels between two features.

Return Value

Return Type Description
Single<!– System.Single –> This method returns the number of pixels between two features.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
worldPointFeature1 Feature<!– ThinkGeo.MapSuite.Core.Feature –> This parameter is the first feature – the one you want to measure from.
worldPointFeature2 Feature<!– ThinkGeo.MapSuite.Core.Feature –> This parameter is the second feature – the one you want to measure to.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetType()

Return Value

Return Type Description
Type<!– System.Type –>

Parameters

Name Type Description

<!– System.Object –> Go Back

GetWorldDistanceBetweenTwoScreenPoints(RectangleShape, ScreenPointF, ScreenPointF, Single, Single, GeographyUnit, DistanceUnit)

<!– static –> This method returns the distance in world units between two screen points.

Overloads

This overload allows you to pass in ScreenPointF as the points.

Return Value

Return Type Description
Double<!– System.Double –> This method returns the distance in world units between two screen points.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
screenPoint1 ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This is the screen point you want to measure from.
screenPoint2 ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This is the screen point you want to measure to.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This is the geographic unit of the world extent rectangle.
distanceUnit DistanceUnit<!– ThinkGeo.MapSuite.Core.DistanceUnit –> This is the geographic unit you want the result to show in.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

GetWorldDistanceBetweenTwoScreenPoints(RectangleShape, Single, Single, Single, Single, Single, Single, GeographyUnit, DistanceUnit)

<!– static –> This method returns the distance in world units between two screen points.

Overloads

This overload allows you to pass in the X & Y for each point.

Return Value

Return Type Description
Double<!– System.Double –>

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
screenPoint1X Single<!– System.Single –> This parameter is the X of the point you want to measure from.
screenPoint1Y Single<!– System.Single –> This parameter is the Y of the point you want to measure from.
screenPoint2X Single<!– System.Single –> This parameter is the X of the point you want to measure to.
screenPoint2Y Single<!– System.Single –> This parameter is the Y of the point you want to measure to.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This is the geographic unit of the world extent you passed in.
distanceUnit DistanceUnit<!– ThinkGeo.MapSuite.Core.DistanceUnit –> This is the geographic unit you want the result to show in.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

Pan(RectangleShape, Single, Int32)

<!– static –> This method returns a panned extent.

Overloads

This overload allows you to pass in an angle and a percentage by which you want to pan.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a panned extent.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to pan.
degree Single<!– System.Single –> This parameter is the degree you want to pan.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to pan.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

Pan(RectangleShape, PanDirection, Int32)

<!– static –> This method returns a panned extent.

Overloads

This overload allows you to pass in a direction and a percentage by which you want to pan.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a panned extent.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to pan.
direction PanDirection<!– ThinkGeo.MapSuite.Core.PanDirection –> This parameter is the direction in which you want to pan.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to pan.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ResizeExtent(RectangleShape, Single, Single, Single, GeographyUnit, MapResizeMode)

<!– static –> This method returns a RectangleShape by resize parameters.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a RectangleShape by resize parameters.

Parameters

Name Type Description
sourceExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> The rectangle shape before rezise
sourceScreenWidth Single<!– System.Single –> The width of the source rectangle shape in screen coordinate
targetScreenWidth Single<!– System.Single –> The width of the target rectangle shape in screen coordinate
targetScreenHeight Single<!– System.Single –> The height of the target rectangle shape in screen coordinate
mapUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> map unit which this rectangle shape used
resizeType MapResizeMode<!– ThinkGeo.MapSuite.Core.MapResizeMode –> Represents resize type which can decide to use which way to resize.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

SnapToZoomLevel(RectangleShape, GeographyUnit, Single, Single, ZoomLevelSet)

<!– static –> This method returns an extent that is snapped to a zoom level in the provided zoom level set.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is snapped to a zoom level in the provided zoom level set.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want snapped.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This parameter is the geographic unit of the world extent parameter.
screenWidth Single<!– System.Single –> This parameter is the screen width.
screenHeight Single<!– System.Single –> This parameter is the screen height.
zoomLevelSet ZoomLevelSet<!– ThinkGeo.MapSuite.Core.ZoomLevelSet –> This parameter is the set of zoom levels you want to snap to.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ToScreenCoordinate(RectangleShape, Double, Double, Single, Single)

<!– static –> This method returns screen coordinates from world coordinates.

Overloads

This overload allows you to pass in world X & Y coordinates.

Return Value

Return Type Description
ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This method returns screen coordinates from world coordinates.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
worldX Double<!– System.Double –> This parameter is the world X you want converted to screen points.
worldY Double<!– System.Double –> This parameter is the world Y you want converted to screen points.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ToScreenCoordinate(RectangleShape, RectangleShape, Single, Single)

<!– static –> This method returns Rectangle in screen coordinates from RectangleShape in world coordinates.

Return Value

Return Type Description
Rectangle<!– System.Drawing.Rectangle –> This method returns Rectangle in screen coordinates from RectangleShape in world coordinates.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
targetExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the rectangle shape in world coordinate you want converted to a rectangle in screen coordinate.
currentExtentWidth Single<!– System.Single –> This parameter is the width of the screen.
currentExtentHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ToScreenCoordinate(RectangleShape, PointShape, Single, Single)

<!– static –> This method returns screen coordinates from world coordinates.

Return Value

Return Type Description
ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This method returns screen coordinates from world coordinates.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
worldPoint PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This parameter is the world point you want converted to a screen point.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ToScreenCoordinate(RectangleShape, Feature, Single, Single)

<!– static –> This method returns screen coordinates from world coordinates.

Return Value

Return Type Description
ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This method returns screen coordinates from world coordinates.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
worldPointFeature Feature<!– ThinkGeo.MapSuite.Core.Feature –> This parameter is the feature you want converted to a screen point.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ToString()

Return Value

Return Type Description
String<!– System.String –>

Parameters

Name Type Description

<!– System.Object –> Go Back

ToWorldCoordinate(RectangleShape, Single, Single, Single, Single)

<!– static –> This method returns world coordinates from screen coordinates.

Return Value

Return Type Description
PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This method returns world coordinates from screen coordinates.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
screenX Single<!– System.Single –> This parameter is the X of the point you want converted to world coordinates.
screenY Single<!– System.Single –> This parameter is the Y of the point you want converted to world coordinates.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ToWorldCoordinate(RectangleShape, ScreenPointF, Single, Single)

<!– static –> This method returns world coordinates from screen coordinates.

Return Value

Return Type Description
PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This method returns world coordinates from screen coordinates.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent.
screenPoint ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This parameter is the screen point you want converted to a world point.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomIn(RectangleShape, Int32)

<!– static –> This method returns a new extent that is zoomed in by the percentage provided.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a new extent that is zoomed in by the percentage provided.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to zoom to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom in.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomIntoCenter(RectangleShape, Int32, PointShape, Single, Single)

<!– static –> This method returns an extent that is centered and zoomed in.

Overloads

This overload allows you to pass in the height and width in screen coordinates, as well as a world point.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to call GetDrawingExtent afterwards.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is centered and zoomed in.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent that you want centered and zoomed to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom in.
worldPoint PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This parameter is the world point you want the extent to be centered on.
screenWidth Single<!– System.Single –> This parameter is the width in screen coordinates.
screenHeight Single<!– System.Single –> This parameter is the height in screen coordinates.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomIntoCenter(RectangleShape, Int32, Feature, Single, Single)

<!– static –> This method returns an extent that is centered and zoomed.

Overloads

This overload allows you to pass in the height and width in screen coordinatesm as well as a feature.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to call GetDrawingExtent afterwards.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is centered and zoomed in.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent that you want centered and zoomed to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom in.
centerFeature Feature<!– ThinkGeo.MapSuite.Core.Feature –> This parameter is the feature you want the extent to be centered on.
screenWidth Single<!– System.Single –> This parameter is the width in screen coordinates.
screenHeight Single<!– System.Single –> This parameter is the height in screen coordinates.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomIntoCenter(RectangleShape, Int32, Single, Single, Single, Single)

<!– static –> This method returns an extent that is centered and zoomed in.

Overloads

This overload allows you to pass in the height and width in screen coordinates, as well as a screen X & Y.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to call GetDrawingExtent afterwards.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is centered and zoomed in.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to center and zoom to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom in.
screenX Single<!– System.Single –> This parameter is the screen X you want to center on.
screenY Single<!– System.Single –> This parameter is the screen Y you want to center on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomIntoOffsetPoint(RectangleShape, Single, Single, ScreenPointF, Int32)

<!– static –> This method returns an extent that is keeping the offsetScreenPoint constant and zoomed.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to afterward call GetDrawingExtent.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is keeping the offsetScreenPoint constant and zoomed.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent that you want centered and zoomed.
screenWidth Single<!– System.Single –> This parameter is the width in screen coordinates.
screenHeight Single<!– System.Single –> This parameter is the height in screen coordinates.
offsetScreenPoint ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This parameter is the screen point you want to keep it constant.
percentage Int32<!– System.Int32 –> This parameter is the percentage you want to zoom.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomOut(RectangleShape, Int32)

<!– static –> This method returns a new extent that is zoomed out by the percentage provided.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a new extent that is zoomed out by the percentage provided.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to zoom out to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom out.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomOutToCenter(RectangleShape, Int32, PointShape, Single, Single)

<!– static –> This method returns an extent that is centered and zoomed out.

Overloads

This overload allows you to pass in the height and width in screen coordinates, as well as a world point.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to call GetDrawingExtent afterwards.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is centered and zoomed out.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to center and zoom out to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom out.
worldPoint PointShape<!– ThinkGeo.MapSuite.Core.PointShape –> This parameter is the world point you want the extent to be centered on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomOutToCenter(RectangleShape, Int32, Feature, Single, Single)

<!– static –> This method returns an extent that is centered and zoomed out.

Overloads

This overload allows you to pass in the height and width in screen coordinates, as well as a feature.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to call GetDrawingExtent afterwards.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is centered and zoomed out.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to center and zoom out to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom out.
centerFeature Feature<!– ThinkGeo.MapSuite.Core.Feature –> This parameter is the feature you want the extent to be centered on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomOutToCenter(RectangleShape, Int32, Single, Single, Single, Single)

<!– static –> This method returns an extent that is centered and zoomed out.

Overloads

This overload allows you to pass in the height and width in screen coordinates, as well as a screen X & Y.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to call GetDrawingExtent afterward.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is centered and zoomed out.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want to center and zoom out to.
percentage Int32<!– System.Int32 –> This parameter is the percentage by which you want to zoom out.
screenX Single<!– System.Single –> This parameter is the screen X you want to center on.
screenY Single<!– System.Single –> This parameter is the screen Y you want to center on.
screenWidth Single<!– System.Single –> This parameter is the width of the screen.
screenHeight Single<!– System.Single –> This parameter is the height of the screen.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomOutToOffsetPoint(RectangleShape, Single, Single, ScreenPointF, Int32)

<!– static –> This method returns an extent that is keeping the offsetScreenPoint constant and zoomed.

Remarks

The resulting rectangle will already be adjusted for the ratio of the screen. You do not need to afterward call GetDrawingExtent.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns an extent that is keeping the offsetScreenPoint constant and zoomed.

Parameters

Name Type Description
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent that you want centered and zoomed.
screenWidth Single<!– System.Single –> This parameter is the width in screen coordinates.
screenHeight Single<!– System.Single –> This parameter is the height in screen coordinates.
offsetScreenPoint ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This parameter is the screen point you want to keep it constant.
percentage Int32<!– System.Int32 –> This parameter is the percentage you want to zoom.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomToScale(Double, RectangleShape, GeographyUnit, Single, Single, ScreenPointF)

<!– static –> This method returns a extent that has been zoomed into a certain scale.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a extent that has been zoomed into a certain scale.

Parameters

Name Type Description
targetScale Double<!– System.Double –> This parameter is the scale you want to zoom into.
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want zoomed into the scale.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This parameter is the geographic unit of the world extent parameter.
screenWidth Single<!– System.Single –> This parameter is the screen width.
screenHeight Single<!– System.Single –> This parameter is the screen height.
offsetScreenPoint ScreenPointF<!– ThinkGeo.MapSuite.Core.ScreenPointF –> This parameter is the offsetScreenPoint.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

ZoomToScale(Double, RectangleShape, GeographyUnit, Single, Single)

<!– static –> This method returns a extent that has been zoomed into a certain scale.

Return Value

Return Type Description
RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This method returns a extent that has been zoomed into a certain scale.

Parameters

Name Type Description
targetScale Double<!– System.Double –> This parameter is the scale you want to zoom into.
worldExtent RectangleShape<!– ThinkGeo.MapSuite.Core.RectangleShape –> This parameter is the world extent you want zoomed into the scale.
worldExtentUnit GeographyUnit<!– ThinkGeo.MapSuite.Core.GeographyUnit –> This parameter is the geographic unit of the world extent parameter.
screenWidth Single<!– System.Single –> This parameter is the screen width.
screenHeight Single<!– System.Single –> This parameter is the screen height.

<!– ThinkGeo.MapSuite.Core.ExtentHelper –> Go Back

Protected Methods

Finalize()

Return Value

Return Type Description
Void<!– System.Void –>

Parameters

Name Type Description

<!– System.Object –> Go Back

MemberwiseClone()

Return Value

Return Type Description
Object<!– System.Object –>

Parameters

Name Type Description

<!– System.Object –> Go Back

Public Properties

Protected Properties

Public Events

thinkgeo.mapsuite.core.extenthelper.1440040128.txt.gz · Last modified: 2015/09/17 08:59 (external edit)