def _setTextFamily(self, newVal):
gm = ['GramTikzStyle._setTextFamily()']
assert isinstance(newVal, basestring)
lowVal = string.lower(newVal)
goodVals = self.goodTextFamilies
if lowVal not in goodVals:
gm.append("You can only set property 'textFamily' to one of")
gm.append("%s" % goodVals)
gm.append("Got attempt to set to '%s'" % newVal)
raise GramError(gm)
if self.font == 'helvetica':
# if lowVal != 'sffamily':
# print gm[0]
# print " Ignoring request to set textFamily to '%s' -- it does not work with helvetica" % newVal
# print "does this work?" # does not work with ttfamily
self._textFamily = lowVal
else:
self._textFamily = lowVal
评论列表
文章目录