CcSimple / electron-hiprint

MIT License
67 stars 35 forks source link

建议整合pdf-to-printer #35

Closed wslsq closed 3 weeks ago

wslsq commented 3 weeks ago

pdf-to-printer已经停止维护,且引入了旧版的SumatraPDF.exe,虽然包提供更换文件路径的选项,但是目前的引入方式很不方便替换成最新版。

核心文件仅exec-file-async.ts、electron-util.ts、print.ts,改js引入并不麻烦,最重要的是期望可以自行更换新版SumatraPDF.exe。

另外win32-pdf-printer在应用里只提供了一个功能,却引入了一个大包,包括SumatraPDF.exe、paper-size-info.exe、pdf2printer.exe等,也可以在后面优化。

Xavier9896 commented 3 weeks ago

引入win32那个包主要是因为自己不会写c,只能找现成的包,本来也打算基于它去拓展,甚至给它拓展,但是能力有限,其实它再大对于 electron 来说都是九牛一毛,而且 win32 那个包其实也支持打印 pdf 文件发自我的 iPhone在 2024年9月5日,01:59,wslsq @.***> 写道: pdf-to-printer已经停止维护,且引入了旧版的SumatraPDF.exe,虽然包提供更换文件路径的选项,但是目前的引入方式很不方便替换成最新版。 核心文件仅exec-file-async.ts、electron-util.ts、print.ts,改js引入并不麻烦,最重要的是期望可以自行更换新版SumatraPDF.exe。 另外win32-pdf-printer在应用里只提供了一个功能,却引入了一个大包,包括SumatraPDF.exe、paper-size-info.exe、pdf2printer.exe等,也可以在后面优化。

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***>

wslsq commented 3 weeks ago

引入win32那个包主要是因为自己不会写c,只能找现成的包,本来也打算基于它去拓展,甚至给它拓展,但是能力有限,其实它再大对于 electron 来说都是九牛一毛,而且 win32 那个包其实也支持打印 pdf 文件发自我的 iPhone在 2024年9月5日,01:59,wslsq @.> 写道: pdf-to-printer已经停止维护,且引入了旧版的SumatraPDF.exe,虽然包提供更换文件路径的选项,但是目前的引入方式很不方便替换成最新版。 核心文件仅exec-file-async.ts、electron-util.ts、print.ts,改js引入并不麻烦,最重要的是期望可以自行更换新版SumatraPDF.exe。 另外win32-pdf-printer在应用里只提供了一个功能,却引入了一个大包,包括SumatraPDF.exe、paper-size-info.exe、pdf2printer.exe等,也可以在后面优化。 —Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.>

win32-pdf-printer确实功能不少。 我认真看了一下 win32-pdf-printer 源码,发现他把pdf-to-printer包含进去了,也就是 pdf-to-printer完全多余了。等我有空提pr。