MCPcopy Create free account
hub / github.com/Paper2Poster/Paper2Poster / to_html

Method to_html

utils/src/presentation.py:554–564  ·  view source on GitHub ↗
(self, style_args: StyleArg)

Source from the content-addressed store, hash-verified

552 self.data[2] = caption
553
554 def to_html(self, style_args: StyleArg) -> str:
555 if not style_args.show_image:
556 return ""
557 if not self.caption:
558 raise ValueError(
559 f"caption not found for picture {self.shape_idx} of slide {self.slide_idx}"
560 )
561 return (
562 self.indent
563 + f"<img {self.get_inline_style(style_args)} alt='{self.caption}'/>"
564 )
565
566
567class FreeformShape(ShapeElement):

Callers

nothing calls this directly

Calls 1

get_inline_styleMethod · 0.45

Tested by

no test coverage detected