diff options
author | Marius <mariausol@gmail.com> | 2013-05-20 03:20:28 +0300 |
---|---|---|
committer | Marius <mariausol@gmail.com> | 2013-05-20 03:20:28 +0300 |
commit | 5fc5cfb5014ddcc2942e13a559f4082fb66aa6e7 (patch) | |
tree | 53f81e99fac8c80ddd2fb70e233a7e5d5735722f /tex/context/base/s-fonts-system.lua | |
parent | 13ec4b540e0d46c97fd7b089e0b7413da81e0a9f (diff) | |
download | context-5fc5cfb5014ddcc2942e13a559f4082fb66aa6e7.tar.gz |
beta 2013.05.20 02:00
Diffstat (limited to 'tex/context/base/s-fonts-system.lua')
-rw-r--r-- | tex/context/base/s-fonts-system.lua | 136 |
1 files changed, 68 insertions, 68 deletions
diff --git a/tex/context/base/s-fonts-system.lua b/tex/context/base/s-fonts-system.lua index a8b6ddaa9..0c0ad4d86 100644 --- a/tex/context/base/s-fonts-system.lua +++ b/tex/context/base/s-fonts-system.lua @@ -1,68 +1,68 @@ -if not modules then modules = { } end modules ['s-fonts-system'] = {
- version = 1.001,
- comment = "companion to s-fonts-system.mkiv",
- author = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
- copyright = "PRAGMA ADE / ConTeXt Development Team",
- license = "see context related readme files"
-}
-
--- ["zapfinoforteltpro"]={
--- ["designsize"]=0,
--- ["familyname"]="zapfinoforteltpro",
--- ["filename"]="zapfinoforteltpro.otf",
--- ["fontname"]="zapfinoforteltpro",
--- ["fontweight"]="regular",
--- ["format"]="otf",
--- ["fullname"]="zapfinoforteltpro",
--- ["maxsize"]=0,
--- ["minsize"]=0,
--- ["modification"]=1105543074,
--- ["modifiers"]="regular",
--- ["rawname"]="ZapfinoForteLTPro",
--- ["style"]="normal",
--- ["subfamily"]="regular",
--- ["variant"]="normal",
--- ["weight"]="normal",
--- ["width"]="normal",
--- }
-
-moduledata.fonts = moduledata.fonts or { }
-moduledata.fonts.system = moduledata.fonts.system or { }
-
-local lower = string.lower
-
-local context = context
-local NC, NR, HL = context.NC, context.NR, context.HL
-local bold = context.bold
-
-function moduledata.fonts.system.showinstalled(specification)
- specification = interfaces.checkedspecification(specification)
- local pattern = lower(specification.pattern or "")
- local list = fonts.names.list(pattern,false,true)
- if list then
- local files = { }
- for k, v in next, list do
- files[file.basename(string.lower(v.filename))] = v
- end
- context.starttabulate { "|Tl|Tl|Tl|Tl|Tl|Tl|" }
- HL()
- NC() bold("filename")
- NC() bold("fontname")
- NC() bold("subfamily")
- NC() bold("variant")
- NC() bold("weight")
- NC() bold("width")
- NC() NR()
- HL()
- for filename, data in table.sortedpairs(files) do
- NC() context(filename)
- NC() context(data.fontname)
- NC() context(data.subfamily)
- NC() context(data.variant)
- NC() context(data.weight)
- NC() context(data.width)
- NC() NR()
- end
- context.stoptabulate()
- end
-end
+if not modules then modules = { } end modules ['s-fonts-system'] = { + version = 1.001, + comment = "companion to s-fonts-system.mkiv", + author = "Hans Hagen, PRAGMA-ADE, Hasselt NL", + copyright = "PRAGMA ADE / ConTeXt Development Team", + license = "see context related readme files" +} + +-- ["zapfinoforteltpro"]={ +-- ["designsize"]=0, +-- ["familyname"]="zapfinoforteltpro", +-- ["filename"]="zapfinoforteltpro.otf", +-- ["fontname"]="zapfinoforteltpro", +-- ["fontweight"]="regular", +-- ["format"]="otf", +-- ["fullname"]="zapfinoforteltpro", +-- ["maxsize"]=0, +-- ["minsize"]=0, +-- ["modification"]=1105543074, +-- ["modifiers"]="regular", +-- ["rawname"]="ZapfinoForteLTPro", +-- ["style"]="normal", +-- ["subfamily"]="regular", +-- ["variant"]="normal", +-- ["weight"]="normal", +-- ["width"]="normal", +-- } + +moduledata.fonts = moduledata.fonts or { } +moduledata.fonts.system = moduledata.fonts.system or { } + +local lower = string.lower + +local context = context +local NC, NR, HL = context.NC, context.NR, context.HL +local bold = context.bold + +function moduledata.fonts.system.showinstalled(specification) + specification = interfaces.checkedspecification(specification) + local pattern = lower(specification.pattern or "") + local list = fonts.names.list(pattern,false,true) + if list then + local files = { } + for k, v in next, list do + files[file.basename(string.lower(v.filename))] = v + end + context.starttabulate { "|Tl|Tl|Tl|Tl|Tl|Tl|" } + HL() + NC() bold("filename") + NC() bold("fontname") + NC() bold("subfamily") + NC() bold("variant") + NC() bold("weight") + NC() bold("width") + NC() NR() + HL() + for filename, data in table.sortedpairs(files) do + NC() context(filename) + NC() context(data.fontname) + NC() context(data.subfamily) + NC() context(data.variant) + NC() context(data.weight) + NC() context(data.width) + NC() NR() + end + context.stoptabulate() + end +end |