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


C# Host.Rectangle类代码示例

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


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

示例1: GetBufferContents

 public override BufferCell[,] GetBufferContents(Rectangle r)
 {
     if (this.externalRawUI == null)
     {
         this.ThrowNotInteractive();
     }
     return this.externalRawUI.GetBufferContents(r);
 }
开发者ID:nickchal,项目名称:pash,代码行数:8,代码来源:InternalHostRawUserInterface.cs

示例2: PushHostUI

        public static void PushHostUI( this PSHostRawUserInterface host )
        {
            var buffer = new Rectangle( 0, 0, host.BufferSize.Width, host.BufferSize.Height );
            HostBufferImage = new HostBuffer
            {
                BufferSize = host.BufferSize,
                Buffer = host.GetBufferContents( buffer ),

                CursorSize = host.CursorSize,
                CursorPosition = host.CursorPosition,

                Background = host.BackgroundColor,
                Foreground = host.ForegroundColor,

                WindowPosition = host.WindowPosition,
                WindowSize = host.WindowSize,
                WindowTitle = host.WindowTitle
            };
        }
开发者ID:rbobot,项目名称:Fqopy,代码行数:19,代码来源:PSCmdletExtender.cs

示例3: ScrollBufferContents

 public override void ScrollBufferContents(Rectangle source, Coordinates destination, Rectangle clip,
                                           BufferCell fill)
 {
     throw new NotImplementedException();
 }
开发者ID:scjunkie,项目名称:Console,代码行数:5,代码来源:ScriptingHostRawUserInterface.cs

示例4: SetBufferContents

		public override void SetBufferContents(Rectangle rectangle, BufferCell fill)
		{
			this.OnMessageCreated(new MessageCreatedEventArgs(new ClearBufferMessage(), false));
		}
开发者ID:nickchal,项目名称:pash,代码行数:4,代码来源:PowwaHostRawUserInterface.cs

示例5: GetBufferContents

		public override BufferCell[,] GetBufferContents(Rectangle rectangle)
		{
			throw new NotSupportedException(Resources.PSHostRawUserInterfaceGetBufferContentsNotSupported);
		}
开发者ID:nickchal,项目名称:pash,代码行数:4,代码来源:PowwaHostRawUserInterface.cs

示例6: SetBufferContents

        public override void SetBufferContents(Rectangle rectangle, BufferCell fill)
        {
            _control.CompleteBackgroundWorkItems();
            if (rectangle.Left == -1 && rectangle.Right == -1)
            {
                _control.ClearScreen();
            }
            else

                // TODO: REIMPLEMENT PSHostRawUserInterface.SetBufferContents(Rectangle rectangle, BufferCell fill)
                throw new NotImplementedException("The SetBufferContents method is not (yet) implemented!");
            //if (_control.Dispatcher.CheckAccess())
            // {
            //     _control.SetBufferContents(rectangle, fill);
            // }
            // else
            // {
            //    _control.Dispatcher.BeginInvoke(DispatcherPriority.Normal, (Action)delegate
            //     {
            //         _control.SetBufferContents(rectangle, fill);
            //     });
            // }
        }
开发者ID:Jaykul,项目名称:PoshConsole,代码行数:23,代码来源:HostRawUI.cs

示例7: GetBufferContents

 public override BufferCell[,] GetBufferContents(Rectangle rectangle)
 {
     // TODO: REIMPLEMENT PSHostRawUserInterface.GetBufferContents(Rectangle rectangle)
     // throw new NotImplementedException("The GetBufferContents method is not (yet) implemented!");
     _control.CompleteBackgroundWorkItems();
     if (_control.Dispatcher.CheckAccess())
     {
         return _control.GetBufferContents(rectangle);
     }
     return (BufferCell[,])_control.Dispatcher.Invoke(DispatcherPriority.Normal, (Func<BufferCell[,]>)(() => _control.GetBufferContents(rectangle)));
 }
开发者ID:Jaykul,项目名称:PoshConsole,代码行数:11,代码来源:HostRawUI.cs

示例8: ScrollBufferContents

 /// <summary>
 /// Scrolls the contents of the console buffer.
 /// </summary>
 /// <param name="source">The source rectangle to scroll.</param>
 /// <param name="destination">The destination coordinates by which to scroll.</param>
 /// <param name="clip">The rectangle inside which the scrolling will be clipped.</param>
 /// <param name="fill">The cell with which the buffer will be filled.</param>
 public override void ScrollBufferContents(
     Rectangle source, 
     Coordinates destination, 
     Rectangle clip, 
     BufferCell fill)
 {
     Logger.Write(
         LogLevel.Warning,
         "PSHostRawUserInterface.ScrollBufferContents was called");
 }
开发者ID:sunnyc7,项目名称:PowerShellEditorServices,代码行数:17,代码来源:SessionPSHostRawUserInterface.cs

示例9: ScrollBufferContents

 public abstract void ScrollBufferContents(Rectangle source, Coordinates destination, Rectangle clip, BufferCell fill);
开发者ID:mauve,项目名称:Pash,代码行数:1,代码来源:PSHostRawUserInterface.cs

示例10: GetBufferContents

 public abstract BufferCell[,] GetBufferContents(Rectangle rectangle);
开发者ID:mauve,项目名称:Pash,代码行数:1,代码来源:PSHostRawUserInterface.cs

示例11: GetBufferContents

 /// <summary>
 /// Get buffer contents.
 /// </summary>
 public override BufferCell[,] GetBufferContents(Rectangle rectangle)
 {
     // This method had an implementation earlier. However, owing
     // to a potential security risk of a malicious server scrapping
     // the screen contents of a client, this is now removed
     throw RemoteHostExceptions.NewNotImplementedException(RemoteHostMethodId.GetBufferContents);
 }
开发者ID:40a,项目名称:PowerShell,代码行数:10,代码来源:ServerRemoteHostRawUserInterface.cs

示例12: SetBufferContents

 /// <summary>
 /// Set buffer contents.
 /// </summary>
 public override void SetBufferContents(Rectangle rectangle, BufferCell fill)
 {
     _serverMethodExecutor.ExecuteVoidMethod(RemoteHostMethodId.SetBufferContents1, new object[] { rectangle, fill });
 }
开发者ID:40a,项目名称:PowerShell,代码行数:7,代码来源:ServerRemoteHostRawUserInterface.cs

示例13: ScrollBufferContents

 /// <summary>
 /// Scroll buffer contents.
 /// </summary>
 public override void ScrollBufferContents(Rectangle source, Coordinates destination, Rectangle clip, BufferCell fill)
 {
     _serverMethodExecutor.ExecuteVoidMethod(RemoteHostMethodId.ScrollBufferContents, new object[] { source, destination, clip, fill });
 }
开发者ID:40a,项目名称:PowerShell,代码行数:7,代码来源:ServerRemoteHostRawUserInterface.cs

示例14: SetBufferContents

 public override void SetBufferContents(Rectangle rectangle, BufferCell fill)
 {
 }
开发者ID:x-cubed,项目名称:Second-Law,代码行数:3,代码来源:HostUI.cs

示例15: ScrollBufferContents

 public override void ScrollBufferContents(Rectangle source, Coordinates destination, Rectangle clip, BufferCell fill)
 {
 }
开发者ID:x-cubed,项目名称:Second-Law,代码行数:3,代码来源:HostUI.cs


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