• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Media.GeneralTransform类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中System.Windows.Media.GeneralTransform的典型用法代码示例。如果您正苦于以下问题:C# GeneralTransform类的具体用法?C# GeneralTransform怎么用?C# GeneralTransform使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



GeneralTransform类属于System.Windows.Media命名空间,在下文中一共展示了GeneralTransform类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     var transformGroup = new GeneralTransformGroup();
     transformGroup.Children.Add(base.GetDesiredTransform(transform));
     transformGroup.Children.Add(new TranslateTransform(_currentPoint.X - _startPoint.X, _currentPoint.Y - _startPoint.Y));
     return transformGroup;
 }
开发者ID:markrendle,项目名称:WpfPrimitives,代码行数:7,代码来源:DragAdorner.cs


示例2: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup result = new GeneralTransformGroup();
     result.Children.Add(base.GetDesiredTransform(transform));
     result.Children.Add(new TranslateTransform(this.left, this.top));
     return result;
 }
开发者ID:Orange637,项目名称:WpfStudy,代码行数:7,代码来源:DraggedAdorner.cs


示例3: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup result = new GeneralTransformGroup();
     result.Children.Add(base.GetDesiredTransform(transform));
     result.Children.Add(new TranslateTransform(_leftOffset, _topOffset));
     return result;
 }
开发者ID:allanckw,项目名称:GEMS-Client,代码行数:7,代码来源:DragAdorner.cs


示例4: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup newTransform = new GeneralTransformGroup();
     newTransform.Children.Add(base.GetDesiredTransform(transform));
     newTransform.Children.Add(new TranslateTransform(this._adornerOffset.X, this._adornerOffset.Y));
     return newTransform;
 }
开发者ID:BoonieBear,项目名称:TinyMetro,代码行数:7,代码来源:DefaultAdorner.cs


示例5: GetDesiredTransform

        /// <summary>
        /// Forwarded to the annotation component to get desired transform relative to the annotated element
        /// </summary>
        /// <param name="transform">Transform to adorned element</param>
        /// <returns>Transform to annotation component </returns>
        public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
        {           
            //if the component is not visual we do not need this
            if (!(_annotationComponent is UIElement))
                return null;

            // Give the superclass a chance to modify the transform
            transform = base.GetDesiredTransform(transform);

            GeneralTransform compTransform = _annotationComponent.GetDesiredTransform(transform);
 
            //ToDo. if the annotated element is null this component must be unloaded.
            //Temporary return null until the PageViewer Load/Unload bug is fixed
            //Convert it to an exception after that.
            if (_annotationComponent.AnnotatedElement == null)
                return null;

            if (compTransform == null)
            {
                // We need to store the element we are registering on.  It may not
                // be available from the annotation component later.
                _annotatedElement = _annotationComponent.AnnotatedElement;

                // Wait for valid text view
                _annotatedElement.LayoutUpdated += OnLayoutUpdated;
                return transform;
            }

            return compTransform;
        }
开发者ID:JianwenSun,项目名称:cc,代码行数:35,代码来源:AnnotationAdorner.cs


示例6: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     var group = new TransformGroup();
     group.Children.Add((Transform)transform);
     group.Children.Add(_tTranslate = new TranslateTransform(HorizontalOffset, VerticalOffset));
     return group;
 }
开发者ID:ivanglushchenko,项目名称:BetterWpfControls,代码行数:7,代码来源:ContentAdorner.cs


示例7: GetBounds

        private Rect GetBounds(StylusPoint stylusPoint, 
            Point position,
            IInputElement relativeTo, 
            GeneralTransform elementToRoot,
            GeneralTransform rootToElement)
        {
            // Get width and heith in pixel value 
            double width = GetStylusPointWidthOrHeight(stylusPoint, /*isWidth*/ true);
            double height = GetStylusPointWidthOrHeight(stylusPoint, /*isWidth*/ false); 
 
            // Get the position with respect to root
            Point rootPoint; 
            if (elementToRoot == null ||
                !elementToRoot.TryTransform(position, out rootPoint))
            {
                rootPoint = position; 
            }
 
            // Create a Rect with respect to root and transform it to element coordinate space 
            Rect rectBounds = new Rect(rootPoint.X - width * 0.5, rootPoint.Y - height * 0.5, width, height);
            if (rootToElement != null) 
            {
                rectBounds = rootToElement.TransformBounds(rectBounds);
            }
            return rectBounds; 
        }
开发者ID:sjyanxin,项目名称:WPFSource,代码行数:26,代码来源:StylusTouchDevice.cs


示例8: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup result = new GeneralTransformGroup();
     result.Children.Add(base.GetDesiredTransform(transform));
     result.Children.Add(new TranslateTransform(position.X, position.Y));
     return result;
 }
开发者ID:YoshihiroIto,项目名称:TreeViewEx,代码行数:7,代码来源:DragAdorner.cs


示例9: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup result = new GeneralTransformGroup();
     result.Children.Add (transform);
     result.Children.Add (new TranslateTransform (this.offset.X, this.offset.Y));
     return result;
 }
开发者ID:RevolutionSmythe,项目名称:xwt,代码行数:7,代码来源:ImageAdorner.cs


示例10: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup group = new GeneralTransformGroup();
     group.Children.Add(base.GetDesiredTransform(transform));
     group.Children.Add(translate);
     return group;
 }
开发者ID:kinectitude,项目名称:kinectitude,代码行数:7,代码来源:DragAdorner.cs


示例11: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     var result = new GeneralTransformGroup();
     result.Children.Add(base.GetDesiredTransform(transform));
     result.Children.Add(new TranslateTransform(_offsetLeft, _offsetTop));
     return result;
 }
开发者ID:borndead,项目名称:PoESkillTree,代码行数:7,代码来源:DragAdorner.cs


示例12: SinglePageInfo

 public SinglePageInfo(double topOffsetInPresenter, double bottomPositionInView, bool intersectsHorizontally, bool intersectsVertically, RadFixedPage page, Rect positionInView, GeneralTransform transformations)
     : base(page, positionInView, transformations)
 {
     this.topOffsetInPresenter = topOffsetInPresenter;
     this.bottomPositionInView = bottomPositionInView;
     this.intersectsWithViewportVertically = intersectsVertically;
     this.intersectsWithViewportHorizontally = intersectsHorizontally;
 }
开发者ID:Motaz-Al-Zoubi,项目名称:xaml-sdk,代码行数:8,代码来源:SinglePageInfo.cs


示例13: GetDesiredTransform

    public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
    {
      var result = new GeneralTransformGroup();
      result.Children.Add(base.GetDesiredTransform(transform));
      result.Children.Add(new TranslateTransform(this.MousePosition.X - 4, this.MousePosition.Y - 4));

      return result;
    }
开发者ID:DeadlyEmbrace,项目名称:gong-wpf-dragdrop,代码行数:8,代码来源:DragAdorner.cs


示例14: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     GeneralTransformGroup result = new GeneralTransformGroup();
     result.Children.Add(base.GetDesiredTransform(transform));
     result.Children.Add(new TranslateTransform(
         position.X - treeViewEx.ScrollViewer.ContentHorizontalOffset, position.Y - treeViewEx.ScrollViewer.ContentVerticalOffset));
     return result;
 }
开发者ID:YoshihiroIto,项目名称:TreeViewEx,代码行数:8,代码来源:BorderSelectionAdorner.cs


示例15: FixedSOMImage

        //-------------------------------------------------------------------- 
        //
        // Constructors
        //
        //--------------------------------------------------------------------- 

        #region Constructors 
        private FixedSOMImage(Rect imageRect, GeneralTransform trans, Uri sourceUri, FixedNode node, DependencyObject o) : base(node, trans) 
        {
            _boundingRect = trans.TransformBounds(imageRect); 
            _source = sourceUri;
            _startIndex = 0;
            _endIndex = 1;
            _name = AutomationProperties.GetName(o); 
            _helpText = AutomationProperties.GetHelpText(o);
        } 
开发者ID:sjyanxin,项目名称:WPFSource,代码行数:16,代码来源:FixedSOMImage.cs


示例16: GetDesiredTransform

 /// <summary>
 ///     Override.
 /// </summary>
 /// <param name="transform"></param>
 /// <returns></returns>
 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     var result = new GeneralTransformGroup();
     // ReSharper disable AssignNullToNotNullAttribute
     result.Children.Add(base.GetDesiredTransform(transform));
     // ReSharper restore AssignNullToNotNullAttribute
     result.Children.Add(new TranslateTransform(offsetLeft, offsetTop));
     return result;
 }
开发者ID:Robin--,项目名称:Warewolf,代码行数:14,代码来源:SingleChildAdornerBase.cs


示例17: GetDesiredTransform

        public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
        {
            GeneralTransformGroup result = new GeneralTransformGroup();
            result.Children.Add(new TranslateTransform(Left, Top));
            if (Left > 0) this.Visibility = Visibility.Visible;
            result.Children.Add(base.GetDesiredTransform(transform));

            return result;
        }
开发者ID:tablesmit,项目名称:FabTab,代码行数:9,代码来源:DropPreviewAdorner.cs


示例18: GetDesiredTransform

    public override GeneralTransform GetDesiredTransform( GeneralTransform transform )
    {
      Size gridRenderSize = this.AdornedElement.RenderSize;
      Size contentDesiredSize = m_content.DesiredSize;

      GeneralTransformGroup result = new GeneralTransformGroup();
      result.Children.Add( base.GetDesiredTransform( transform ) );
      result.Children.Add( new TranslateTransform( gridRenderSize.Width - contentDesiredSize.Width - 9, 4 ) );
      return result;
    }
开发者ID:wangws556,项目名称:duoduo-chat,代码行数:10,代码来源:WatermarkAdorner.cs


示例19: GetDesiredTransform

 public override GeneralTransform GetDesiredTransform(GeneralTransform transform)
 {
     return (GeneralTransform) new GeneralTransformGroup()
       {
     Children = {
       transform,
       (GeneralTransform) new TranslateTransform(30.0, this.position.Y)
     }
       };
 }
开发者ID:unbearab1e,项目名称:FlattyTweet,代码行数:10,代码来源:AdornerDragDrop.cs


示例20: GetDesiredTransform

        public override GeneralTransform GetDesiredTransform(GeneralTransform transform) {
            var result = new GeneralTransformGroup();
            var desired = base.GetDesiredTransform(transform);
            if (desired != null) {
                result.Children.Add(desired);
            }

            result.Children.Add(new TranslateTransform(_offsetLeft, _offsetTop));
            return result;
        }
开发者ID:gro-ove,项目名称:actools,代码行数:10,代码来源:DragAdorner.cs



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Media.GeneralTransformGroup类代码示例发布时间:2022-05-26
下一篇:
C# Media.FormattedText类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap