MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / _put_char_real

Method _put_char_real

lib/matplotlib/dviread.py:408–426  ·  view source on GitHub ↗
(self, char)

Source from the content-addressed store, hash-verified

406 self._put_char_real(char)
407
408 def _put_char_real(self, char):
409 font = self.fonts[self.f]
410 if isinstance(font, cbook._ExceptionInfo):
411 self._missing_font = font
412 elif font._vf is None:
413 self.text.append(Text(self.h, self.v, font, char,
414 font._width_of(char)))
415 else:
416 scale = font._scale
417 for x, y, f, g, w in font._vf[char].text:
418 newf = DviFont(scale=_mul1220(scale, f._scale),
419 metrics=f._metrics, texname=f.texname, vf=f._vf)
420 self.text.append(Text(self.h + _mul1220(x, scale),
421 self.v + _mul1220(y, scale),
422 newf, g, newf._width_of(g)))
423 self.boxes.extend([Box(self.h + _mul1220(x, scale),
424 self.v + _mul1220(y, scale),
425 _mul1220(a, scale), _mul1220(b, scale))
426 for x, y, a, b in font._vf[char].boxes])
427
428 @_dispatch(137, state=_dvistate.inpage, args=('s4', 's4'))
429 def _put_rule(self, a, b):

Callers 3

_set_char_immediateMethod · 0.95
_set_charMethod · 0.95
_put_charMethod · 0.95

Calls 5

_width_ofMethod · 0.95
DviFontClass · 0.85
_mul1220Function · 0.85
BoxClass · 0.85
TextClass · 0.70

Tested by

no test coverage detected