summaryrefslogtreecommitdiff
path: root/Master/texmf-dist
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist')
-rwxr-xr-xMaster/texmf-dist/doc/support/findhyph/findhyph.bat40
-rw-r--r--Master/texmf-dist/doc/support/findhyph/findhyph.txt4
-rwxr-xr-xMaster/texmf-dist/scripts/findhyph/findhyph40
3 files changed, 58 insertions, 26 deletions
diff --git a/Master/texmf-dist/doc/support/findhyph/findhyph.bat b/Master/texmf-dist/doc/support/findhyph/findhyph.bat
index 46ed04cbccc..92c077d672e 100755
--- a/Master/texmf-dist/doc/support/findhyph/findhyph.bat
+++ b/Master/texmf-dist/doc/support/findhyph/findhyph.bat
@@ -19,7 +19,7 @@ $opt_l = 'kKsSvVzZoOuUiIA'; # defaults for Slovak and Czech
$opt_c = $opt_f = $opt_h = $opt_v = 0;
getopts('cfphvl:');
-$version_msg = "findhyph version 3.0\n";
+$version_msg = "findhyph version 3.1\n";
$help_msg = "\nUsage: findhyph [options] <yourtexfile.log>\n" .
"\n" .
"Options: -c display hyphenated words in context\n" .
@@ -176,16 +176,22 @@ sub do_hyph {
for $i (1..$max_break-1) {
if (defined $USED[$i]) {
if ($search_hyphens) { # hyphenated words
- if ($act_text =~ /(\S+\@$i\@\S+)/) { # only hyphenated words match
- $out_text = $1;
+ if ($act_text =~ /(\S+)(\@$i\@)(\S+)/) { # only hyphenated words match
+ $out_pre = $1;
+ $out_post = $3;
+ if (substr($out_pre,-1) ne "-") { # hyphenated ligatures
+ $out_pre_A = substr($out_pre,0,rindex($out_pre,"-"));
+ $out_pre_B = substr($out_pre,rindex($out_pre,"-")+1);
+ $out_pre = $out_pre_A;
+ $out_post = $out_pre_B.$out_post;
+ }
if ($opt_c) {
- $context_before = $context_after = "";
- if ($act_text =~ /(\S+)\s+\S+\@$i\@/) {$context_before = $1;}
- if ($act_text =~ /\@$i\@\S+\s+(\S+)/) {$context_after = $1;}
- $out_text = "$context_before $out_text $context_after";
+ if ($act_text =~ /(\S+)\s+\S+\@$i\@/) {$out_pre = "$1 $out_pre";}
+ if ($act_text =~ /\@$i\@\S+\s+(\S+)/) {$out_post = "$out_post $1";}
}
- $out_text =~ s/-//g;
- $out_text =~ s/\@$i\@/-/g;
+ $out_pre =~ s/-//g;
+ $out_post =~ s/-//g;
+ $out_text = "$out_pre-$out_post";
$out_text =~ s/\@\d+\@//g; # very narrow columns
print O1 "$out_text\n";
$write_hyph_page = 1;
@@ -196,10 +202,8 @@ sub do_hyph {
$out_text = $1;
if ($out_text =~ /^[$opt_l]$/) {
if ($opt_c) {
- $context_before = $context_after = "";
- if($act_text =~ /(\S+) \S \@$i\@/) {$context_before = $1;}
- if($act_text =~ /\@$i\@ ?(\S+)/) {$context_after = $1;}
- $out_text = "$context_before $out_text $context_after";
+ if($act_text =~ /(\S+) \S \@$i\@/) {$out_text = "$1 $out_text";}
+ if($act_text =~ /\@$i\@ ?(\S+)/) {$out_text = "$out_text $1";}
$out_text =~ s/-//g;
$out_text =~ s/\@\d+\@//g; # very narrow columns
}
@@ -361,6 +365,16 @@ for identifying the issue)
=back
+=head4 3.1 (2012-11-03)
+
+=over 4
+
+=item *
+
+fixed displaying of hyphenated ligatures (bug reported by Karel Horak)
+
+=back
+
=head1 LICENSE
This program is free software; you can redistribute it and/or modify
diff --git a/Master/texmf-dist/doc/support/findhyph/findhyph.txt b/Master/texmf-dist/doc/support/findhyph/findhyph.txt
index ed089eed89e..5c55c059a8f 100644
--- a/Master/texmf-dist/doc/support/findhyph/findhyph.txt
+++ b/Master/texmf-dist/doc/support/findhyph/findhyph.txt
@@ -82,6 +82,10 @@ HISTORY
* "\looseness" setting is now taken into account (thanks to Karel
Horak for identifying the issue)
+ 3.1 (2012-11-03)
+ * fixed displaying of hyphenated ligatures (bug reported by Karel
+ Horak)
+
LICENSE
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
diff --git a/Master/texmf-dist/scripts/findhyph/findhyph b/Master/texmf-dist/scripts/findhyph/findhyph
index 66fa67d999a..e66f55a8db2 100755
--- a/Master/texmf-dist/scripts/findhyph/findhyph
+++ b/Master/texmf-dist/scripts/findhyph/findhyph
@@ -6,7 +6,7 @@ $opt_l = 'kKsSvVzZoOuUiIA'; # defaults for Slovak and Czech
$opt_c = $opt_f = $opt_h = $opt_v = 0;
getopts('cfphvl:');
-$version_msg = "findhyph version 3.0\n";
+$version_msg = "findhyph version 3.1\n";
$help_msg = "\nUsage: findhyph [options] <yourtexfile.log>\n" .
"\n" .
"Options: -c display hyphenated words in context\n" .
@@ -163,16 +163,22 @@ sub do_hyph {
for $i (1..$max_break-1) {
if (defined $USED[$i]) {
if ($search_hyphens) { # hyphenated words
- if ($act_text =~ /(\S+\@$i\@\S+)/) { # only hyphenated words match
- $out_text = $1;
+ if ($act_text =~ /(\S+)(\@$i\@)(\S+)/) { # only hyphenated words match
+ $out_pre = $1;
+ $out_post = $3;
+ if (substr($out_pre,-1) ne "-") { # hyphenated ligatures
+ $out_pre_A = substr($out_pre,0,rindex($out_pre,"-"));
+ $out_pre_B = substr($out_pre,rindex($out_pre,"-")+1);
+ $out_pre = $out_pre_A;
+ $out_post = $out_pre_B.$out_post;
+ }
if ($opt_c) {
- $context_before = $context_after = "";
- if ($act_text =~ /(\S+)\s+\S+\@$i\@/) {$context_before = $1;}
- if ($act_text =~ /\@$i\@\S+\s+(\S+)/) {$context_after = $1;}
- $out_text = "$context_before $out_text $context_after";
+ if ($act_text =~ /(\S+)\s+\S+\@$i\@/) {$out_pre = "$1 $out_pre";}
+ if ($act_text =~ /\@$i\@\S+\s+(\S+)/) {$out_post = "$out_post $1";}
}
- $out_text =~ s/-//g;
- $out_text =~ s/\@$i\@/-/g;
+ $out_pre =~ s/-//g;
+ $out_post =~ s/-//g;
+ $out_text = "$out_pre-$out_post";
$out_text =~ s/\@\d+\@//g; # very narrow columns
print O1 "$out_text\n";
$write_hyph_page = 1;
@@ -183,10 +189,8 @@ sub do_hyph {
$out_text = $1;
if ($out_text =~ /^[$opt_l]$/) {
if ($opt_c) {
- $context_before = $context_after = "";
- if($act_text =~ /(\S+) \S \@$i\@/) {$context_before = $1;}
- if($act_text =~ /\@$i\@ ?(\S+)/) {$context_after = $1;}
- $out_text = "$context_before $out_text $context_after";
+ if($act_text =~ /(\S+) \S \@$i\@/) {$out_text = "$1 $out_text";}
+ if($act_text =~ /\@$i\@ ?(\S+)/) {$out_text = "$out_text $1";}
$out_text =~ s/-//g;
$out_text =~ s/\@\d+\@//g; # very narrow columns
}
@@ -348,6 +352,16 @@ for identifying the issue)
=back
+=head4 3.1 (2012-11-03)
+
+=over 4
+
+=item *
+
+fixed displaying of hyphenated ligatures (bug reported by Karel Horak)
+
+=back
+
=head1 LICENSE
This program is free software; you can redistribute it and/or modify