fix go names according to linter
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/jung-kurt/gofpdf"
|
||||
)
|
||||
|
||||
func main() {
|
||||
pdf := gofpdf.New("P", "mm", "A4", "")
|
||||
|
||||
pdf.SetFontLocation("fonts")
|
||||
errs := gofpdf.MakeFont("/usr/share/fonts/dejavu/DejaVuSans.ttf", "/home/joerg/go/src/github.com/jung-kurt/gofpdf/font/cp1252.map", "fonts", nil, true)
|
||||
if errs != nil {
|
||||
fmt.Println(errs)
|
||||
}
|
||||
errs2 := gofpdf.MakeFont("/usr/share/fonts/dejavu/DejaVuSans-Bold.ttf", "/home/joerg/go/src/github.com/jung-kurt/gofpdf/font/cp1252.map", "fonts", nil, true)
|
||||
if errs2 != nil {
|
||||
fmt.Println(errs)
|
||||
}
|
||||
pdf.AddFont("DejaVuSans", "", "DejaVuSans.json")
|
||||
pdf.AddFont("DejaVuSans-Bold", "", "DejaVuSans-Bold.json")
|
||||
}
|
||||
Reference in New Issue
Block a user