diff options
author | Nick White <git@njw.me.uk> | 2014-01-30 17:27:55 +0000 |
---|---|---|
committer | Nick White <git@njw.me.uk> | 2014-01-30 17:27:55 +0000 |
commit | 03a33a151138dc31681e42407ea3a8ab869bc038 (patch) | |
tree | d892ba42343d577123395b433722c1a5bf714dbe | |
parent | 170cc4b91cf6f7d6266363bd73ec55a3db9b60ff (diff) | |
download | tkread-03a33a151138dc31681e42407ea3a8ab869bc038.tar.bz2 tkread-03a33a151138dc31681e42407ea3a8ab869bc038.zip |
Colour selection nicely
-rwxr-xr-x | tkread | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -21,6 +21,7 @@ set fontsize 16 set textcolour #443322 set bgcolour #eeeee2 set outercolour #222222 +set selectbgcolour #ffffff set inverttextcolour #eeeeee set invertbgcolour #333030 set invertoutercolour #222222 @@ -156,7 +157,7 @@ if { [lsearch [font families] "$fontfamily"] == -1 } { set fontfamily Times } . configure -bg $outercolour -text .t -font "{$fontfamily} $fontsize" -wrap word -width 64 -padx [expr $fontsize * 3] -bg $bgcolour -fg $textcolour -relief flat +text .t -font "{$fontfamily} $fontsize" -wrap word -width 64 -padx [expr $fontsize * 3] -bg $bgcolour -fg $textcolour -relief flat -inactiveselectbackground $selectbgcolour pack .t -expand yes -fill y set text [read stdin] foreach arg $::argv { @@ -169,7 +170,7 @@ foreach arg $::argv { if { $domarkdown } { markup .t } -.t configure -state disabled ;# disable cursor +.t configure -state disabled ;# disable text insertion & cursor bind . <Up> {scroll -1 unit} bind . <k> {scroll -1 unit} |