feat(拆分文件): 下沉PDF计算并精简根包
build.yaml / build (push) Successful in 50s

This commit is contained in:
xiaoqidun committed 2026-10-18 18:35:13 +08:00
1 parent a2de650b52
commit f952c5d91d
15 files changed
+1104 -1096

No files matched your search

+2 -1
View File
@@ -21,6 +21,7 @@ import (
"strconv"
"unicode/utf8"
codecpdf "github.com/xiaoqidun/ofdgo/internal/codec/pdf"
"github.com/xiaoqidun/pdfgo"
)
@@ -68,7 +69,7 @@ func (p *pdfImporter) text(mark pdfgo.TextMark) error {
return err
}
paintMode := mark.Mode % 4
if (paintMode == 0 || paintMode == 2) && mark.Style.FillOverprint && pdfOverprintNeedsSeparation(mark.Style.Fill) || (paintMode == 1 || paintMode == 2) && mark.Style.StrokeOverprint && pdfOverprintNeedsSeparation(mark.Style.Stroke) {
if (paintMode == 0 || paintMode == 2) && mark.Style.FillOverprint && codecpdf.OverprintNeedsSeparation(mark.Style.Fill) || (paintMode == 1 || paintMode == 2) && mark.Style.StrokeOverprint && codecpdf.OverprintNeedsSeparation(mark.Style.Stroke) {
return &pdfgo.UnsupportedError{Feature: "text color separation overprint"}
}
if p.warning != nil && ((paintMode == 0 || paintMode == 2) && p.gradientError(mark.Style.Fill) != nil || (paintMode == 1 || paintMode == 2) && p.gradientError(mark.Style.Stroke) != nil) {