diff options
author | Hans Hagen <pragma@wxs.nl> | 2009-10-22 23:27:00 +0200 |
---|---|---|
committer | Hans Hagen <pragma@wxs.nl> | 2009-10-22 23:27:00 +0200 |
commit | f89395483bb5154004626768dfcee7316254b1fa (patch) | |
tree | c77176cdb82b854eccde07395c0503eae7e1d43c /tex/context/base/font-ctx.lua | |
parent | 8248cba2a913b762265cfb43c1cd93d0c36888ef (diff) | |
download | context-f89395483bb5154004626768dfcee7316254b1fa.tar.gz |
beta 2009.10.22 23:27
Diffstat (limited to 'tex/context/base/font-ctx.lua')
-rw-r--r-- | tex/context/base/font-ctx.lua | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tex/context/base/font-ctx.lua b/tex/context/base/font-ctx.lua index f3b7879fb..8e42b0ab0 100644 --- a/tex/context/base/font-ctx.lua +++ b/tex/context/base/font-ctx.lua @@ -273,7 +273,9 @@ local P, C, Cc = lpeg.P, lpeg.C, lpeg.Cc local space = P(" ") local spaces = space^0 -local value = C((1-space)^1) +local leftparent = (P"(") +local rightparent = (P")") +local value = C((leftparent * (1-rightparent)^0 * rightparent + (1-space))^1) local rest = C(P(1)^0) local scale_none = Cc(0) local scale_at = P("at") * Cc(1) * spaces * value @@ -333,7 +335,8 @@ function define.command_2(global,cs,str,size,classfeatures,fontfeatures,classfal if lookup and lookup ~= "" then specification.lookup = lookup end specification.name = name specification.size = size - specification.sub = sub +--~ specification.sub = sub + specification.sub = (sub and sub ~= "" and sub) or specification.sub specification.mathsize = mathsize specification.textsize = textsize if detail and detail ~= "" then |