From 7c5006543b654248bb1fb640703faf0a53f59f71 Mon Sep 17 00:00:00 2001 From: Brigham Thompson Date: Sun, 11 Aug 2019 20:52:54 -0700 Subject: adds RoundedRect per Issue #272 --- fpdf_test.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'fpdf_test.go') diff --git a/fpdf_test.go b/fpdf_test.go index 63c28c5..08814e0 100644 --- a/fpdf_test.go +++ b/fpdf_test.go @@ -2639,3 +2639,16 @@ func ExampleUTF8CutFont() { // Output: // Successfully generated pdf/Fpdf_UTF8CutFont.pdf } + +func ExampleFpdf_RoundedRect() { + pdf := gofpdf.New("P", "mm", "A4", "") + pdf.AddPage() + pdf.SetFillColor(160, 160, 160) + pdf.SetLineWidth(0.5) + pdf.RoundedRect(70, 30, 68, 46, 20, "1234", "FD") + fileStr := example.Filename("Fpdf_RoundedRect") + err := pdf.OutputFileAndClose(fileStr) + example.Summary(err, fileStr) + // Output: + // Successfully generated pdf/Fpdf_RoundedRect.pdf +} -- cgit v1.2.1-24-ge1ad