示例#1
0
        static void Main(string[] args)
        {
            Console.Title          = "Simple Curses Example";
            Console.CursorVisible  = false;
            Console.OutputEncoding = System.Text.Encoding.UTF8;

            var virtualConsole = VirtualConsole.Create();

            currentController = new HomeController();

            while (!virtualConsole.Ended)
            {
                virtualConsole.Update(currentController.CurrentView().GetRenderable());

                if (Console.KeyAvailable)
                {
                    currentController.CurrentView().HandleKeyPress(Console.ReadKey(true));
                }

                Thread.Sleep(1);
            }

            Console.ReadKey();
        }