From 6d6f3679f33801b6412627912231f1357656a46c Mon Sep 17 00:00:00 2001 From: aplsimple Date: Tue, 17 Nov 2020 20:20:46 +0300 Subject: [PATCH] v3.2.2 --- apave.tcl | 9 +++- apaveinput.tcl | 2 +- baltip/baltip.tcl | 27 ++++++---- baltip/pkgIndex.tcl | 2 +- hl_tcl/hl_tcl.tcl | 15 ++++-- hl_tcl/pkgIndex.tcl | 2 +- obbit.tcl | 121 +++++++++++++++++++++++-------------------- pkgIndex.tcl | 2 +- tests/test2_pave.tcl | 20 +++---- 9 files changed, 114 insertions(+), 86 deletions(-) diff --git a/apave.tcl b/apave.tcl index e5393db..5f4443d 100644 --- a/apave.tcl +++ b/apave.tcl @@ -2356,7 +2356,14 @@ oo::class create ::apave::APave { set addcomms {} if {[set tooltip [::apave::getOption -tooltip {*}$attrs]] ne ""} { my initTooltip - lappend addcomms [list baltip::tip $wdg $tooltip] + if {[set i [string first " -ATTR " $tooltip]]>0} { + set tooltip [string range $tooltip 1 end-1] + set tattrs [string range $tooltip $i+6 end] + set tooltip "{[string range $tooltip 0 $i-2]}" + } else { + set tattrs "" + } + lappend addcomms [list baltip::tip $wdg $tooltip {*}$tattrs] lappend ::apave::_AP_VARS(TIMW) $wdg set attrs [::apave::removeOptions $attrs -tooltip] } diff --git a/apaveinput.tcl b/apaveinput.tcl index f592c76..8d2b206 100644 --- a/apaveinput.tcl +++ b/apaveinput.tcl @@ -34,7 +34,7 @@ package require Tk -package provide apave 3.2.1 +package provide apave 3.2.2 source [file join [file dirname [info script]] apavedialog.tcl] diff --git a/baltip/baltip.tcl b/baltip/baltip.tcl index ed87aae..6200b99 100755 --- a/baltip/baltip.tcl +++ b/baltip/baltip.tcl @@ -9,7 +9,7 @@ # License: MIT. # _______________________________________________________________________ # -package provide baltip 0.8 +package provide baltip 0.8.1 package require Tk @@ -291,13 +291,13 @@ proc ::baltip::my::Show {w text force geo optvals} { catch {wm attributes $win -alpha $data(-alpha)} } else { ::baltip::my::Fade $win $aint [expr {round(1.0*$data(-pause)/$aint)}] \ - 0 Un $data(-alpha) 1 + 0 Un $data(-alpha) 1 $geo } if {$force} { - ::baltip::my::Fade $win $aint $fint $icount {} $data(-alpha) 1 + ::baltip::my::Fade $win $aint $fint $icount {} $data(-alpha) 1 $geo } else { after $data(-pause) [list \ - ::baltip::my::Fade $win $aint $fint $icount {} $data(-alpha) 1] + ::baltip::my::Fade $win $aint $fint $icount {} $data(-alpha) 1 $geo] } } else { # just showing, no fading @@ -308,7 +308,7 @@ proc ::baltip::my::Show {w text force geo optvals} { } #_____ -proc ::baltip::my::Fade {w aint fint icount Un alpha show {geos ""}} { +proc ::baltip::my::Fade {w aint fint icount Un alpha show geo {geos ""}} { # Fades/unfades the tip's window. # w - the tip's window # aint - interval for 'after' @@ -317,18 +317,19 @@ proc ::baltip::my::Fade {w aint fint icount Un alpha show {geos ""}} { # Un - if equal to "Un", unfades the tip # alpha - value of -alpha option # show - flag "show the window" + # geo - coordinates (+X+Y) of balloon # geos - saved coordinates (+X+Y) of shown tip # See also: FadeNext, UnFadeNext update if {[winfo exists $w]} { after idle [list after $aint \ - [list ::baltip::my::${Un}FadeNext $w $aint $fint $icount $alpha $show $geos]] + [list ::baltip::my::${Un}FadeNext $w $aint $fint $icount $alpha $show $geo $geos]] } } #_____ -proc ::baltip::my::FadeNext {w aint fint icount alpha show {geos ""}} { +proc ::baltip::my::FadeNext {w aint fint icount alpha show geo {geos ""}} { # A step to fade the tip's window. # w - the tip's window # aint - interval for 'after' @@ -336,6 +337,7 @@ proc ::baltip::my::FadeNext {w aint fint icount alpha show {geos ""}} { # icount - counter of intervals # alpha - value of -alpha option # show - flag "show the window" + # geo - coordinates (+X+Y) of balloon # geos - saved coordinates (+X+Y) of shown tip # See also: Fade @@ -345,8 +347,8 @@ proc ::baltip::my::FadeNext {w aint fint icount alpha show {geos ""}} { if {![winfo exists $w]} return lassign [split [wm geometry $w] +] -> X Y if {$geos ne "" && $geos ne "+$X+$Y"} return + set al [expr {min($alpha,($fint+$icount*1.5)/$fint)}] if {$icount<0} { - set al [expr {min($alpha,($fint+$icount*1.5)/$fint)}] if {$al>0} { if {[catch {wm attributes $w -alpha $al}]} {set al 0} } @@ -354,12 +356,14 @@ proc ::baltip::my::FadeNext {w aint fint icount alpha show {geos ""}} { catch {destroy $w} return } + } elseif {$al>0 && $geo eq ""} { + catch {wm attributes $w -alpha $al} } - Fade $w $aint $fint $icount {} $alpha $show +$X+$Y + Fade $w $aint $fint $icount {} $alpha $show $geo +$X+$Y } #_____ -proc ::baltip::my::UnFadeNext {w aint fint icount alpha show {geos ""}} { +proc ::baltip::my::UnFadeNext {w aint fint icount alpha show geo {geos ""}} { # A step to unfade the balloon's window. # w - the tip's window # aint - interval for 'after' @@ -367,6 +371,7 @@ proc ::baltip::my::UnFadeNext {w aint fint icount alpha show {geos ""}} { # icount - counter of intervals # alpha - value of -alpha option # show - not used (here just for compliance with Fade) + # geo - not used (here just for compliance with Fade) # geos - not used (here just for compliance with Fade) # See also: Fade @@ -378,7 +383,7 @@ proc ::baltip::my::UnFadeNext {w aint fint icount alpha show {geos ""}} { set show 0 } if {[winfo exists $w] && $al<$alpha} { - Fade $w $aint $fint $icount Un $alpha 0 + Fade $w $aint $fint $icount Un $alpha 0 $geo } } #_____ diff --git a/baltip/pkgIndex.tcl b/baltip/pkgIndex.tcl index 314f1e4..3763d71 100644 --- a/baltip/pkgIndex.tcl +++ b/baltip/pkgIndex.tcl @@ -1,4 +1,4 @@ -package ifneeded baltip 0.8 [list source [file join $dir baltip.tcl]] +package ifneeded baltip 0.8.1 [list source [file join $dir baltip.tcl]] namespace eval ::baltip { diff --git a/hl_tcl/hl_tcl.tcl b/hl_tcl/hl_tcl.tcl index bab9c25..6150720 100644 --- a/hl_tcl/hl_tcl.tcl +++ b/hl_tcl/hl_tcl.tcl @@ -6,7 +6,7 @@ # License: MIT. # _______________________________________________________________________ # -package provide hl_tcl 0.7.2 +package provide hl_tcl 0.7.3 # _______________ Common data of ::hl_tcl:: namespace ______________ # @@ -390,14 +390,18 @@ proc ::hl_tcl::my::MemPos {txt} { variable data set ln [$txt index insert] + set updcurr [expr {![info exists data(CUR_POS,$txt)] || \ + int($data(CUR_POS,$txt)) != int($ln)}] set data(CUR_POS,$txt) $ln set data(CUR_LEN,$txt) [$txt index end] lassign [CountQSH $txt $ln] \ data(CNT_QUOTE,$txt) data(CNT_SLASH,$txt) data(CNT_COMMENT,$txt) - $txt tag remove tagBRACKET 1.0 end - $txt tag remove tagBRACKETERR 1.0 end - $txt tag remove tagCURLINE 1.0 end - $txt tag add tagCURLINE [list $ln linestart] [list $ln lineend]+1displayindices + if {[$txt tag ranges tagBRACKET] ne ""} {$txt tag remove tagBRACKET 1.0 end} + if {[$txt tag ranges tagBRACKETERR] ne ""} {$txt tag remove tagBRACKETERR 1.0 end} + if {$updcurr} { + $txt tag remove tagCURLINE 1.0 end + $txt tag add tagCURLINE [list $ln linestart] [list $ln lineend]+1displayindices + } } #_____ @@ -840,6 +844,7 @@ proc ::hl_tcl::hl_text {txt} { $txt tag configure tagBRACKETERR -foreground white -background red $txt tag configure tagCURLINE -background $clrCURL $txt tag raise sel + $txt tag raise tagBRACKETERR my::HighlightAll $txt if {![info exists ::hl_tcl::my::data(BIND_TXT,$txt)]} { bind $txt [list + [namespace current]::my::MemPos $txt] diff --git a/hl_tcl/pkgIndex.tcl b/hl_tcl/pkgIndex.tcl index f2f6399..2e1598a 100644 --- a/hl_tcl/pkgIndex.tcl +++ b/hl_tcl/pkgIndex.tcl @@ -1,5 +1,5 @@ -package ifneeded hl_tcl 0.7.2 [list source [file join $dir hl_tcl.tcl]] +package ifneeded hl_tcl 0.7.3 [list source [file join $dir hl_tcl.tcl]] # short intro (for Ruff! docs generator) diff --git a/obbit.tcl b/obbit.tcl index b8f70a0..eb7fec1 100644 --- a/obbit.tcl +++ b/obbit.tcl @@ -30,57 +30,65 @@ namespace eval ::apave { set ::apave::_CS_(!FG) #000000 set ::apave::_CS_(!BG) #c3c3c3 set ::apave::_CS_(expo,tfg1) "-" - # = name fg item bg bg itemsHL actbg actfg cc greyed hot - # clrtitf clrinaf clrtitb clrinab clrhelp clractb clractf clrcurs clrgrey clrhotk fI bI -fM- bM + +# Colors for : 1) meanings 2) code names + +# itemfg mainfg itembg mainbg itemsHL actbg actfg cursor greyed hot \ + emfg embg - menubg winfg winbg #002...reserved... + +# clrtitf clrinaf clrtitb clrinab clrhelp clractb clractf clrcurs clrgrey clrhotk \ + fI bI -fM- bM fW bW #002...reserved... + set ::apave::_CS_(ALL) { -{MildDark #E8E8E8 #E7E7E7 #222A2F #2D435B #FEEFA8 #739bb9 black #00ffff grey #76b0c3 black #6d95b3 - #3c546e #000 #001 #002 #003 #004 #005 #006 #007} -{Inkpot #d3d3ff #AFC2FF #05050e #1E1E27 #a4a4e5 #8e8ecf black #ff9900 grey orange black #8585c6 - #292936 #000 #001 #002 #003 #004 #005 #006 #007} -{Green #E8E8E8 #EFEFEF #0F3F0A #274923 #FEEC9A #8fad98 black #E69800 grey #E69800 black #88a691 - #3e603a #000 #001 #002 #003 #004 #005 #006 #007} -{Brown #E8E8E8 #E7E7E7 #352927 #453528 #FEEC9A #b4a489 black #E69800 grey #E69800 black #ab9b80 - #524235 #000 #001 #002 #003 #004 #005 #006 #007} -{Magenta #E8E8E8 #F0E8E8 #2B1137 #4A2A4A #FEEC9A #b898b8 black #E69800 grey #E69800 black #ad8dad - #573757 #000 #001 #002 #003 #004 #005 #006 #007} -{Red white #CECECB #340202 #440702 yellow #df8d8d black red #440701 orange black #ba6868 - #440702 #000 #001 #002 #003 #004 #005 #006 #007} -{Anti-Light1 #bebebe #bebebe #333333 #242424 #FEEFA8 #8d8d8d black #ff9900 grey #70C6C6 #000000 #636363 - #1c1c1c #000 #001 #002 #003 #004 #005 #006 #007} -{Anti-Light2 #bebebe #bebebe #242424 #333333 #FEEFA8 #8d8d8d black #ff9900 grey #70C6C6 #000000 #636363 - #2b2b2b #000 #001 #002 #003 #004 #005 #006 #007} -{Darcula #dedede #A1ACB6 #272727 #303030 #B09869 #2F5692 #EDC881 #ff9900 grey #f0a471 #EDC881 #1a417d - #444444 #000 #001 #002 #003 #004 #005 #006 #007} -{Sleepy #daefd0 #D0D0D2 #3b4043 #2E3436 #CB956D #899498 black #ff9900 grey #B0B000 black #828d91 - #383E40 #000 #001 #002 #003 #004 #005 #006 #007} -{Dark #E0D9D9 #C4C4C4 #232323 #303030 #CCCC90 #aaaaaa black #E69800 grey #E69800 black #a2a2a2 - #424242 #000 #001 #002 #003 #004 #005 #006 #007} -{DarkGrey #F0E8E8 #E7E7E7 #333333 #494949 #DCDC9B #bbbbbb black #E69800 grey #E69800 black #adadad - #595959 #000 #001 #002 #003 #004 #005 #006 #007} -{Sandy #211D1C #27201F #FEFAEB #F7EEC5 #523A0A #cdbf9a #2f0a00 #802e00 grey #933232 black #b9ab86 - #e4dbb2 #000 #001 #002 #003 #004 #005 #006 #007} -{African black black #ffe2a2 #ffffb4 brown #d3a876 #000000 red grey SaddleBrown #3b1516 #f9b777 - #ffffd0 #000 #001 #002 #003 #004 #005 #006 #007} -{Rosy #2B122A #000000 #FFFFFF #F6E6E9 #570957 #C5ADC8 black #802e00 grey #870287 #000000 #C5ADC8 - #d6c6c9 #000 #001 #002 #003 #004 #005 #006 #007} -{InverseGrey #121212 #1A1A1A #c9cbcf #DADCE0 #302206 #777777 white #802e00 #DADCE1 #933232 #FFFFFF #6d6d6d - #c9cbcf #000 #001 #002 #003 #004 #005 #006 #007} -{Grey #000000 #0D0D0D #FFFFFF #DADCE0 #362607 #AFAFAF black #802e00 grey #933232 #000000 #AFAFAF - #caccd0 #000 #001 #002 #003 #004 #005 #006 #007} -{Anti-Dark1 #2e3436 #2e3436 #F8F8F8 #dadad8 #362607 #AFAFAF black #802e00 grey #933232 #000000 #AFAFAF - #caccd0 #000 #001 #002 #003 #004 #005 #006 #007} -{Anti-Dark2 #2e3436 #2e3436 #dadad8 #F8F8F8 #362607 #AFAFAF black #802e00 grey #933232 #000000 #AFAFAF - #e1e1df #000 #001 #002 #003 #004 #005 #006 #007} -{Florid black darkgreen #dbffdb white brown #93e493 #0F2D0F #802e00 grey #802e00 black #8adb8a - #dff4df #000 #001 #002 #003 #004 #005 #006 #007} -{LightGreen #122B05 #091900 #FFFFFF #DEF8DE #562222 #A8CCA8 black #802e00 grey #933232 #000000 #A8CCA8 - #c3ddc3 #000 #001 #002 #003 #004 #005 #006 #007} -{InverseGreen #122B05 #091900 #cce6c8 #DEF8DE #562222 #9cc09c black #802e00 #DEF8D1 #933232 black #98bc98 - #cce6cc #000 #001 #002 #003 #004 #005 #006 #007} -{Khakish #2e3436 #2e3436 #e1ffdd #cadfca #933232 #9dbb99 black #802e00 grey #AE5F02 #000000 #9cb694 - #bcdab8 #000 #001 #002 #003 #004 #005 #006 #007} -{Blue #08085D #030358 #FFFFFF #D2DEFA #562222 #9fb6e9 black #802e00 grey #933232 black #a5bcef - #b7c3df #000 #001 #002 #003 #004 #005 #006 #007} -{Sky #102433 #0A1D33 #D2EAF2 #AFDFEF #0D3239 #72b5c9 black #0052b9 grey #1261AD black #7bbed2 - #96c6d6 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-SourceForge #141414 #151616 #ffffff #a3dcff #144d70 #528bae white #0052b9 grey #189898 white #4982a5 - #8ac3e6 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Juicy #000000 #000000 #f1f1f1 #dddddd #41312b #bfbfbf black #802e00 grey #933232 black #a9a9a9 - #d3d3d3 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-FluidVision #000000 #000000 #f4f4f4 #cccccc #41312b #777777 white #802e00 grey #933232 white #6b6b6b - #BABABA #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-YellowStone #0000ff #00003c #fdf9d0 #d5d2af #00003c #d59d6f black #4A3706 grey #771d00 #00003c #e6ae80 - #DBD8B5 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-TurnOfCentury #333333 #333333 #d6c4b6 #ae9f94 #333333 #d59d6f black #4A3706 grey #771d00 black #e6ae80 - #a5968b #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Notebook #000000 #000000 #beb69d #96907c #000000 #d59d6f black #4A3706 grey #771d00 #000000 #e6ae80 - #85806E #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-IdleFingers #ffffff #ffffff #323232 #5a5a5a #ffffff #395472 white #ff9900 grey orange #ffffff #2d4866 - #4F4F4F #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Minimal #fcffe0 #ffffff #302d26 #5a5a5a #ffffff #395472 white #ff9900 grey orange #ffffff #2e4967 - #4F4F4F #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Monokai #f8f8f2 #f8f8f2 #272822 #4e5044 #f8f8f2 #8d8d8d black #ff959f grey orange black #777777 - #505147 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-LightVision #ffffff #ffffff #3C423C #515753 #ffc2a1 #8d8d8d black #ff959f grey orange black #777777 - #474D49 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-oscuro #f1f1f1 #f1f1f1 #344545 #526d6d #f1f1f1 #9eb9b9 black #ff959f grey orange black #94afaf - #475E5E #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-StarLight #C0B6A8 #C0B6A8 #223859 #315181 #C0B6A8 #7292c2 black #00ffff grey orange black #7d9dcd - #2D4A75 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-MildDark #d2d2d2 #ffffff #151616 #2D435B #ffbe00 #739bb9 black #00ffff grey #ffbb6d black #6c94b2 - #24384f #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-MildDark2 #b4b4b4 #ffffff #0d0e0e #24384f #ffbe00 #739bb9 black #00ffff grey #ffbb6d black #6890ae - #1B3048 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-MildDark3 #e2e2e2 #f1f1f1 #000000 #1B3048 #ffbe00 #739bb9 black #00ffff grey #ffbb6d black #668eac - #12273f #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-RubyBlue #ffffff #ffffff #121e31 #213659 #ffffff #6d88a6 black #00ffff grey orange black #66819f - #1C2E4D #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-MadeOfCode #f8f8f8 #f8f8f8 #090a1b #00348c #f8f8f8 #5d91e9 black #00ffff grey orange black #578be3 - #002C78 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-CoolGlow #e0e0e0 #e0e0e0 #06071d #0e1145 #e0e0e0 #7d8aee black #00ffff grey orange black #727fe3 - #171C73 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Quiverly #b6c1c1 #b6c1c1 #2b303b #333946 #fbffd7 #a1a7b4 black #ff9900 grey orange black #9197a4 - #414650 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Aurora #ececec #ececec #302e40 #4e4b68 #ececec #9b98b5 black #ff9900 grey orange black #8d8aa7 - #434259 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Choco #c3be98 #c3be98 #180c0c #402020 #c3be98 #664D4D white #ff9900 grey orange white #735a5a - #331A1A #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-AnatomyOfGrey #dfdfdf #ffffff #000000 #282828 #ffffff #8b8b8b black #ff9900 grey orange black #828282 - #363636 #000 #001 #002 #003 #004 #005 #006 #007} -{TKE-Default white white black #282828 white blue white #ff9900 grey orange white #0000d3 - #383838 #000 #001 #002 #003 #004 #005 #006 #007} +{MildDark #E8E8E8 #E7E7E7 #222A2F #2D435B #FEEFA8 #739bb9 black #00ffff grey #76b0c3 \ +black #6d95b3 - #3c546e black #b0b04c #002 #003 #004 #005 #006 #007} +{Inkpot #d3d3ff #AFC2FF #05050e #1E1E27 #a4a4e5 #8e8ecf black #ff9900 grey orange black #8585c6 - #292936 black #a2a23e #002 #003 #004 #005 #006 #007} +{Green #E8E8E8 #EFEFEF #0F3F0A #274923 #FEEC9A #8fad98 black #E69800 grey #E69800 black #88a691 - #3e603a black #bebe5a #002 #003 #004 #005 #006 #007} +{Brown #E8E8E8 #E7E7E7 #352927 #453528 #FEEC9A #b4a489 black #E69800 grey #E69800 black #ab9b80 - #524235 black #bebe5a #002 #003 #004 #005 #006 #007} +{Magenta #E8E8E8 #F0E8E8 #2B1137 #4A2A4A #FEEC9A #b898b8 black #E69800 grey #E69800 black #ad8dad - #573757 black #cdcd69 #002 #003 #004 #005 #006 #007} +{Red white #CECECB #340202 #440702 #efef2a #df8d8d black red #440701 orange black #ba6868 - #440702 black #bebe5a #002 #003 #004 #005 #006 #007} +{Anti-Light1 #bebebe #bebebe #333333 #242424 #FEEFA8 #8d8d8d black #ff9900 grey #70C6C6 #000000 #636363 - #1c1c1c black #bebe5a #002 #003 #004 #005 #006 #007} +{Anti-Light2 #bebebe #bebebe #242424 #333333 #FEEFA8 #8d8d8d black #ff9900 grey #70C6C6 #000000 #636363 - #2b2b2b black #b0b04c #002 #003 #004 #005 #006 #007} +{Darcula #dedede #A1ACB6 #272727 #303030 #B09869 #2F5692 #EDC881 #ff9900 grey #f0a471 #EDC881 #1a417d - #444444 black #a2a23e #002 #003 #004 #005 #006 #007} +{Sleepy #daefd0 #D0D0D2 #3b4043 #2E3436 #CB956D #899498 black #ff9900 grey #B0B000 black #828d91 - #383E40 black #b0b04c #002 #003 #004 #005 #006 #007} +{Dark #E0D9D9 #C4C4C4 #232323 #303030 #CCCC90 #aaaaaa black #E69800 grey #E69800 black #a2a2a2 - #424242 black #cdcd69 #002 #003 #004 #005 #006 #007} +{DarkGrey #F0E8E8 #E7E7E7 #333333 #494949 #DCDC9B #bbbbbb black #E69800 grey #E69800 black #adadad - #595959 black #cdcd69 #002 #003 #004 #005 #006 #007} +{Sandy #211D1C #27201F #FEFAEB #F7EEC5 #523A0A #cdbf9a #2f0a00 #802e00 grey #933232 black #b9ab86 - #e4dbb2 #000000 #ffff3a #002 #003 #004 #005 #006 #007} +{African black black #ffe2a2 #ffffb4 brown #d3a876 #000000 red grey SaddleBrown #3b1516 #f9b777 - #ffffd0 #000000 #ffff00 #002 #003 #004 #005 #006 #007} +{Rosy #2B122A #000000 #FFFFFF #F6E6E9 #570957 #C5ADC8 black #802e00 grey #870287 #000000 #C5ADC8 - #d6c6c9 #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{InverseGrey #121212 #1A1A1A #c9cbcf #DADCE0 #302206 #777777 white #802e00 #DADCE1 #933232 #FFFFFF #6d6d6d - #c9cbcf #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{Grey #000000 #0D0D0D #FFFFFF #DADCE0 #362607 #AFAFAF black #802e00 grey #933232 #000000 #AFAFAF - #caccd0 #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{Anti-Dark1 #2e3436 #2e3436 #F8F8F8 #dadad8 #362607 #AFAFAF black #802e00 grey #933232 #000000 #AFAFAF - #caccd0 #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{Anti-Dark2 #2e3436 #2e3436 #dadad8 #F8F8F8 #362607 #AFAFAF black #802e00 grey #933232 #000000 #AFAFAF - #e1e1df #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{Florid black darkgreen #dbffdb white brown #93e493 #0F2D0F #802e00 grey #802e00 black #8adb8a - #dff4df #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{LightGreen #122B05 #091900 #edffed #DEF8DE #562222 #A8CCA8 black #802e00 grey #933232 #000000 #A8CCA8 - #c3ddc3 #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{InverseGreen #122B05 #091900 #cce6c8 #DEF8DE #562222 #9cc09c black #802e00 #DEF8D1 #933232 black #98bc98 - #cce6cc #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{Khakish #2e3436 #2e3436 #e1ffdd #cadfca #933232 #9dbb99 black #802e00 grey #AE5F02 #000000 #9cb694 - #bcdab8 #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{Blue #08085D #030358 #FFFFFF #D2DEFA #562222 #9fb6e9 black #802e00 grey #933232 black #a5bcef - #b7c3df #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{Sky #102433 #0A1D33 #D2EAF2 #AFDFEF #0D3239 #72b5c9 black #0052b9 grey #1261AD black #7bbed2 - #96c6d6 #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{TKE-SourceForge #141414 #151616 #ffffff #a3dcff #144d70 #528bae white #0052b9 grey #189898 white #4982a5 - #8ac3e6 #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{TKE-Juicy #000000 #000000 #f1f1f1 #dddddd #41312b #bfbfbf black #802e00 grey #933232 black #a9a9a9 - #d3d3d3 #000000 #FBFB96 #002 #003 #004 #005 #006 #007} +{TKE-FluidVision #000000 #000000 #f4f4f4 #cccccc #41312b #777777 white #802e00 grey #933232 white #6b6b6b - #BABABA #000000 #FBFB95 #002 #003 #004 #005 #006 #007} +{TKE-YellowStone #0000ff #00003c #fdf9d0 #d5d2af #00003c #d59d6f black #4A3706 grey #771d00 #00003c #e6ae80 - #DBD8B5 #000000 #fbfb74 #002 #003 #004 #005 #006 #007} +{TKE-TurnOfCentury #333333 #333333 #d6c4b6 #ae9f94 #333333 #d59d6f black #4A3706 grey #771d00 black #e6ae80 - #a5968b #000000 #eded89 #002 #003 #004 #005 #006 #007} +{TKE-Notebook #000000 #000000 #beb69d #96907c #000000 #d59d6f black #4A3706 grey #771d00 #000000 #e6ae80 - #85806E #000000 #eded89 #002 #003 #004 #005 #006 #007} +{TKE-IdleFingers #ffffff #ffffff #323232 #5a5a5a #ffffff #395472 white #ff9900 grey orange #ffffff #2d4866 - #4F4F4F black #cdcd69 #002 #003 #004 #005 #006 #007} +{TKE-Minimal #fcffe0 #ffffff #302d26 #5a5a5a #ffffff #395472 white #ff9900 grey orange #ffffff #2e4967 - #4F4F4F black #cdcd69 #002 #003 #004 #005 #006 #007} +{TKE-Monokai #f8f8f2 #f8f8f2 #272822 #4e5044 #f8f8f2 #8d8d8d black #ff959f grey orange black #777777 - #505147 black #cdcd69 #002 #003 #004 #005 #006 #007} +{TKE-LightVision #ffffff #ffffff #3C423C #515753 #ffc2a1 #8d8d8d black #ff959f grey orange black #777777 - #474D49 black #cdcd69 #002 #003 #004 #005 #006 #007} +{TKE-oscuro #f1f1f1 #f1f1f1 #344545 #526d6d #f1f1f1 #9eb9b9 black #ff959f grey orange black #94afaf - #475E5E black #cdcd69 #002 #003 #004 #005 #006 #007} +{TKE-StarLight #C0B6A8 #C0B6A8 #223859 #315181 #C0B6A8 #7292c2 black #00ffff grey orange black #7d9dcd - #2D4A75 black #bebe5a #002 #003 #004 #005 #006 #007} +{TKE-MildDark #d2d2d2 #ffffff #151616 #2D435B #ffbe00 #739bb9 black #00ffff grey #ffbb6d black #6c94b2 - #24384f black #bebe5a #002 #003 #004 #005 #006 #007} +{TKE-MildDark2 #b4b4b4 #ffffff #0d0e0e #24384f #ffbe00 #739bb9 black #00ffff grey #ffbb6d black #6890ae - #1B3048 black #bebe5a #002 #003 #004 #005 #006 #007} +{TKE-MildDark3 #e2e2e2 #f1f1f1 #000000 #1B3048 #ffbe00 #739bb9 black #00ffff grey #ffbb6d black #668eac - #12273f black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-RubyBlue #ffffff #ffffff #121e31 #213659 #ffffff #6d88a6 black #00ffff grey orange black #66819f - #1C2E4D black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-MadeOfCode #f8f8f8 #f8f8f8 #090a1b #00348c #f8f8f8 #5d91e9 black #00ffff grey orange black #578be3 - #002C78 black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-CoolGlow #e0e0e0 #e0e0e0 #06071d #0e1145 #e0e0e0 #7d8aee black #00ffff grey orange black #727fe3 - #171C73 black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-Quiverly #b6c1c1 #b6c1c1 #2b303b #333946 #fbffd7 #a1a7b4 black #ff9900 grey orange black #9197a4 - #414650 black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-Aurora #ececec #ececec #302e40 #4e4b68 #ececec #9b98b5 black #ff9900 grey orange black #8d8aa7 - #434259 black #bebe5a #002 #003 #004 #005 #006 #007} +{TKE-Choco #c3be98 #c3be98 #180c0c #402020 #c3be98 #664D4D white #ff9900 grey orange white #735a5a - #331A1A black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-AnatomyOfGrey #dfdfdf #ffffff #000000 #282828 #ffffff #8b8b8b black #ff9900 grey orange black #828282 - #363636 black #b0b04c #002 #003 #004 #005 #006 #007} +{TKE-Default white white black #282828 white blue white #ff9900 grey orange white #0000d3 - #383838 black #b0b04c #002 #003 #004 #005 #006 #007} } #-RUNF1: ./tests/test2_pave.tcl #RUNF1: ./tests/test2_pave.tcl 0 9 12 @@ -585,6 +593,8 @@ oo::class create ::apave::ObjectTheming { if {"$ncolor" eq "" || $ncolor<0} { # basic color scheme: get colors from a current ttk::style colors + set fW black + set bW #FBFB95 if {[info exists ::apave::_CS_(def_fg)]} { set fg $::apave::_CS_(def_fg) set bg $::apave::_CS_(def_bg) @@ -614,8 +624,8 @@ oo::class create ::apave::ObjectTheming { set ::apave::_CS_(def_bclr) $bclr } return [list default \ - $fg $fg $bA $bg $fg $bS $fS #802e00 grey #4f6379 $fS $bS - $bg] - # clrtitf clrinaf clrtitb clrinab clrhelp clractb clractf clrcurs clrgrey clrhotk fI bI fM bM + $fg $fg $bA $bg $fg $bS $fS #802e00 grey #4f6379 $fS $bS - $bg $fW $bW] + # clrtitf clrinaf clrtitb clrinab clrhelp clractb clractf clrcurs clrgrey clrhotk fI bI fM bM fW bW } return [lindex $::apave::_CS_(ALL) $ncolor] } @@ -795,6 +805,7 @@ oo::class create ::apave::ObjectTheming { set ::apave::_CS_(old) $ncolor my themeWindow $win $fg $bg $fE $bE $fS $bS $grey $bg $cc $ht $hh $tfgI $tbgI $fM $bM my UpdateColors + my initTooltip } return [list $fg $bg $fE $bE $fS $bS $hh $gr $cc $ht $tfgI $tbgI $fM $bM] } @@ -1338,9 +1349,9 @@ oo::class create ::apave::ObjectTheming { # Configurates colors and other attributes of tooltip. # args - options of ::baltip::configure - if {[info commands ::baltip::configure] eq ""} { - package require baltip - } + if {[info commands ::baltip::configure] eq ""} {package require baltip} + lassign [lrange [my csGet] 14 15] fW bW + ::baltip config -fg $fW -bg $bW -global yes ::baltip config {*}$args return } diff --git a/pkgIndex.tcl b/pkgIndex.tcl index f072879..fc2dd5d 100644 --- a/pkgIndex.tcl +++ b/pkgIndex.tcl @@ -1,5 +1,5 @@ -package ifneeded apave 3.2.1 [list source [file join $dir apaveinput.tcl]] +package ifneeded apave 3.2.2 [list source [file join $dir apaveinput.tcl]] # A short intro (for Ruff! docs generator:) diff --git a/tests/test2_pave.tcl b/tests/test2_pave.tcl index 300be5b..e085810 100644 --- a/tests/test2_pave.tcl +++ b/tests/test2_pave.tcl @@ -172,9 +172,9 @@ namespace eval t { catch {::t::colorBar} } baltip::tip [pave BuT_Img4] \ - "Next is $::t::nextcs: [pave csGetName $::t::nextcs]" + "Next is $::t::nextcs: [pave csGetName $::t::nextcs]" -under 5 baltip::tip [pave BuT_Img3] \ - "Previous is $::t::prevcs: [pave csGetName $::t::prevcs]" + "Previous is $::t::prevcs: [pave csGetName $::t::prevcs]" -under 5 lassign [pave csGet] fg - bg - - bS fS set ::t::textTags [list \ [list "red" " -font {-weight bold} -foreground $fS -background $bS"] \ @@ -821,7 +821,7 @@ proc putsResult3 {} { if {[catch {image create photo $img -data [::apave::iconData $icon]}]} { image create photo $img -data [::apave::iconData none] } - append ::t::toolList " $img {{} -tooltip {Icon: $icon}}" + append ::t::toolList " $img {{} -tooltip {Icon: $icon -ATTR -under 4}}" } set ::bgst [ttk::style lookup TScrollbar -troughcolor] ttk::style conf TLabelframe -labelmargins {5 10 1 1} -padding 3 @@ -936,26 +936,26 @@ proc putsResult3 {} { # {# 2ND TAB (DEMO OF ttk::panewindow) } #################################################################### {tool - - - - {pack -side top} {-array { - Img1 {{::t::toolBut 1} -tooltip "Start progress" -state disabled} + Img1 {{::t::toolBut 1} -tooltip "Start progress -ATTR -under 5" -state disabled} h_ 3 - Img2 {{::t::toolBut 2} -tooltip "Stop progress"} + Img2 {{::t::toolBut 2} -tooltip "Stop progress -ATTR -under 5"} sev 7 h_ 1 - Img5 {{::t::e_menu} -tooltip "Run e_menu"} + Img5 {{::t::e_menu} -tooltip "Run e_menu -ATTR -under 5"} h_ 1 - Img6 {{::t::screenshooter} -tooltip "Run screenshooter"} + Img6 {{::t::screenshooter} -tooltip "Run screenshooter -ATTR -under 5"} sev 7 h_ 1 Img3 {{::t::toolBut 3 \[set ::t::prevcs\]}} h_ 1 - opcTool {::t::opcc ::t::opcColors {-width 20} {t::opcToolPre %a} -command t::opcToolPost -tooltip "Current color scheme"} + opcTool {::t::opcc ::t::opcColors {-width 20} {t::opcToolPre %a} -command t::opcToolPost -tooltip "Current color scheme -ATTR -under 3"} h_ 1 Img4 {{::t::toolBut 4 \[set ::t::nextcs\]}} h_ 4 - ChbRestart {-var ::t::restart -t "Restart" -tooltip "To restart test2\nif CS changes"} + ChbRestart {-var ::t::restart -t "Restart" -tooltip "To restart test2\nif CS changes -ATTR -under 3"} sev 8 h_ 1 - spX {-tvar ::t::fontsz -command {::t::toolBut 4 -3} -from 8 -to 16 -w 3 -justify center -tooltip "Font size 8..16" -myown { + spX {-tvar ::t::fontsz -command {::t::toolBut 4 -3} -from 8 -to 16 -w 3 -justify center -tooltip "Font size 8..16 -ATTR -under 3" -myown { puts "\nA local/global configuration may be set with -myown attribute, e.g.\ \n %w configure -bg yellow -font {-weight bold}\ \n ::NS::GLOBAL_CONFIG %w"}}