Home | History | Annotate | Download | only in subset

Lines Matching refs:subset

12 from fontTools.subset.cff import *
32 subset fonts as webfonts. Individual optimizations can be enabled or
45 Specify one or more glyph identifiers to include in the subset. Must be
59 Specify comma/whitespace-separated PS glyph names to add to the subset.
67 Specify characters to include in the subset, as UTF-8 string.
70 the subset.
113 will be saved in as font-file.subset.
125 These options control how additional glyphs are added to the subset.
129 Add the '.notdef' glyph to the subset (ie, keep it). [default]
144 Add glyphs 0, 1, 2, and 3 to the subset, as recommended for
148 Do not add glyphs 0, 1, 2, and 3 to the subset, unless specified in
152 features. Instead, OpenType layout features will be subset to only
158 specified subset glyph set. By default, 'calt', 'ccmp', 'clig', 'curs',
212 The tool will attempt to subset the remaining tables.
222 --no-subset-tables+=<table>[,<table>...]
228 By default, tables that the tool does not know how to subset and are not
232 --no-subset-tables+=FFTM
235 Do not drop tables that the tool does not know how to subset.
237 Tables that the tool does not know how to subset and are not specified
238 in --no-subset-tables will be dropped from the font. [default]
337 Produce a subset containing the characters ' !"#$%' without performing
347 log = logging.getLogger("fontTools.subset")
360 timer = Timer(logger=logging.getLogger("fontTools.subset.timer"))
398 def subset(self, glyphs):
425 def subset(self, glyphs, remap=False):
510 indices = self.Coverage.subset(s.glyphs)
519 all(c.subset(s.glyphs)
527 return len(self.Coverage.subset(s.glyphs))
529 indices = self.Coverage.subset(s.glyphs)
548 indices = self.Coverage.subset(s.glyphs)
562 class1_map = [c for c in self.ClassDef1.subset(s.glyphs, remap=True) if c < self.Class1Count]
563 class2_map = [c for c in self.ClassDef2.subset(s.glyphs, remap=True) if c < self.Class2Count]
571 self.Coverage.subset(s.glyphs))
586 indices = self.Coverage.subset(s.glyphs)
612 mark_indices = self.MarkCoverage.subset(s.glyphs)
615 base_indices = self.BaseCoverage.subset(s.glyphs)
646 mark_indices = self.MarkCoverage.subset(s.glyphs)
649 ligature_indices = self.LigatureCoverage.subset(s.glyphs)
682 mark1_indices = self.Mark1Coverage.subset(s.glyphs)
685 mark2_indices = self.Mark2Coverage.subset(s.glyphs)
996 indices = self.Coverage.subset(s.glyphs)
1016 if not self.Coverage.subset(s.glyphs):
1019 klass_maps = [x.subset(s.glyphs, remap=True) if x else None for x in ContextData]
1054 # now we subset classes to c.glyphs only. Or better, rewrite
1059 return all(x.subset(s.glyphs) for x in c.RuleData(self))
1616 indices = table.LigCaretList.Coverage.subset(glyphs)
1628 indices = table.AttachList.Coverage.subset(glyphs)
1636 coverage.subset(glyphs)
1663 # Subset.
1974 indices = self.Coverage.subset(s.glyphs)
1981 indices = self.TopAccentCoverage.subset(s.glyphs)
1988 indices = self.MathKernCoverage.subset(s.glyphs)
2002 self.ExtendedShapeCoverage.subset(s.glyphs)
2008 indices = self.VertGlyphCoverage.subset(s.glyphs)
2013 indices = self.HorizGlyphCoverage.subset(s.glyphs)
2091 # Don't drop empty 'glyf' tables, otherwise 'loca' doesn't get subset.
2280 self.passthrough_tables = False # keep/drop tables we can't subset
2485 log.info("Added gid0 to subset")
2488 log.info("Added .notdef to subset")
2493 log.info("Added first four glyphs to subset")
2576 with timer("subset '%s'" % tag):
2587 log.info("%s NOT subset; don't know how to subset", tag)
2589 log.warning("%s NOT subset; don't know how to subset; dropped", tag)
2593 with timer("subset GlyphOrder"):
2630 def subset(self, font):
2813 outfile = basename + ".subset" + ext
2830 subsetter.subset(font)
2837 log.info("Subset font:% 7d bytes: %s" % (os.path.getsize(outfile), outfile))