Open ali-0x11 opened 1 year ago
Unfortunately, this is not really possible at the moment. You could directly inject terminal escape codes into the title string, like this:
#!/usr/bin/env python3
from simple_term_menu import TerminalMenu
def main():
terminal_menu = TerminalMenu(["Apple", "Banana", "Peach"], title="\33[32mFruits\33[m")
terminal_menu.show()
print(f"Your choice: {terminal_menu.chosen_menu_entry}")
if __name__ == "__main__":
main()
But this breaks the title line length calculation routine and leads to a broken menu display on repaint. This is related to issue #14 and hopefully can be fixed soon.
How I can add colors to the title ?