sub printSettings { my @groups = shift; foreach my $table (@groups) { foreach my $info (@$table) { my $cnt = 1; print "=" x 60, "\n"; print " $info->[0]", " " x 20, "\n"; print "=" x 60, "\n"; foreach my $key (sort keys %{$info->[1]}) { printf "%5s. %-25s %-5s $info->[1]{$key}\n", $cnt, $key, "=>"; $cnt++; } } } } sub viewTheme { #print "[(a)ll, (b)ase, (m)enu, tag(l)ist, (o)other]{Enter to quit}: "; #chomp (my $item = ); my $item = shift; my $base = ["Base Elements", \%theme_base]; my $taglist = ["Taglist Elements", \%theme_taglist]; my $menu = ["Menu Elements", \%theme_menu]; my $other = ["Other Elements", \%theme_other]; return unless ($item); return [$base] if ($item =~ /^\s*(?:b|base)\s*$/i); return [$taglist] if ($item =~ /^\s*(?:l|taglist)\s*$/i); return [$menu] if ($item =~ /^\s*(?:m|menu)\s*$/i); return [$other] if ($item =~ /^\s*(?:o|other)\s*$/i); if ($item =~ /^\s*(?:a|all)\s*$/i) { return [$base, $taglist, $menu, $other]; } say "Invalid Entry: $item\n"; viewTheme(); }