jung-kurt / gofpdf

A PDF document generator with high level support for text, drawing and images
http://godoc.org/github.com/jung-kurt/gofpdf
MIT License
4.31k stars 777 forks source link

Text format Bold and Underline within Single MultiCell Cell #284

Open bennsid opened 5 years ago

bennsid commented 5 years ago

Hi Jung-Kurt While using MultiCell. In a single cell, how do i get to Bold some text while other text is left not bold. Furthermore, how do i go about underlining some text while other text isn't underlined.

Your assistance would be highly appreciated

jung-kurt commented 5 years ago

Unfortunately, gofpdf supports only one font attribute in MultiCell(). You could try modifying the code in htmlbasic.go to achieve your objective. Call GetStringWidth() to calculate word spacing for text justification.