コード例 #1
0
ファイル: MenuContext.cs プロジェクト: bushuosx/ConsoleMenu
        /// <summary>
        /// 菜单上下文。父菜单active时生成,用于绘制参考
        /// </summary>
        /// <param name="menuStyle"></param>
        public MenuContext(MenuDrawingStyle drawingStyle, MenuItemKeyStyle keyStyle, ConsoleColor disabledItemForegroundColor = System.ConsoleColor.DarkGray)
        {
            DrawingStyle = drawingStyle;
            KeyStyle     = keyStyle;
            DisabledItemForegroundColor = disabledItemForegroundColor;

            CursorStatus = new CursorStatus();
            ConsoleColor = new SafeConsoleColor();
        }
コード例 #2
0
ファイル: MenuStyle.cs プロジェクト: bushuosx/ConsoleMenu
 /// <summary>
 /// 菜单绘制样式
 /// </summary>
 /// <param name="drawingStyle">绘制方式</param>
 /// <param name="titleStyle">标题风格</param>
 public MenuStyle(MenuDrawingStyle drawingStyle, MenuItemTitleStyle titleStyle)
 {
     DrawingStyle = drawingStyle;
     TitleStyle   = titleStyle;
 }