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


C# DocumentWorkspace类代码示例

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


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

示例1: FreeformShapeTool

 public FreeformShapeTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            PdnResources.GetImageResource("Icons.FreeformShapeToolIcon.png"),
            PdnResources.GetString("FreeformShapeTool.Name"),
            PdnResources.GetString("FreeformShapeTool.HelpText"))
 {
 }
开发者ID:herbqiao,项目名称:paint.net,代码行数:7,代码来源:FreeformShapeTool.cs

示例2: EllipseTool

 public EllipseTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.EllipseToolIcon.png"),
            PdnResources.GetString("EllipseTool.Name"),
            PdnResources.GetString("EllipseTool.HelpText"))
 {
 }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:7,代码来源:EllipseTool.cs

示例3: RoundedRectangleTool

 public RoundedRectangleTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.RoundedRectangleToolIcon.png"),
            PdnResources.GetString("RoundedRectangleTool.Name"),
            PdnResources.GetString("RoundedRectangleTool.HelpText"))
 {
 }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:7,代码来源:RoundedRectangleTool.cs

示例4: PerformAction

        public override HistoryMemento PerformAction(DocumentWorkspace documentWorkspace)
        {
            DateTime lastUpdate = DateTime.Now;

            documentWorkspace.History.BeginStepGroup();

            using (new WaitCursorChanger(documentWorkspace))
            {
                documentWorkspace.SuspendToolCursorChanges();

                while (documentWorkspace.History.RedoStack.Count > 0)
                {
                    documentWorkspace.History.StepForward();

                    if ((DateTime.Now - lastUpdate).TotalMilliseconds >= 500)
                    {
                        documentWorkspace.History.EndStepGroup();
                        documentWorkspace.Update();
                        lastUpdate = DateTime.Now;
                        documentWorkspace.History.BeginStepGroup();
                    }
                }

                documentWorkspace.ResumeToolCursorChanges();
            }

            documentWorkspace.History.EndStepGroup();

            Utility.GCFullCollect();
            documentWorkspace.Document.Invalidate();
            documentWorkspace.Update();

            return null;
        }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:34,代码来源:HistoryFastForwardAction.cs

示例5: EllipseSelectTool

 public EllipseSelectTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.EllipseSelectToolIcon.png"),
            PdnResources.GetString("EllipseSelectTool.Name"),
            PdnResources.GetString("EllipseSelectTool.HelpText"),
            's',
            ToolBarConfigItems.None)
 {
 }
开发者ID:nkaligin,项目名称:paint-mono,代码行数:9,代码来源:EllipseSelectTool.cs

示例6: LassoSelectTool

 public LassoSelectTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            PdnResources.GetImageResource("Icons.LassoSelectToolIcon.png"),
            PdnResources.GetString("LassoSelectTool.Name"),
            PdnResources.GetString("LassoSelectTool.HelpText"),
            's',
            ToolBarConfigItems.None)
 {
 }
开发者ID:herbqiao,项目名称:paint.net,代码行数:9,代码来源:LassoSelectTool.cs

示例7: CloneStampTool

 public CloneStampTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.CloneStampToolIcon.png"),
            PdnResources.GetString("CloneStampTool.Name"),
            PdnResources.GetString("CloneStampTool.HelpText"),
            'l',
            false,
            ToolBarConfigItems.Pen | ToolBarConfigItems.Antialiasing)
 {
 }
开发者ID:nkaligin,项目名称:paint-mono,代码行数:10,代码来源:CloneStampTool.cs

示例8: RecolorTool

 public RecolorTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.RecoloringToolIcon.png"),
            PdnResources.GetString("RecolorTool.Name"), 
            PdnResources.GetString("RecolorTool.HelpText"),
            'r',
            false,
            ToolBarConfigItems.Pen | ToolBarConfigItems.Antialiasing | ToolBarConfigItems.Tolerance)
 {
 }
开发者ID:nkaligin,项目名称:paint-mono,代码行数:10,代码来源:RecoloringTool.cs

示例9: GradientTool

 public GradientTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            StaticImage,
            StaticName,
            PdnResources.GetString("GradientTool.HelpText"),
            'g',
            false,
            ToolBarConfigItems.Gradient | ToolBarConfigItems.AlphaBlending)
 {
 }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:10,代码来源:GradientTool.cs

示例10: EraserTool

 public EraserTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.EraserToolIcon.png"),
            PdnResources.GetString("EraserTool.Name"),
            PdnResources.GetString("EraserTool.HelpText"), //"Click and drag to erase a portion of the image",
            'e',
            false,
            ToolBarConfigItems.Pen | ToolBarConfigItems.Antialiasing)
 {
 }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:10,代码来源:EraserTool.cs

示例11: PaintBucketTool

 public PaintBucketTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.PaintBucketIcon.png"),
            PdnResources.GetString("PaintBucketTool.Name"),
            PdnResources.GetString("PaintBucketTool.HelpText"),
            'f',
            false,
            ToolBarConfigItems.Brush | ToolBarConfigItems.Antialiasing | ToolBarConfigItems.AlphaBlending)
 {
 }
开发者ID:nkaligin,项目名称:paint-mono,代码行数:10,代码来源:PaintBucketTool.cs

示例12: LineTool

 public LineTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.LineToolIcon.png"),
            PdnResources.GetString("LineTool.Name"),
            PdnResources.GetString("LineTool.HelpText"),
            ToolBarConfigItems.None, 
            ToolBarConfigItems.ShapeType)
 {
     this.ForceShapeDrawType = true;
     this.ForcedShapeDrawType = ShapeDrawType.Outline;
 }
开发者ID:nkaligin,项目名称:paint-mono,代码行数:11,代码来源:LineTool.cs

示例13: MoveSelectionTool

 public MoveSelectionTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.MoveSelectionToolIcon.png"),
            MoveSelectionTool.StaticName,
            PdnResources.GetString("MoveSelectionTool.HelpText"), // "Click and drag to move a selected region",
            'm',
            false,
            ToolBarConfigItems.None)
 {
     this.context = new Context();
 }
开发者ID:nkaligin,项目名称:paint-mono,代码行数:11,代码来源:MoveSelectionTool.cs

示例14: ZoomTool

 public ZoomTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.ZoomToolIcon.png"),
            PdnResources.GetString("ZoomTool.Name"),
            PdnResources.GetString("ZoomTool.HelpText"),
            'z',
            false,
            ToolBarConfigItems.None)
 {
     this.mouseDown = MouseButtons.None;
 }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:11,代码来源:ZoomTool.cs

示例15: MagicWandTool

 public MagicWandTool(DocumentWorkspace documentWorkspace)
     : base(documentWorkspace,
            ImageResource.Get("Icons.MagicWandToolIcon.png"),
            PdnResources.GetString("MagicWandTool.Name"),
            PdnResources.GetString("MagicWandTool.HelpText"), 
            's',
            false,
            ToolBarConfigItems.None)
 {
     LimitToSelection = false;
 }
开发者ID:leejungho2,项目名称:xynotecgui,代码行数:11,代码来源:MagicWandTool.cs


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