diff --git a/pdf2d/doc.go b/pdf2d/doc.go index 87a95ee..f019d31 100644 --- a/pdf2d/doc.go +++ b/pdf2d/doc.go @@ -1,5 +1,5 @@ // Copyright 2015 The draw2d Authors. All rights reserved. // created: 26/06/2015 by Stani Michiels -// Package pdf2d provides a Graphic Context that can draw vector form on pdf file. -package pdf2d +// Package draw2dpdf provides a Graphic Context that can draw vector form on pdf file. +package draw2dpdf diff --git a/pdf2d/fileutil.go b/pdf2d/fileutil.go index 4e4fcfd..c3c8e66 100644 --- a/pdf2d/fileutil.go +++ b/pdf2d/fileutil.go @@ -1,4 +1,4 @@ -package pdf2d +package draw2dpdf import "github.com/jung-kurt/gofpdf" diff --git a/pdf2d/graphiccontext.go b/pdf2d/graphiccontext.go index 1b4c7b5..f2d196c 100644 --- a/pdf2d/graphiccontext.go +++ b/pdf2d/graphiccontext.go @@ -2,7 +2,7 @@ // created: 26/06/2015 by Stani Michiels // TODO: fonts, dpi -package pdf2d +package draw2dpdf import ( "bytes" diff --git a/pdf2d/graphiccontext_test.go b/pdf2d/graphiccontext_test.go index 3aa1539..949f18f 100644 --- a/pdf2d/graphiccontext_test.go +++ b/pdf2d/graphiccontext_test.go @@ -1,4 +1,4 @@ -package pdf2d +package draw2dpdf import ( "fmt" @@ -28,7 +28,7 @@ func ExampleGraphicContext() { gc.FillStroke() fmt.Println(gc.LastPoint()) - // pdf2d.SaveToPdfFile("example.pdf", pdf) + // draw2dpdf.SaveToPdfFile("example.pdf", pdf) // Output: // 10 10 diff --git a/pdf2d/path_converter.go b/pdf2d/path_converter.go index 662d72b..c58d53e 100644 --- a/pdf2d/path_converter.go +++ b/pdf2d/path_converter.go @@ -1,7 +1,7 @@ // Copyright 2015 The draw2d Authors. All rights reserved. // created: 26/06/2015 by Stani Michiels -package pdf2d +package draw2dpdf import ( "math" diff --git a/pdf2d/samples_test.go b/pdf2d/samples_test.go index 4a6a6f3..5ceeb3c 100644 --- a/pdf2d/samples_test.go +++ b/pdf2d/samples_test.go @@ -1,6 +1,6 @@ // See also test_test.go -package pdf2d_test +package draw2dpdf_test import ( "testing" diff --git a/pdf2d/test_test.go b/pdf2d/test_test.go index d8a9364..923f021 100644 --- a/pdf2d/test_test.go +++ b/pdf2d/test_test.go @@ -1,20 +1,20 @@ -// Package pdf2d_test gives test coverage with the command: +// Package draw2dpdf_test gives test coverage with the command: // go test -cover ./... | grep -v "no test" // (It should be run from its parent draw2d directory.) -package pdf2d_test +package draw2dpdf_test import ( "os" "testing" "github.com/llgcode/draw2d" - "github.com/llgcode/draw2d/pdf2d" + "github.com/llgcode/draw2d/draw2dpdf" ) func test(t *testing.T, sample draw2d.Sample) { // Initialize the graphic context on an pdf document - dest := pdf2d.NewPdf("L", "mm", "A4") - gc := pdf2d.NewGraphicContext(dest) + dest := draw2dpdf.NewPdf("L", "mm", "A4") + gc := draw2dpdf.NewGraphicContext(dest) // Draw sample fn, err := sample(gc, "pdf") if err != nil { @@ -26,7 +26,7 @@ func test(t *testing.T, sample draw2d.Sample) { t.Skipf("Saving %q skipped, as it exists already. (Git would consider it modified.)", fn) return } - err = pdf2d.SaveToPdfFile(fn, dest) + err = draw2dpdf.SaveToPdfFile(fn, dest) if err != nil { t.Errorf("Saving %q failed: %v", fn, err) } diff --git a/pdf2d/vectorizer.go b/pdf2d/vectorizer.go index dda2312..556c2e0 100644 --- a/pdf2d/vectorizer.go +++ b/pdf2d/vectorizer.go @@ -1,7 +1,7 @@ // Copyright 2015 The draw2d Authors. All rights reserved. // created: 26/06/2015 by Stani Michiels -package pdf2d +package draw2dpdf // Vectorizer defines the minimal interface for gofpdf.Fpdf // to be passed to a PathConvertor.