xref: /freebsd/contrib/bsddialog/README.md (revision d4eeb02986980bf33dd56c41ceb9fc5f180c0d47)
1# BSDDialog 0.2
2
3
4This project provides **bsddialog** and **libbsddialog**, an utility and a
5library to build scripts and tools with TUI dialogs and widgets.
6
7
8## Intro
9
10Briefly:
11<https://www.freebsd.org/status/report-2021-04-2021-06/#_bsddialog_tui_widgets>
12
13Utility:
14<https://alfonsosiciliano.gitlab.io/posts/2021-12-07-bsddialog.html>
15
16Library:
17<https://alfonsosiciliano.gitlab.io/posts/2022-01-16-libbsddialog.html>
18
19Screenshots:
20<https://www.flickr.com/photos/alfonsosiciliano/albums/72157720215006074>
21
22
23## Getting Started
24
25FreeBSD:
26
27```
28% git clone https://gitlab.com/alfix/bsddialog.git
29% cd bsddialog
30% make
31% ./bsddialog --msgbox "Hello World!" 8 20
32```
33
34Output:
35
36![screenshot](screenshot.png)
37
38
39## Utility
40
41**Dialogs:**
42
43--checklist, --datebox, --form, --gauge, --inputbox, --menu, --mixedform,
44--mixedgauge, --msgbox, --passwordbox, --passwordform, --pause, --radiolist,
45--rangebox, --textbox, --timebox, --treeview, --yesno.
46
47**Manual**
48
49 - [bsddialog(1)](https://alfonsosiciliano.gitlab.io/posts/2022-01-26-manual-bsddialog.html)
50
51
52**Examples**:
53
54```
55% ./bsddialog --backtitle "TITLE" --title msgbox --msgbox "Hello World!" 5 30
56% ./bsddialog --theme blackwhite --title msgbox --msgbox "Hello World!" 5 30
57% ./bsddialog --begin-y 2 --default-no --title yesno --yesno "Hello World!" 5 30
58% ./bsddialog --ascii-lines --pause "Hello World!" 8 50 10
59% ./bsddialog --checklist "Space to select" 0 0 0 Name1 Desc1 off Name2 Desc2 on
60% ./bsddialog --title yesno --hline "bsddialog" --yesno "Hello World!" 5 25
61% ./bsddialog --extra-button --help-button --yesno "Hello World!" 0 0
62```
63
64and [Examples](https://gitlab.com/alfix/bsddialog/-/tree/main/examples_utility)
65in the _Public Domain_ to build new projects:
66```
67% sh ./examples_utility/checklist.sh
68% sh ./examples_utility/form.sh
69% sh ./examples_utility/gauge.sh
70% sh ./examples_utility/infobox.sh
71% sh ./examples_utility/inputbox.sh
72% sh ./examples_utility/menu.sh
73% sh ./examples_utility/mixedform.sh
74% sh ./examples_utility/mixedgauge.sh
75% sh ./examples_utility/msgbox.sh
76% sh ./examples_utility/passwordbox.sh
77% sh ./examples_utility/passwordform.sh
78% sh ./examples_utility/pause.sh
79% sh ./examples_utility/radiolist.sh
80% sh ./examples_utility/timebox.sh
81% sh ./examples_utility/yesno.sh
82```
83
84## Library
85
86**API**
87
88 - [bsddialog.h](https://gitlab.com/alfix/bsddialog/-/blob/main/lib/bsddialog.h)
89 - [bsddialog\_theme.h](https://gitlab.com/alfix/bsddialog/-/blob/main/lib/bsddialog_theme.h)
90
91
92**Manual**
93
94 - [bsddialog(3)](https://alfonsosiciliano.gitlab.io/posts/2022-01-15-manual-libbsddialog.html)
95
96
97**Examples**:
98
99[Examples](https://gitlab.com/alfix/bsddialog/-/tree/main/examples_library)
100in the _Public Domain_ to build new projects:
101```
102% cd examples_library
103% sh compile
104% ./datebox
105% ./form
106% ./infobox
107% ./menu
108% ./mixedlist
109% ./msgbox
110% ./pause
111% ./radiolist
112% ./rangebox
113% ./theme
114% ./timebox
115% ./yesno
116```
117
118