本文整理汇总了C#中PointLatLng类的典型用法代码示例。如果您正苦于以下问题:C# PointLatLng类的具体用法?C# PointLatLng怎么用?C# PointLatLng使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
PointLatLng类属于命名空间,在下文中一共展示了PointLatLng类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GMapMarkerCross
public GMapMarkerCross(PointLatLng p)
: base(p)
{
#if !PocketPC
Pen = new Pen(Brushes.Red, 1);
#else
Pen = new Pen(Color.Red, 1);
#endif
}
示例2: GMapMarkerRect
public GMapMarkerRect(PointLatLng p)
: base(p)
{
Pen = new Pen(Brushes.Transparent, 5);
// do not forget set Size of the marker
// if so, you shall have no event on it ;}
Size = new System.Drawing.Size(20, 20);
Offset = new System.Drawing.Point(-Size.Width / 2, -Size.Height / 2);
}
示例3: GMarkerCross
public GMarkerCross(PointLatLng p)
: base(p)
{
#if !PocketPC
Pen = new Pen(Brushes.Red, 1);
#else
Pen = new Pen(Color.Red, 1);
#endif
IsHitTestVisible = false;
}
示例4: GMarkerGoogle
public GMarkerGoogle(PointLatLng p, GMarkerGoogleType type)
: base(p)
{
this.Type = type;
if(type != GMarkerGoogleType.none)
{
LoadBitmap();
}
}
示例5: GMarkerGoogle
public GMarkerGoogle(PointLatLng p, GMarkerGoogleType type, bool showShadow = true)
: base(p)
{
this.Type = type;
this.ShowShadow = showShadow;
if(type != GMarkerGoogleType.none)
{
LoadBitmap();
}
}
示例6: GMapMarkerTransparentGoogleGreen
public GMapMarkerTransparentGoogleGreen(PointLatLng p)
: base(p)
{
System.Reflection.Assembly ass = System.Reflection.Assembly.GetExecutingAssembly();
String resShadow = "GMap.NET.WindowsMobile.Resources.shadow50.png";
String resMarker = "GMap.NET.WindowsMobile.Resources.bigMarkerGreen.png";
IGMapTransparentBitmap shadow = GMapMarkerTransparent.LoadTransparentBitmap(ass.GetManifestResourceStream(resShadow));
IGMapTransparentBitmap marker = GMapMarkerTransparent.LoadTransparentBitmap(ass.GetManifestResourceStream(resMarker));
bitmaps = new IGMapTransparentBitmap[] { shadow, marker };
Size = new System.Drawing.Size(marker.Width, marker.Height);
Offset = new System.Drawing.Point(-10, -34);
}
示例7: GetDirections
public DirectionsStatusCode GetDirections(out GDirections direction, PointLatLng start, IEnumerable<PointLatLng> wayPoints, bool avoidHighways, bool avoidTolls, bool walkingMode, bool sensor, bool metric)
{
return GetDirectionsUrl(MakeDirectionsUrl(start, wayPoints, LanguageStr, avoidHighways, avoidTolls, walkingMode, sensor, metric), out direction);
}
示例8: GMapMarkerCondominioLarge
public GMapMarkerCondominioLarge(PointLatLng p) : base(p)
{
Size = new System.Drawing.Size(global::Gipasoft.Stabili.UI.GeoLocation.Properties.Resources.stabile_large.Width, global::Gipasoft.Stabili.UI.GeoLocation.Properties.Resources.stabile_large.Height);
Offset = new System.Drawing.Point(-10, -34);
}
示例9: FromLatLngToLocal
/// <summary>
/// return local coordinates from lat/lng
/// </summary>
/// <param name="latlng"></param>
/// <returns></returns>
public GPoint FromLatLngToLocal(PointLatLng latlng)
{
GPoint pLocal = Provider.Projection.FromLatLngToPixel(latlng, Zoom);
pLocal.Offset(renderOffset);
pLocal.OffsetNegative(compensationOffset);
return pLocal;
}
示例10: MakeRoutingUrl
string MakeRoutingUrl(PointLatLng start, PointLatLng end, string travelType, string language, string units)
{
// http://developers.cloudmade.com/projects/routing-http-api/examples/
// http://routes.cloudmade.com/YOUR-API-KEY-GOES-HERE/api/0.3/start_point,[[transit_point1,...,transit_pointN]],end_point/route_type[/route_type_modifier].output_format[?lang=(en|de)][&units=(km|miles)]
return string.Format(CultureInfo.InvariantCulture, UrlFormat, Key, Version, start.Lat, start.Lng, end.Lat, end.Lng, travelType, language, units);
}
示例11: GetPlacemarks
public GeoCoderStatusCode GetPlacemarks(PointLatLng location, out List<Placemark> placemarkList)
{
return GetPlacemarkFromReverseGeocoderUrl(MakeReverseGeocoderUrl(location, LanguageStr), out placemarkList);
}
示例12: MakeReverseGeocoderUrl
string MakeReverseGeocoderUrl(PointLatLng pt, string language)
{
return string.Format(CultureInfo.InvariantCulture, ReverseGeocoderUrlFormat, ServerAPIs, pt.Lat, pt.Lng, language);
}
示例13: MakeDirectionsUrl
// The Coogle Directions API: http://tinyurl.com/6vv4cac
string MakeDirectionsUrl(PointLatLng start, PointLatLng end, string language, bool avoidHighways, bool avoidTolls, bool walkingMode, bool sensor, bool metric)
{
string av = (avoidHighways ? "&avoid=highways" : string.Empty) + (avoidTolls ? "&avoid=tolls" : string.Empty); // 6
string mt = "&units=" + (metric ? "metric" : "imperial"); // 7
string wk = "&mode=" + (walkingMode ? "walking" : "driving"); // 8
return string.Format(CultureInfo.InvariantCulture, DirectionUrlFormatPoint, start.Lat, start.Lng, end.Lat, end.Lng, sensor.ToString().ToLower(), language, av, mt, wk, ServerAPIs);
}
示例14: GetRoute
public MapRoute GetRoute(PointLatLng start, PointLatLng end, bool avoidHighways, bool walkingMode, int Zoom)
{
string tooltip;
int numLevels;
int zoomFactor;
MapRoute ret = null;
List<PointLatLng> points = GetRoutePoints(MakeRouteUrl(start, end, LanguageStr, avoidHighways, walkingMode), Zoom, out tooltip, out numLevels, out zoomFactor);
if (points != null)
{
ret = new MapRoute(points, tooltip);
}
return ret;
}
示例15: GMapMarker
public GMapMarker(PointLatLng pos)
{
this.Position = pos;
}