X-Git-Url: http://git.tuebingen.mpg.de/?p=gsu.git;a=blobdiff_plain;f=misc%2Fgsu%2Fgui;h=99da51a78cf74091eb8b7f726883e5b2cb3f1bc8;hp=12c8b8b7685f346e7bccb0ff4aecd5788350f01b;hb=d7c3e4925d48003b996017e9a1c9d1e103272266;hpb=ced36439642170f319be76187907bccc2ea32ce0 diff --git a/misc/gsu/gui b/misc/gsu/gui index 12c8b8b..99da51a 100644 --- a/misc/gsu/gui +++ b/misc/gsu/gui @@ -7,7 +7,7 @@ fi export GSU_NODE_NAME_PATTERN='[a-zA-Z_]' -get_geometry() +_get_geometry() { local x y result="$(stty size)" @@ -23,7 +23,7 @@ get_geometry() gsu_infobox() { - get_geometry + _get_geometry dialog --infobox "$1" $result } @@ -33,7 +33,7 @@ gsu_checklist_all_on() local items="$2" local i state opts num=0 - get_geometry + _get_geometry ops="$result 16" for i in $items; do let num++ @@ -50,7 +50,7 @@ gsu_radiolist() local items="$3" local i state ops num=0 - get_geometry + _get_geometry ops="$result 16" for i in $items; do let num++ @@ -69,7 +69,7 @@ gsu_inputbox() { local g text="$1" init="$2" - get_geometry + _get_geometry g="$result" result="$(dialog --inputbox "$text" $g "$init" 3>&1 1>&2 2>&3 3>&-)" ret="$?" @@ -79,7 +79,7 @@ gsu_textbox() { local file="$1" - get_geometry + _get_geometry dialog --textbox "$file" $result } @@ -115,7 +115,7 @@ gsu_yesno() { local text="$1" - get_geometry + _get_geometry dialog --yesno "$text" $result ret=$? if (($ret == 0)); then @@ -133,13 +133,13 @@ gsu_menu() local items="$2" local i state opts num=0 - get_geometry + _get_geometry opts="$result 16" for i in $items; do let num++ opts+=" $i $num" done - result="$(dialog --menu "$header" $opts 3>&1 1>&2 2>&3 3>&-)" + result="$(dialog --menu "$gsu_banner_txt ($header)" $opts 3>&1 1>&2 2>&3 3>&-)" ret="$?" } @@ -208,5 +208,5 @@ gsu_gui() fi _get_root_nodes "$tree" subtree="$result" - _browse "$gsu_name main menu" "$tree" "$subtree" + _browse "main menu" "$tree" "$subtree" }