From b249ca69a00fdd997a3998286c85ac68447f781b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?IOhannes=20m=20zm=C3=B6lnig?= Date: Mon, 28 Oct 2013 14:14:48 +0000 Subject: honour PD_KIOSK_CONFIG envvar for setting kiosk-config file svn path=/trunk/guiplugins/kiosk-plugin/; revision=17223 --- kiosk-plugin.tcl | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'kiosk-plugin.tcl') diff --git a/kiosk-plugin.tcl b/kiosk-plugin.tcl index 48886bf..d173d17 100644 --- a/kiosk-plugin.tcl +++ b/kiosk-plugin.tcl @@ -33,6 +33,7 @@ set ::kiosk::config(GeometryMain) "" proc ::kiosk::readconfig {{fname kiosk.cfg}} { + set orgname $fname if {[file exists $fname]} { set fp [open $fname r] } else { @@ -40,7 +41,7 @@ proc ::kiosk::readconfig {{fname kiosk.cfg}} { if {[file exists $fname]} { set fp [open $fname r] } else { - puts "kiosk.cfg not found" + puts "kiosk-configuration not found: $orgname" return False } } @@ -125,7 +126,11 @@ proc ::kiosk::makekiosk {mywin} { ###################################### ## read the default configuration file "kiosk.cfg" -::kiosk::readconfig +if { [info exists ::env(PD_KIOSK_CONFIG) ] } { + ::kiosk::readconfig $::env(PD_KIOSK_CONFIG) +} { + ::kiosk::readconfig +} ###### do some global KIOSK-settings -- cgit v1.2.1