Fix CreatePanel.py, mode setXY: substitute variables in base widget
Warning, cannot access the index:
_darcs/index: opening of '_darcs/index' failed: permission denied (Permission denied)
diff -rN -u old-bii_scripts/bin/CreatePanel.pl new-bii_scripts/bin/CreatePanel.pl
--- old-bii_scripts/bin/CreatePanel.pl 2022-12-09 20:59:16.688802552 +0100
+++ new-bii_scripts/bin/CreatePanel.pl 2022-12-09 20:59:16.688802552 +0100
@@ -623,9 +623,12 @@
#print "rH_subst:",Dumper($r_substData);
my $baseWidget = (defined $baseW) ? $baseW : $inFileName;
$baseWidget =~s/\.substitutions/\.edl/;
-
- my ($prEdl, $panelWidth, $panelHeight) = getDisplay($baseWidget);
- die "can' find base widget: \'$baseWidget\'" unless defined $prEdl;
+
+ my $rH_Attr;
+ $rH_Attr = $options{SUBSTITUTIONS} if( defined $options{SUBSTITUTIONS});
+ my ($base, $panelWidth, $panelHeight) = getDisplay($baseWidget);
+ my $prEdl = setWidget($base,$panelWidth,$panelHeight,$rH_Attr, 1,0,0);
+ die "can' find base widget: \'$baseWidget\'" unless defined $prEdl;
print "layout XY: base panel: $baseWidget: w=$panelWidth, h=$panelHeight\n" if $opt_v == 1;
my($p,$xPos,$yPos) = setTitle($rH_options,0,0) if defined $rH_options->{TITLE};
@@ -1275,6 +1278,7 @@
}
#substitute the PV variable
$edl = parsePV($edl,$rH_Attr);
+ $edl = parsePV($edl,$options{SUBSTITUTIONS}) if( defined $options{SUBSTITUTIONS});
#substitute all other variables
$edl = parseVars($edl,$rH_Attr);
$edl = parseVars($edl,$options{SUBSTITUTIONS}) if( defined $options{SUBSTITUTIONS});
patch 9404661a9e4af528e8a47239fef3828d5d38565c
Author: Bernhard.Kuner@bessy.de
Date: Mon Apr 26 08:26:06 CEST 2021
* Fix CreatePanel.py, mode setXY: substitute variables in base widget