From 529c61050f2137b3ba6ff3ab9c78df8dad61dce2 Mon Sep 17 00:00:00 2001 From: Christopher Chavez Date: Tue, 18 Jun 2019 21:45:47 -0500 Subject: [PATCH 1/2] Derived.pm: do not set default colors As done in Tcl::pTk 1.00. --- Tk/Derived.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Tk/Derived.pm b/Tk/Derived.pm index 1685c781..c3e467e9 100644 --- a/Tk/Derived.pm +++ b/Tk/Derived.pm @@ -339,14 +339,14 @@ sub ConfigDefault Tk::catch { $cw->Tk::cget('-background') }; my (@bg) = $@ ? ('PASSIVE') : ('SELF'); push(@bg,'CHILDREN') if $child; - $specs->{'-background'} = [\@bg,'background','Background',NORMAL_BG]; + $specs->{'-background'} = [\@bg,'background','Background',undef]; } unless (exists($specs->{'-foreground'})) { Tk::catch { $cw->Tk::cget('-foreground') }; my (@fg) = $@ ? ('PASSIVE') : ('SELF'); push(@fg,'CHILDREN') if $child; - $specs->{'-foreground'} = [\@fg,'foreground','Foreground',BLACK]; + $specs->{'-foreground'} = [\@fg,'foreground','Foreground',undef]; } $cw->ConfigAlias(-fg => '-foreground', -bg => '-background'); From 4d71dffab5a02913f107c441d7b25afa41d36576 Mon Sep 17 00:00:00 2001 From: Christopher Chavez Date: Sun, 23 Jun 2019 02:18:03 -0500 Subject: [PATCH 2/2] Balloon.pm, DialogBox.pm adjustments As done in Tcl::pTk 1.01: - Balloon.pm: set default foreground to 'black' - DialogBox.pm: do not set default foreground color --- Tixish/Balloon.pm | 2 +- Tixish/DialogBox.pm | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Tixish/Balloon.pm b/Tixish/Balloon.pm index 8b8fa4fb..32899d70 100644 --- a/Tixish/Balloon.pm +++ b/Tixish/Balloon.pm @@ -108,7 +108,7 @@ sub Populate { -cancelcommand => ['CALLBACK', 'cancelCommand', 'CancelCommand', undef], -motioncommand => ['CALLBACK', 'motionCommand', 'MotionCommand', undef], -background => ['DESCENDANTS', 'background', 'Background', '#C0C080'], - -foreground => ['DESCENDANTS', 'foreground', 'Foreground', undef], + -foreground => ['DESCENDANTS', 'foreground', 'Foreground', 'black'], -font => [$ml, 'font', 'Font', '-*-helvetica-medium-r-normal--*-120-*-*-*-*-*-*'], -borderwidth => ['SELF', 'borderWidth', 'BorderWidth', 1], -numscreens=>['PASSIVE', 'numScreens','NumScreens',1], diff --git a/Tixish/DialogBox.pm b/Tixish/DialogBox.pm index 6111a0ec..ae9d1893 100644 --- a/Tixish/DialogBox.pm +++ b/Tixish/DialogBox.pm @@ -79,7 +79,7 @@ sub Populate { warn "Cancel button `$cancel_button' does not exist.\n"; } $cw->ConfigSpecs(-command => ['CALLBACK', undef, undef, undef ], - -foreground => ['DESCENDANTS', 'foreground','Foreground', 'black'], + -foreground => ['DESCENDANTS', 'foreground','Foreground', undef], -background => ['DESCENDANTS', 'background','Background', undef], -focus => ['PASSIVE', undef, undef, undef], -showcommand => ['CALLBACK', undef, undef, undef],