macOS: declare PDF by UTI so Open With recommends PrintCraft (#176)
CFBundleDocumentTypes listed PDF by extension and MIME type only. LaunchServices keeps those as plain tags (.pdf, application/pdf) instead of resolving them to com.adobe.pdf, so Finder greys the app out under Open With > Recommended Applications and a forced open fails with 'cannot open files in the PDF document format'. Add LSItemContentTypes com.adobe.pdf (keeping extension and MIME for backward compatibility). Role stays Editor, rank stays Alternate, so the app is offered without hijacking the default. Verified with lsregister -dump: bindings change from '.pdf, application/pdf' to 'com.adobe.pdf' with claimed UTIs com.adobe.pdf; plutil -lint and xmllint --noout pass. Follow-up to #73. Co-authored-by: Brandon Thomas <echelon@gmail.com>
This commit is contained in:
parent
6c89837541
commit
bfa17ff3b9
|
|
@ -47,7 +47,8 @@
|
|||
|
||||
<!-- Documents PdfCraft opens (#73): it is offered under Open With and can be made the default
|
||||
for PDFs, without taking over from the system's viewer on install ("Alternate"). Declared by
|
||||
extension and MIME type; LaunchServices maps them to the system's PDF type. Finder hands the
|
||||
UTI (LSItemContentTypes, what modern macOS filters Open With > Recommended Applications on),
|
||||
plus extension and MIME type for backward compatibility. Finder hands the
|
||||
file over as an Apple event, which apps/pdfcraft/src/apple_events.rs receives. -->
|
||||
<key>CFBundleDocumentTypes</key>
|
||||
<array>
|
||||
|
|
@ -58,6 +59,8 @@
|
|||
<string>Editor</string>
|
||||
<key>LSHandlerRank</key>
|
||||
<string>Alternate</string>
|
||||
<key>LSItemContentTypes</key>
|
||||
<array><string>com.adobe.pdf</string></array>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array><string>pdf</string></array>
|
||||
<key>CFBundleTypeMIMETypes</key>
|
||||
|
|
|
|||
Loading…
Reference in New Issue