diff options
author | Karl Berry <karl@freefriends.org> | 2015-11-20 23:15:41 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-11-20 23:15:41 +0000 |
commit | ac00a0f196d83884f1543e50de7864b4078a3ba1 (patch) | |
tree | 0514fd472754fd27e653804438a2636a90c93423 /Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua | |
parent | fc76887bf99e40ed1678e3250be897896776579b (diff) |
hyph-utf8 (20nov15)
git-svn-id: svn://tug.org/texlive/trunk@38905 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua')
-rw-r--r-- | Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua | 72 |
1 files changed, 63 insertions, 9 deletions
diff --git a/Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua b/Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua index 4fd01932953..17ccdf2dc33 100644 --- a/Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua +++ b/Master/texmf-dist/source/generic/hyph-utf8/languages/es/eshyph-make.lua @@ -1,7 +1,39 @@ -- (encoding:utf-8) --- (c) Javier Bezos 2009 --- License: LPPL. v. 4.5 +-- GUIONIZADO DE PALABRAS +-- ~~~~~~~~~~~~~~~~~~~~~ +-- v 4.7 +-- +-- License: MIT/X11 +-- +-- Copyright (c) 1993, 1997 Javier Bezos +-- Copyright (c) 2001-2015 Javier Bezos and CervanTeX +-- +-- Permission is hereby granted, free of charge, to any person obtaining a copy +-- of this software and associated documentation files (the "Software"), to deal +-- in the Software without restriction, including without limitation the rights +-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +-- copies of the Software, and to permit persons to whom the Software is +-- furnished to do so, subject to the following conditions: +-- +-- The above copyright notice and this permission notice shall be included in +-- all copies or substantial portions of the Software. +-- +-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +-- SOFTWARE. +-- +-- For further info, bug reports and comments: +-- +-- http://www.tex-tipografia.com/spanish_hyphen.html + +---------- + +-- ethymologic, trailing no, bad words, prefixes, consonant + h, tl patfile = io.open('eshyph.tex', 'w') patfile:write('\\patterns{\n') @@ -11,24 +43,25 @@ patfile:write('\\patterns{\n') digraphs = 'ch ll' liquids = 'bl cl fl gl kl pl vl br cr dr fr gr kr pr rr tr vr' -avoid = 'tl' +avoid = 'tl ts tx tz' silent = 'h' +chrl = 'chr chl' letters = 'bcdfghjklmnpqrstvwxyz' for n in letters:gmatch('.') do if silent:find(n) then - patfile:write('2' .. n .. '.') + patfile:write(' 4' .. n .. '.') else - patfile:write('1' .. n .. ' 2' .. n .. '.') + patfile:write('1' .. n .. ' 4' .. n .. '. .' .. n .. '2') end for m in letters:gmatch('.') do pat = n .. m if digraphs:find(pat) then - patfile:write(' ' .. n .. '4'.. m .. ' 2' .. pat .. '.') + patfile:write(' ') elseif liquids:find(pat) then - patfile:write(' ' .. n .. '2'.. m .. ' 2' .. pat .. '.') + patfile:write(' ') elseif avoid:find(pat) then - patfile:write(' 2' .. n .. '2'.. m) + patfile:write(' ') elseif silent:find(m) then patfile:write(' 2' .. n .. '1' .. m) else @@ -38,7 +71,28 @@ for n in letters:gmatch('.') do patfile:write('\n') end -patfile:write('1ñ 2ñ.\n') +patfile:write('1ñ 4ñ.\n') + +for n in digraphs:gmatch('%S+') do + patfile:write(n:sub(1,1) .. '4' .. n:sub(2,2) .. ' 4' .. n .. '.') + for m in letters:gmatch('.') do + pat = n .. m + if chrl:find(pat) then + patfile:write(' ' .. n .. '2' .. m) + else + patfile:write(' 2' .. pat) + end + end + patfile:write('\n') +end + +for n in liquids:gmatch('%S+') do + patfile:write(n:sub(1,1) .. '2' .. n:sub(2,2) .. ' 4' .. n .. '.') + for m in letters:gmatch('.') do + patfile:write(' 2' .. n .. '2' .. m) + end + patfile:write('\n') +end letters = 'bcdlmnrstxy' etim = 'pt ct cn ps mn gn ft pn cz tz ts' |