pdfKit

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 10, 2025 License: MIT Imports: 2 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compress

func Compress(file string) string

Compress 压缩pdf

  • @param file pdf文件

func Jpg2Pdf

func Jpg2Pdf(filePath []string, outPath string) error

Jpg2Pdf 将jpg转换为pdf

  • @param file {[]string} jpg文件
  • @param path {string} 保存路径

func Merge

func Merge(mergeFilePath []string, dividerPage bool, outFilePath string) error

Merge 合并两个pdf文件,file1是文章的开始

  • @param mergeFilePath 要合并pdf文件路径
  • @param dividerPage 分隔页
  • @param outFilePath 输出文件

func Office2Pdf

func Office2Pdf(file, path string) bool

Office2Pdf 将office转换为pdf

  • @param file office文件
  • @param path 保存路径

func Pdf2Jpg

func Pdf2Jpg(file, path string) bool

Pdf2Jpg 将pdf转换为jpg

  • @param file pdf文件
  • @param path 保存路径

func Pdf2Office

func Pdf2Office(file, officeType, path string) bool

Pdf2Office 将pdf转换为office

  • @param file pdf文件
  • @param officeType office类型 word, excel, ppt
  • @param path 保存路径

func PdfEncrypt

func PdfEncrypt(inFile, outFile, userPwd, ownerPwd string) (bool, error)

PdfEncrypt pdf加密

  • @param file pdf文件
  • @param outFile 输出文件
  • @param userPwd 用户密码(仅拥有查看的权限),若为空,则默认为userPwd
  • @param ownerPwd 所有者密码

func Split

func Split(file string) string

Split 拆分pdf,将pdf中的页面拆分成多个pdf

  • @param file pdf文件

func Watermark

func Watermark(file, imgPath string) bool

Watermark pdf添加水印

  • @param file pdf文件
  • @param imgPath 水印

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL