1.\" 2.\" Copyright (c) 2021-2024 Alfonso Sabato Siciliano 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. 9.\" 2. Redistributions in binary form must reproduce the above copyright 10.\" notice, this list of conditions and the following disclaimer in the 11.\" documentation and/or other materials provided with the distribution. 12.\" 13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 16.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23.\" SUCH DAMAGE. 24.\" 25.Dd May 25, 2024 26.Dt BSDDIALOG 1 27.Os 28.Sh NAME 29.Nm bsddialog 30.Nd TUI dialogs 31.Sh SYNOPSIS 32.Nm 33.Fl Fl help | Fl Fl version 34.Nm 35.Op Fl Fl option 36.Fl Fl dialog 37.Ar text 38.Ar rows 39.Ar cols 40.Op Ar dialog-argument 41.Op Fl Fl option 42.Nm 43\&... 44.Fl Fl dialog1 45.Ar ... 46.Oo Fl Fl and-dialog 47.Fl Fl dialog2 48.Ar ... 49.Oc ... 50.Sh DESCRIPTION 51The 52.Nm bsddialog 53utility builds Text User Interface dialogs and widgets. 54.Pp 55The option 56.Fl Fl help 57prints a brief list of features and exits. 58The option 59.Fl Fl version 60prints the version and exits. 61The option 62.Fl Fl and-dialog 63builds another dialog unless the previous one returns Error, ESC or Cancel. 64.Pp 65Each dialog accepts 66.Ar text 67to print a message inside, 68.Ar rows 69and 70.Ar cols 71to set height and width, 72.Dv 0 73for autosize and 74.Dv -1 75for fullscreen. 76.Pp 77The possible input from the user interface is printed to standard error at exit. 78.Ss Options 79The following options can change the default behavior of the utility and are 80common to some dialog. 81.Bl -tag -width Ds 82.It Fl Fl alternate-screen 83If available set alternate screen mode, see 84.Xr terminfo 5 . 85.It Fl Fl ascii-lines 86Ascii characters to draw lines. 87.It Fl Fl backtitle Ar backtitle 88Screen title. 89.It Fl Fl begin-x Ar x 90Set dialog horizontal position, 91.Dv -1 92center, 93.Dv 0 94left screen. 95.It Fl Fl begin-y Ar y 96Set dialog vertical position, 97.Dv -1 98center, 99.Dv 0 100top screen. 101.It Fl Fl bikeshed 102Random settings. 103Colors, title delimiter, button delimiter; see theme features. 104Title margin. 105Buttons always active or TAB to switch focus with other components, see 106.Fl Fl switch-buttons . 107Zero padding with time output; see 108.Fl Fl time-format . 109Zero padding with date output; see 110.Fl Fl date-format . 111User Interface date format for 112.Fl Fl datebox ; 113see 114.Fl Fl datebox-format . 115.It Fl Fl cancel-exit-code Ar retval 116Set an exit code value for the 117.Dq Cancel 118button. 119.It Fl Fl cancel-label Ar label 120Label for the 121.Dq Cancel 122button. 123.It Fl Fl clear-dialog 124Hide the dialog at exit. 125.It Fl Fl clear-screen 126Clear the screen, wait a dialog if built. 127.It Fl Fl columns-per-row Ar columns 128Try to set the number of columns for a row of text with autosizing; default 129.Dv 10 . 130.It Fl Fl cr-wrap 131Keep new line in 132.Ar text 133also if it constains a 134.Dq \en , 135see 136.Fl Fl text-unchanged . 137.It Fl Fl datebox-format Ar format 138String to customize 139.Fl Fl datebox 140interface, possible values: 141.Dq d/m/y , 142.Dq m/y/d , 143.Dq y/m/d . 144.It Fl Fl date-format Ar format 145String accepted by 146.Xr strftime 3 147to customize the output of 148.Fl Fl datebox 149and 150.Fl Fl calendar . 151.It Fl Fl default-button Ar label 152Focus on the button with 153.Ar label 154on startup. 155.It Fl Fl default-item Ar name 156Focus on the item with 157.Ar name , 158for Checklist, Menu, Radiolist and Treeview. 159.It Fl Fl default-no 160Focus on 161.Dq Cancel 162or 163.Dq \&No 164button on startup. 165.It Fl Fl disable-esc 166Disable ESC key to quit. 167.It Fl Fl error-exit-code Ar retval 168Set an exit code value for the 169.Nm 170errors. 171.It Fl Fl esc-exit-code Ar retval 172Set an exit code value for the 173.Dv ESC 174key. 175.It Fl Fl extra-button 176Add a button with 177.Dq Extra 178label. 179.It Fl Fl extra-exit-code Ar retval 180Set an exit code value for the 181.Dq Extra 182button. 183.It Fl Fl extra-label Ar label 184Set 185.Ar label 186for the 187.Dq Extra 188button. 189.It Fl Fl left1-button Ar label 190Add a button with 191.Ar label . 192.It Fl Fl left1-exit-code Ar retval 193Set an exit code for 194.Fl Fl left1-button . 195.It Fl Fl left2-button Ar label 196Add a button with 197.Ar label . 198.It Fl Fl left2-exit-code Ar retval 199Set an exit code for 200.Fl Fl left2-button . 201.It Fl Fl left3-button Ar label 202Add a button with 203.Ar label . 204.It Fl Fl left3-exit-code Ar retval 205Set an exit code for 206.Fl Fl left3-button . 207.It Fl Fl help-button 208Add a button with 209.Dq Help 210label. 211.It Fl Fl help-exit-code Ar retval 212Set an exit code value for the 213.Dq Help 214button. 215.It Fl Fl help-label Ar label 216Set 217.Ar label 218for 219.Dq Help 220button. 221.It Fl Fl help-print-items 222Print also the selected items or form values if the 223.Dq Help 224button is pressed. 225.It Fl Fl help-print-name 226Print the name of the focused item if the 227.Dq Help 228button is pressed also 229with 230.Fl Fl item-bottom-desc . 231.It Fl Fl hfile Ar filename 232Open 233.Ar filename 234in a Textbox if F1 key is pressed. 235.It Fl Fl hline Ar string 236Dialog subtitle. 237.It Fl Fl hmsg Ar string 238Open a Msgbox with 239.Ar string 240if the F1 key is pressed. 241.It Fl Fl ignore 242Do not exit with unknown options. 243.It Fl Fl insecure 244Print 245.Sq * 246to hide passwords while typing, white space otherwise. 247.It Fl Fl item-bottom-desc 248Set a help string for each item of a Checklist, Form, Menu, Mixedform, 249Passwordform, Radiolist and Treeview to display at the bottom screen side. 250.It Fl Fl item-depth 251Specify a margin for items, available for Checklist, Menu and Radiolist. 252.It Fl Fl item-prefix 253Set a string to prefix each item of a Checklist, Menu, Radiolist or Treeview. 254.It Fl Fl load-theme Ar file 255Load theme from 256.Ar file . 257.It Fl Fl max-input Ar size 258Maximum length of the input for 259.Fl Fl inputbox 260and 261.Fl Fl passwordbox , 262default 2048. 263.It Fl Fl no-cancel 264Do not show 265.Dq Cancel 266button. 267.It Fl Fl no-descriptions 268Do not display items desciption, for Checklist, Menu, Radiolist or Treeview; 269mutually exclusive with 270.Fl Fl no-names . 271.It Fl Fl no-lines 272Do not draw borders and lines. 273.It Fl Fl no-names 274Do not display items name, for Checklist, Menu and Radiolist; mutually exclusive 275with 276.Fl Fl no-descriptions . 277.It Fl Fl no-ok 278Do not draw 279.Dq OK 280button. 281.It Fl Fl no-shadow 282No not draw the shadow of the dialog. 283.It Fl Fl ok-label Ar label 284Set 285.Ar label 286for 287.Dq OK 288button. 289.It Fl Fl ok-exit-code Ar retval 290Set an exit code value for the 291.Dq Ok 292button. 293.It Fl Fl normal-screen 294If available set normal screen mode, see 295.Xr terminfo 5 . 296.It Fl Fl output-fd Ar fd 297Print input from user interface to the specified file descriptor. 298.It Fl Fl output-separator Ar sep 299Set a sepator for the items in output, default white space. 300.It Fl Fl print-maxsize 301Screen size. 302This option can be used without a dialog. 303.It Fl Fl print-size 304Print dialog height and width at exit. 305.It Fl Fl print-version 306Print version. 307This option can be used without a dialog. 308.It Fl Fl quoted 309Quote items in output, default only when necessary. 310.It Fl Fl right1-button Ar label 311Add a button with 312.Ar label . 313.It Fl Fl right1-exit-code Ar retval 314Set an exit code for 315.Fl Fl right1-button . 316.It Fl Fl right2-button Ar label 317Add a button with 318.Ar label . 319.It Fl Fl right2-exit-code Ar retval 320Set an exit code for 321.Fl Fl right2-button . 322.It Fl Fl right3-button Ar label 323Add a button with 324.Ar label . 325.It Fl Fl right3-exit-code Ar retval 326Set an exit code for 327.Fl Fl right3-button . 328.It Fl Fl save-theme Ar file 329Save the current theme. 330This option can be used without a dialog. 331.It Fl Fl separate-output 332Print selected items separated by a new line and avoid to quote. 333.It Fl Fl shadow 334Show a shadow for the dialog, enabled by default. 335.It Fl Fl single-quoted 336Use single quote for items in output. 337.It Fl Fl sleep Ar secs 338Wait 339.Ar secs 340seconds to close the dialog. 341.It Fl Fl stderr 342Print input from user interface to standand error, default. 343.It Fl Fl stdout 344Print input from user interface to standard output. 345.It Fl Fl switch-buttons 346Enable focus switching between buttons and input components pressing TAB, 347otherwise buttons are always active and ENTER key closes the dialog. 348Suitable for: 349.Fl Fl form , 350.Fl Fl inputbox , 351.Fl Fl mixedform , 352.Fl Fl passwordbox , 353.Fl Fl passwordform , 354.Fl Fl timebox , 355.Fl Fl calendar 356and 357.Fl Fl datebox . 358.It Fl Fl tab-escape 359Replace 360.Dq \et 361with a tab in 362.Ar text . 363.It Fl Fl tab-len Ar spaces 364Number of spaces to print a TAB in 365.Ar text . 366.It Fl Fl text-escape 367Enable escapes in 368.Ar text : 369.Bl -column -compact 370.It Dq \eZ0 371black. 372.It Dq \eZ1 373red. 374.It Dq \eZ2 375green. 376.It Dq \eZ3 377yellow. 378.It Dq \eZ4 379blue. 380.It Dq \eZ5 381magenta. 382.It Dq \eZ6 383cyan. 384.It Dq \eZ7 385white. 386.It Dq \eZb 387bold. 388.It Dq \eZB 389disable bold. 390.It Dq \eZd 391Half bright. 392.It Dq \eZD 393disable half bright. 394.It Dq \eZk 395Blink. 396.It Dq \eZK 397disable blinking. 398.It Dq \eZr 399reverse foreground and background. 400.It Dq \eZR 401disable reverse. 402.It Dq \eZs 403Highlight. 404.It Dq \eZS 405disable highlighting. 406.It Dq \eZu 407underline. 408.It Dq \eZU 409disable underline. 410.It Dq \eZn 411disable each customization. 412.El 413.It Fl Fl text-unchanged 414Disable 415.Ar text 416modification. 417By default 418.Ar text 419is changed before to be printed in the dialog. 420If it contains at least a 421.Dq \en 422each new line and TAB is converted to a space, subsequent spaces are merged. 423Otherwise new line characters are preserved and a TAB becomes a space. 424.It Fl Fl theme Ar theme 425Set theme, possible values: 426.Dq 3d , 427.Dq blackwhite , 428.Dq flat . 429.It Fl Fl time-format Ar format 430String accepted by 431.Xr strftime 3 432to customize the output of 433.Fl Fl timebox . 434.It Fl Fl timeout-exit-code Ar retval 435Set an exit code value for the 436.Fl Fl pause 437timeout. 438.It Fl Fl title Ar title 439Dialog title. 440.El 441.Ss Keys 442The following keys are available at runtime: 443.Bl -tag -width Ds 444.It Ctrl-l 445Redraw the dialog. 446.It F1 447See 448.Fl Fl hfile 449and 450.Fl Fl hmsg . 451.It SPACE 452Select menu item. 453.It UP DOWN LEFT RIGHT - + HOME END PAGEUP PAGEDOWN Ctrl-p Ctrl-n TAB 454Navigate elements and set value, depending on the dialog. 455.El 456.Ss Dialogs 457The following dialogs are available: 458.Bl -tag -width Ds 459.It Fl Fl calendar Ar text Ar rows Ar cols Op Ar day Ar month Ar year 460Dialog to select a date. 461.It Fl Fl checklist Ar text Ar rows Ar cols Ar menurows Oo Ar name Ar desc \ 462Ar status Oc ... 463Checklist to select some item from a list via the SPACE key. 464An item has a 465.Ar name , 466.Ar desc 467and a default 468.Ar status 469specified by 470.Dq on 471or 472.Dq off . 473The names of the selected items are printed to standard error. 474.Ar menurows 475is the graphical height of the list, 0 for autosize. 476.It Fl Fl datebox Ar text Ar rows Ar cols Op Ar day Ar month Ar year 477Dialog to select a date. 478.It Fl Fl form Ar text Ar rows Ar cols Ar formrows Oo Ar label Ar ylabel \ 479Ar xlabel Ar init Ar yfield Ar xfield Ar fieldlen Ar maxletters Oc ... 480Dialog to get a list of strings via forms. 481A form has a 482.Ar label 483at the position 484.Ar ylabel 485and 486.Ar xlabel , 487a field to get the input at the position 488.Ar yfield 489and 490.Ar xfield . 491.Ar fieldlen 492is the field width, if negative is readonly and the width is the absolute value, 493if 494.Dv 0 495the field becomes readonly and its value is the 496.Ar init 497width. 498The field input is not printed to output if it is readonly. 499.Ar maxletters 500is the maximum input length, if is 501.Dv 0 502its value is 503.Ar fieldlen . 504.Ar init 505is the default value in the field. 506.Ar formrows 507is the graphical height of the list, 508.Dv 0 509for autosize. 510.It Fl Fl gauge Ar text Ar rows Ar cols Op Ar percentage 511Dialog with a bar to shows 512.Ar percentage , 513then it waits to read 514.Dq XXX 515from the standard input, then the first string replaces percentage and the 516following strings replace 517.Ar text 518until the next 519.Dq XXX , 520the loop ends reading 521.Dq EOF . 522.It Fl Fl infobox Ar text Ar rows Ar cols 523Dialog without buttons to display a message and to exit immediately. 524.It Fl Fl inputbox Ar text Ar rows Ar cols Op Ar init 525Dialog to get a string in input, 526.Ar init 527is the default value. 528.It Fl Fl menu Ar text Ar rows Ar cols Ar menurows Oo Ar name desc Oc ... 529Builds a menu to select an item from a list, SPACE key is equivalent to ENTER. 530An item has a 531.Ar name 532and a 533.Ar desc . 534The name of the selected item is printed to standard error. 535.Ar menurows 536is the graphical height of the list, 0 for autosize. 537.It Fl Fl mixedform Ar text Ar rows Ar cols Ar formrows Oo Ar label Ar ylabel \ 538Ar xlabel Ar init Ar yfield Ar xfield Ar fieldlen Ar maxletters Ar flag Oc ... 539Dialog to get a list of strings via forms. 540A form has a 541.Ar label 542at the position 543.Ar ylabel 544and 545.Ar xlabel , 546a field to get the input at the position 547.Ar yfield 548and 549.Ar xfield . 550.Ar fieldlen 551is the field width, if negative is readonly and the width is the absolute value, 552if 553.Dv 0 554the field becomes readonly and its value is the 555.Ar init 556width. 557The field input is not printed to output if 558.Ar fieldlen 559is less than or equal to 560.Dv 0 . 561.Ar maxletters 562is the maximum input length, if is 563.Dv 0 564its value is 565.Ar fieldlen . 566.Ar init 567is the default value in the field. 568.Ar flag 569can customize 570.Ar field : 571.Dv 0 572normal, 573.Dv 1 574hide typed characters, 575.Dv 2 576readonly. 577.Ar formrows 578is the graphical height of the list, 579.Dv 0 580for autosize. 581.It Fl Fl mixedgauge Ar text Ar rows Ar cols Ar mainperc Oo Ar minilabel \ 582Ar miniperc Oc ... 583Dialog to show a main bar to represent 584.Ar mainperc 585from 0 to 100. 586Some mini bar with a 587.Ar minilabel 588string and a 589.Ar miniperc 590with a value from 0 and 100 or negative to print a descriptive string: -1 591.Dq Succeeded , 592-2 593.Dq Failed , 594-3 595.Dq Passed , 596-4 597.Dq Completed , 598-5 599.Dq Checked , 600-6 601.Dq Done , 602-7 603.Dq Skipped , 604-8 605.Dq \&In Progress , 606-9 607to hide 608.Fa miniperc , 609-10 610.Dq N/A , 611-11 612.Dq Pending , 613otherwise 614.Dq UNKNOWN . 615.It Fl Fl msgbox Ar text Ar rows Ar cols 616Dialog to diplay a message without the 617.Dq Cancel 618button. 619.It Fl Fl passwordbox Ar text Ar rows Ar cols Op Ar init 620Dialog to get a password, 621.Ar init 622is the default value. 623.It Fl Fl passwordform Ar text Ar rows Ar cols Ar formrows Oo Ar label \ 624Ar ylabel Ar xlabel Ar init Ar yfield Ar xfield Ar fieldlen Ar maxletters \ 625Oc ... 626Dialog to get a list of passwords, equivalent to 627.Fl Fl form 628except typed characters are hidden. 629.It Fl Fl pause Ar text Ar rows Ar cols Ar seconds 630Dialog runs until 631.Ar seconds 632timeout expires or a button is pressed. 633.It Fl Fl radiolist Ar text Ar rows Ar cols Ar menurows Oo Ar name Ar desc \ 634Ar status Oc ... 635Radiolist to select at most an item from a list via the SPACE key. 636An item has a 637.Ar name , 638.Ar desc 639and a default 640.Ar status 641specified by 642.Dq on 643or 644.Dq off . 645The name of the selected item is printed to standard error. 646.Ar menurows 647is the graphical height of the list, 0 for autosize. 648.It Fl Fl rangebox Ar text Ar rows Ar cols Ar min Ar max Op Ar init 649Dialog to select a value between 650.Ar min 651and 652.Ar max , 653.Ar init 654is the default value. 655.It Fl Fl textbox Ar file Ar rows Ar cols 656Opens and prints 657.Ar file . 658TAB changes button. 659Extra keys 0, h, l, k, j are available to navigate the text. 660.Dq OK 661button is renamed 662.Dq EXIT . 663.It Fl Fl timebox Ar text Ar rows Ar cols Op Ar hour Ar min Ar sec 664Dialog to select a time. 665.It Fl Fl treeview Ar text Ar rows Ar cols Ar menurows Oo Ar depth Ar name \ 666Ar desc Ar status Oc ... 667Equivalent to Radiolist with 668.Fl Fl item-depth 669and 670.Fl Fl no-name . 671.It Fl Fl yesno Ar text Ar rows Ar cols 672.Dq Yes-No Question , 673.Dq OK 674and 675.Dq Cancel 676buttons are renamed 677.Dq Yes 678and 679.Dq \&No . 680.El 681.Sh ENVIRONMENT 682The following environment variables take effect only on startup, other options 683can override their setting. 684.Bl -tag -width indent 685.It Ev NO_COLOR 686If present and not an empty string (regardless of its value) equivalent to 687.Fl Fl theme Ar blackwhite . 688.It Ev BSDDIALOG_ERROR , Ev BSDDIALOG_OK , Ev BSDDIALOG_CANCEL , \ 689Ev BSDDIALOG_HELP , Ev BSDDIALOG_EXTRA , Ev BSDDIALOG_TIMEOUT , \ 690Ev BSDDIALOG_ESC , Ev BSDDIALOG_LEFT1 , Ev BSDDIALOG_LEFT2 , \ 691Ev BSDDIALOG_LEFT3 , Ev BSDDIALOG_RIGHT1 , Ev BSDDIALOG_RIGHT2 , \ 692Ev BSDDIALOG_RIGHT3 693Set exit codes. 694.It Ev BSDDIALOG_THEMEFILE Ar file 695Equivalent to 696.Fl Fl load-theme Ar file . 697.El 698.Sh FILES 699The theme file 700.Pa $HOME/.bsddialog.conf 701is read on startup if exists. 702.Sh EXIT STATUS 703The 704.Nm 705utility exits 255 on unsuccessful, otherwise depending on the button or key 706pressed the following values can be returned: 707.Bl -column -compact 708.It 0 709.Dq OK , 710.Dq Yes 711or 712.Dq Exit 713button. 714.It 1 715.Dq Cancel 716or 717.Dq \&No 718button. 719.It 2 720.Dq Help 721button. 722.It 3 723.Dq Extra 724button. 725.It 4 726Timeout. 727.It 5 728ESC key. 729.It 6 730Left1 generic button. 731.It 7 732Left2 generic button. 733.It 8 734Left3 generic button. 735.It 9 736Right1 generic button. 737.It 10 738Right2 generic button. 739.It 11 740Right2 generic button. 741.El 742.Sh EXAMPLES 743Backtitle, title and message: 744.Dl bsddialog --backtitle MESSAGE --title Msgbox --msgbox Message 0 0 745.Pp 746Yes-No Question and theme: 747.Dl bsddialog --theme blackwhite --yesno Question 10 30 748.Pp 749Save a custom theme: 750.Dl bsddialog --save-theme mytheme.txt --infobox \*qSaving theme...\*q 0 0 751.Pp 752Load a custom theme: 753.Dl bsddialog --load-theme mytheme.txt --infobox \*qCustom theme\*q 0 0 754.Pp 755Checklist: 756.Dl bsddialog --checklist Checklist 0 0 3 N1 \&D1 off N2 D2 on N3 D3 off 757.Pp 758Form: 759.Dl bsddialog --form Form 0 0 0 L1: 0 0 X 0 4 20 25 L2: 1 0 Y 1 4 20 25 760.Pp 761Multi-dialog: 762.Dl bsddialog --normal-screen --begin-y 1 --yesno Continue? 0 0 \e \ 763--and-dialog --begin-y 10 --infobox Yes 0 0 764.Pp 765Bikeshed: 766.Dl bsddialog --bikeshed --inputbox Example 0 0 767.Dl bsddialog --bikeshed --datebox Example 0 0 768.Pp 769Mixedgauge: 770.Dl bsddialog --sleep 3 --mixedgauge Example 10 30 60 L1 \*q -1\*q L2 30 771.Pp 772Mixedgauge script: 773.Bd -literal -offset indent -compact 774perc=0 775while [ $perc -le 100 ] 776do 777 bsddialog --sleep 1 --title Mixedgauge \e 778 --mixedgauge "\enExample...\en" 0 0 $perc \e 779 "Hidden" " -9" \e 780 "Label 1" " -4" \e 781 "Label 2" " -4" \e 782 "Label 3" $perc 783 784 perc=`expr $perc + 20` 785done 786.Ed 787.Pp 788Gauge script: 789.Bd -literal -offset indent -compact 790i=1 791for c in A B C D E F G H 792do 793 sleep 1 794 echo XXX 795 echo "$(expr $(expr $i "*" 100) "/" 8)" 796 echo "[$i/8] Char: $c" 797 echo XXX 798 if [ $i -eq 8 ] 799 then 800 sleep 1 801 echo EOF 802 fi 803 i=`expr $i + 1` 804done | bsddialog --title Gauge --gauge "Starting..." 10 70 805.Ed 806.Sh COMPATIBILITY 807Outdated options are retained for compatibility, properly equivalent options are 808used: 809.Bd -literal -offset indent -compact 810Obsolete Equivalent 811--and-widget --and-dialog 812--calendar <text> 2 <cols> --calendar <text> 0 <cols> 813--clear --clear-screen 814--colors --text-escape 815--defaultno --default-no 816--exit-label --ok-label 817--help-status --help-print-items 818--help-tags --help-print-name 819--item-help --item-bottom-desc 820--keep-tite --alternate-screen 821--no-items --no-descriptions 822--no-label --cancel-label 823--no-tags --no-names 824--nocancel --no-cancel 825--nook --no-ok 826--separator --output-separator 827--yes-label --ok-label 828.Ed 829.Sh SEE ALSO 830.Xr bsddialog 3 , 831.Xr strftime 3 , 832.Xr terminfo 5 833.Sh HISTORY 834The 835.Nm bsddialog 836utility first appeared in 837.Fx 14.0 . 838.Sh AUTHORS 839.Nm bsddialog 840was written by 841.An Alfonso Sabato Siciliano 842.Aq Mt asiciliano@FreeBSD.org . 843.Pp 844.Nm bsddialog 845provides also a subset of the functionality described in the 846.Nm dialog 847manual. 848The following features were reimplemented: 849.Pp 850Options: 851.Fl Fl and-widget , 852.Fl Fl ascii-lines , 853.Fl Fl backtitle , 854.Fl Fl cancel-label , 855.Fl Fl clear , 856.Fl Fl colors , 857.Fl Fl cr-wrap , 858.Fl Fl date-format , 859.Fl Fl defaultno , 860.Fl Fl default-button , 861.Fl Fl default-no , 862.Fl Fl default-item , 863.Fl Fl exit-label , 864.Fl Fl extra-button , 865.Fl Fl extra-label , 866.Fl Fl help , 867.Fl Fl help-button , 868.Fl Fl help-label , 869.Fl Fl help-status , 870.Fl Fl help-tags , 871.Fl Fl hfile , 872.Fl Fl hline , 873.Fl Fl ignore , 874.Fl Fl insecure , 875.Fl Fl item-help , 876.Fl Fl keep-tite , 877.Fl Fl max-input , 878.Fl Fl no-cancel , 879.Fl Fl nocancel , 880.Fl Fl no-items , 881.Fl Fl no-label , 882.Fl Fl no-lines , 883.Fl Fl no-ok , 884.Fl Fl nook , 885.Fl Fl no-shadow , 886.Fl Fl no-tags , 887.Fl Fl ok-label , 888.Fl Fl output-fd , 889.Fl Fl output-separator , 890.Fl Fl print-maxsize , 891.Fl Fl print-size , 892.Fl Fl print-version , 893.Fl Fl quoted , 894.Fl Fl separate-output , 895.Fl Fl separator , 896.Fl Fl shadow , 897.Fl Fl single-quoted , 898.Fl Fl sleep , 899.Fl Fl stderr , 900.Fl Fl stdout , 901.Fl Fl tab-len , 902.Fl Fl time-format , 903.Fl Fl title , 904.Fl Fl version , 905.Fl Fl yes-label . 906.Pp 907Keys: Ctrl-l, F1. 908.Pp 909Dialogs: 910.Fl Fl calendar , 911.Fl Fl checklist , 912.Fl Fl form , 913.Fl Fl gauge , 914.Fl Fl infobox , 915.Fl Fl inputbox , 916.Fl Fl menu , 917.Fl Fl mixedform , 918.Fl Fl mixedgauge , 919.Fl Fl msgbox , 920.Fl Fl passwordbox , 921.Fl Fl passwordform , 922.Fl Fl pause , 923.Fl Fl radiolist , 924.Fl Fl rangebox , 925.Fl Fl textbox , 926.Fl Fl timebox , 927.Fl Fl treeview , 928.Fl Fl yesno . 929.Pp 930Some feature differs in input, output, or behavior. 931Compatibility is not a priority for future development. 932.Sh THANKS TO 933.An Baptiste Daroussin 934.Aq Mt bapt@FreeBSD.org , 935.An \&Ed Maste 936.Aq Mt emaste@FreeBSD.org , 937.An Juraj Lutter 938.Aq Mt otis@FreeBSD.org 939and 940.An Trenton Schulz 941for suggestions, help, and testing. 942