code: func (f *Fpdf) SetErrorf(fmtStr string, args ...interface{}) {
  	if f.err == nil {
  		f.err = fmt.Errorf(fmtStr, args...)
  	}
  }
docs: // SetErrorf sets the internal Fpdf error with formatted text to halt PDF
  // generation; this may facilitate error handling by application. If an error
  // condition is already set, this call is ignored.
  //
  // See the documentation for printing in the standard fmt package for details
  // about fmtStr and args.