Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on May 9, 2024. It is now read-only.

dotmenu/dotmenu

Repository files navigation

License: MIT GitHub Actions Workflow Status

About Dotmenu

A straightforward console menu library designed to streamline user interactions in console applications. Works on every terminal that supports ANSI escape codes.

Installation

Dotmenu can be added to your project with:

dotnet add package Dotmenu

Usage

Creating a menu is similar to creating a host for modern .NET applications:

Menu.CreateDefaultBuilder()
    .SetTitle("Sample")
    .SetPrefix("")
    .SetSelector(">")
    .AddOption<PlayOption>()
    .AddOption<CreditsOption>()
    .AddOption(text: "Exit", static () => Environment.Exit(0))
    .Build()
    .Run();

Builders

Currently, there are a few builders available to help you create menus:

  • Menu.CreateDefaultBuilder()
  • Menu.CreateCenteredBuilder()

Menu Samples

Hangman Hangman Screenshot

Special thanks

Special thanks to tacosontitan for adding unit tests, making hangman sample and making new API Surface. And thanks to samwise for fixing bugs.

Documentation

For more documentation on how to create and configure menus please read the wiki at dotmenu.natesworks.com

About

A straightforward console menu library designed to streamline user interactions in console applications.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Contributors

Languages