summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtkread8
1 files changed, 4 insertions, 4 deletions
diff --git a/tkread b/tkread
index 60fcbf4..4a712b8 100755
--- a/tkread
+++ b/tkread
@@ -45,8 +45,8 @@ set surroundfmt { \
}
set underlinefmt { \
- {"==" "6" ""} \
- {"--" "3" "italic"} \
+ {"=" "6" ""} \
+ {"-" "3" "italic"} \
}
if { $::argc > 0 && [lindex $::argv 0] == "-h" } {
@@ -161,14 +161,14 @@ proc markup {widget} {
set fmtsizemod [lindex $fmt 1]
set fmtstring [lindex $fmt 2]
- set cur [$widget search -regexp "^$searchchar" 0.0 end]
+ set cur [$widget search -regexp "^$searchchar$searchchar*\$" 0.0 end]
while {$cur != ""} {
set dotindex [string first . $cur]
set linenum [string range $cur 0 [expr $dotindex - 1]]
$widget tag add underline_$underlinenum [expr $linenum - 1].0 $linenum.end
$widget delete $linenum.0 [expr $linenum + 1].0
- set cur [$widget search -regexp "^$searchchar" [expr $linenum + 1].0 end]
+ set cur [$widget search -regexp "^$searchchar$searchchar*\$" [expr $linenum + 1].0 end]
}
$widget tag configure underline_$underlinenum -font "{$fontfamily} [expr $fontsize + $fmtsizemod] $fmtstring"
incr underlinenum