当前位置: 首页>>代码示例>>C#>>正文


C# Point.Minus方法代码示例

本文整理汇总了C#中Point.Minus方法的典型用法代码示例。如果您正苦于以下问题:C# Point.Minus方法的具体用法?C# Point.Minus怎么用?C# Point.Minus使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Point的用法示例。


在下文中一共展示了Point.Minus方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: MoveToCore

 public override void MoveToCore(Point newPosition)
 {
     Offset = newPosition.Minus(Origin);
     base.MoveToCore(newPosition);
 }
开发者ID:ondrej11,项目名称:o106,代码行数:5,代码来源:AreaMeasurement.cs

示例2: MouseMove

 internal void MouseMove(Point point)
 {
     if (state == CanvasState.Dragging)
     {
         Point d = point.Minus(draggingOrigin);
         Point p1 = allViews[dragged];
         Point p2 = p1.Offseted(d);
         Size sz = dragged.Assemble().Size;
         Rectangle inva = Rectangle.Union(new Rectangle(p1, sz), new Rectangle(p2, sz));
         inva.Inflate(5, 5);
         draggedModel.Location = p2;
         draggingOrigin = point;
         DropRegion active;
         if (FindActiveDropRegion(ViewBounds(dragged), out active))
         {
             Rectangle topLevelDest = ViewBounds(active.Destination.AbsoluteAncestor());
             inva = Rectangle.Union(inva, topLevelDest);
         }
         Update(inva);
     }
     if (state == CanvasState.Ready)
     {
         /*
         IBlockView hit = HitTest(point);
         if (hit != null)
             canvasView.status = hit.ToString();
         else
             canvasView.status = "<None>";
          //*/
     }
 }
开发者ID:andyhebear,项目名称:kitsune,代码行数:31,代码来源:BlockController.cs

示例3: MoveToCore

 public override void MoveToCore(Point newPosition)
 {
     Point newOffset = newPosition.Minus(Point(0));
     newOffset = newOffset.TrimToMaxLength(ToLogical(100));
     Offset = newOffset;
     base.MoveToCore(newPosition);
 }
开发者ID:ondrej11,项目名称:o106,代码行数:7,代码来源:PointLabel.cs

示例4: MoveToCore

 public override void MoveToCore(Point newPosition)
 {
     Point newOffset = newPosition.Minus(Point(0));
     Offset = newOffset;
     base.MoveToCore(newPosition);
 }
开发者ID:ondrej11,项目名称:o106,代码行数:6,代码来源:AngleMeasurement.cs

示例5: CartesianToPolar

 public static void CartesianToPolar(Point point, Point center, out double radius, out double phi)
 {
     var p = point.Minus(center);
     radius = Math.Sqrt((p.X * p.X) + (p.Y * p.Y));
     phi = Math.Atan2(p.Y, p.X);
 }
开发者ID:georgeslegros,项目名称:geometry,代码行数:6,代码来源:Geometry.cs


注:本文中的Point.Minus方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。