summaryrefslogtreecommitdiff
path: root/fpdf.go
diff options
context:
space:
mode:
authorKurt Jung <kurt.w.jung@gmail.com>2015-08-21 12:11:07 -0400
committerKurt Jung <kurt.w.jung@gmail.com>2015-08-21 12:11:07 -0400
commit1800f941981bc8ffc3229ba79304ca76974767de (patch)
treebfadf5bd5e5e8f315b071fe608e8afdd1f802cd1 /fpdf.go
parent27b605858db6d8f5439e9b689f70626801324f02 (diff)
Change GetImageInfo to return pointer
Diffstat (limited to 'fpdf.go')
-rw-r--r--fpdf.go13
1 files changed, 4 insertions, 9 deletions
diff --git a/fpdf.go b/fpdf.go
index 470a81b..d77fd4b 100644
--- a/fpdf.go
+++ b/fpdf.go
@@ -2359,15 +2359,10 @@ func (f *Fpdf) RegisterImage(fileStr, tp string) (info *ImageInfoType) {
}
// GetImageInfo returns information about the registered image specified by
-// imageStr. If the image has not been registered, an empty structure followed
-// by false is returned. The internal error is not modified by this method.
-func (f *Fpdf) GetImageInfo(imageStr string) (info ImageInfoType, ok bool) {
- var infoPtr *ImageInfoType
- infoPtr, ok = f.images[imageStr]
- if ok {
- info = *infoPtr
- }
- return
+// imageStr. If the image has not been registered, nil is returned. The
+// internal error is not modified by this method.
+func (f *Fpdf) GetImageInfo(imageStr string) (info *ImageInfoType) {
+ return f.images[imageStr]
}
// GetXY returns the abscissa and ordinate of the current position.