summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2010-02-04 01:58:57 +0000
committerNorbert Preining <preining@logic.at>2010-02-04 01:58:57 +0000
commit1921ef49afe5000b4b465f01ffeaec7a2f9397d6 (patch)
treeb80e0c1fbd9d66bb321a4d98e216f2c5bb935a39 /Master
parentb28e1fdb89dfc2a6f0344af73ff47bc4e36e5815 (diff)
add a perl script to check for the actually used font in Tk
git-svn-id: svn://tug.org/texlive/trunk@16912 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/tlpkg/dev/check-tk-used-font.pl30
1 files changed, 30 insertions, 0 deletions
diff --git a/Master/tlpkg/dev/check-tk-used-font.pl b/Master/tlpkg/dev/check-tk-used-font.pl
new file mode 100644
index 00000000000..c906c5506e6
--- /dev/null
+++ b/Master/tlpkg/dev/check-tk-used-font.pl
@@ -0,0 +1,30 @@
+
+use strict;
+$^W=1;
+
+use Tk;
+use Tk::Font;
+
+my $mw = MainWindow->new();
+my $l = $mw->Label(-text => "Hello");
+$l->pack;
+
+my $f = $l->Font();
+
+my %fp = $f->configure();
+print "preset settings:\n";
+for my $k (keys %fp) {
+ if (defined($fp{$k})) {
+ print "$k -> $fp{$k}\n";
+ } else {
+ print "$k -> undefined\n";
+ }
+}
+
+print "actually used settings:\n";
+my %fp = $f->actual();
+for my $k (keys %fp) {
+ print "$k -> $fp{$k}\n";
+}
+
+