diff options
author | Karl Berry <karl@freefriends.org> | 2014-03-11 22:16:52 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2014-03-11 22:16:52 +0000 |
commit | da1cdc98ee437aab0f962bae0e48a6b02a0b27c2 (patch) | |
tree | 3bf88c625d7db84ddd04e65213a9d3d5026da58e /Master/texmf-dist/scripts | |
parent | 3b25faeb2fe6b2ff7384da9a80e6c535103db004 (diff) |
glossaries (9mar14)
git-svn-id: svn://tug.org/texlive/trunk@33153 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts')
-rw-r--r-- | Master/texmf-dist/scripts/glossaries/glossaries.perl | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/Master/texmf-dist/scripts/glossaries/glossaries.perl b/Master/texmf-dist/scripts/glossaries/glossaries.perl index d615d83ab08..ba6fdd5c5a8 100644 --- a/Master/texmf-dist/scripts/glossaries/glossaries.perl +++ b/Master/texmf-dist/scripts/glossaries/glossaries.perl @@ -1532,7 +1532,7 @@ sub do_cmd_glsnamefont{ sub do_cmd_newacronym{ local($_) = @_; - local($label,$abbrev,$long,$opt); + local($label,$abbrev,$long,$opt,$shortplural,$longplural); ($opt,$pat) = &get_next_optional_argument; @@ -1543,6 +1543,12 @@ sub do_cmd_newacronym{ $long = &missing_braces unless (s/$next_pair_pr_rx/$long=$2;''/eo); + ($longplural,$opt) = &get_keyval('longplural', $opt); + ($shortplural,$opt) = &get_keyval('shortplural', $opt); + + $longplural = $long.'s' unless ($longplural); + $shortplural = $abbrv.'s' unless ($shortplural); + local($cmd) = "\\newglossaryentry"; local($id); $id = ++$global{'max_id'}; @@ -1558,9 +1564,9 @@ sub do_cmd_newacronym{ $id = ++$global{'max_id'}; $entry .= "first=$OP$id$CP$long ($abbrv)$OP$id$CP,"; $id = ++$global{'max_id'}; - $entry .= "plural=$OP$id$CP${abbrv}s$OP$id$CP,"; + $entry .= "plural=$OP$id$CP$shortplural$OP$id$CP,"; $id = ++$global{'max_id'}; - $entry .= "firstplural=$OP$id$CP${long}s (${abbrv}s)$OP$id$CP"; + $entry .= "firstplural=$OP$id$CP$longplural ($shortplural)$OP$id$CP"; $id = ++$global{'max_id'}; $cmd .= "$OP$id$CP$entry,$opt$OP$id$CP"; |