objc2_app_kit/generated/
NSPDFInfo.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 #[unsafe(super(NSObject))]
13 #[derive(Debug, PartialEq, Eq, Hash)]
14 pub struct NSPDFInfo;
15);
16
17extern_conformance!(
18 unsafe impl NSCoding for NSPDFInfo {}
19);
20
21extern_conformance!(
22 unsafe impl NSCopying for NSPDFInfo {}
23);
24
25unsafe impl CopyingHelper for NSPDFInfo {
26 type Result = Self;
27}
28
29extern_conformance!(
30 unsafe impl NSObjectProtocol for NSPDFInfo {}
31);
32
33impl NSPDFInfo {
34 extern_methods!(
35 #[unsafe(method(URL))]
36 #[unsafe(method_family = none)]
37 pub fn URL(&self) -> Option<Retained<NSURL>>;
38
39 #[unsafe(method(setURL:))]
43 #[unsafe(method_family = none)]
44 pub fn setURL(&self, url: Option<&NSURL>);
45
46 #[unsafe(method(isFileExtensionHidden))]
47 #[unsafe(method_family = none)]
48 pub fn isFileExtensionHidden(&self) -> bool;
49
50 #[unsafe(method(setFileExtensionHidden:))]
52 #[unsafe(method_family = none)]
53 pub fn setFileExtensionHidden(&self, file_extension_hidden: bool);
54
55 #[unsafe(method(tagNames))]
56 #[unsafe(method_family = none)]
57 pub fn tagNames(&self) -> Retained<NSArray<NSString>>;
58
59 #[unsafe(method(setTagNames:))]
63 #[unsafe(method_family = none)]
64 pub fn setTagNames(&self, tag_names: &NSArray<NSString>);
65
66 #[cfg(feature = "NSPrintInfo")]
67 #[unsafe(method(orientation))]
68 #[unsafe(method_family = none)]
69 pub fn orientation(&self) -> NSPaperOrientation;
70
71 #[cfg(feature = "NSPrintInfo")]
72 #[unsafe(method(setOrientation:))]
74 #[unsafe(method_family = none)]
75 pub fn setOrientation(&self, orientation: NSPaperOrientation);
76
77 #[unsafe(method(paperSize))]
78 #[unsafe(method_family = none)]
79 pub fn paperSize(&self) -> NSSize;
80
81 #[unsafe(method(setPaperSize:))]
83 #[unsafe(method_family = none)]
84 pub fn setPaperSize(&self, paper_size: NSSize);
85
86 #[cfg(feature = "NSPrintInfo")]
87 #[unsafe(method(attributes))]
91 #[unsafe(method_family = none)]
92 pub unsafe fn attributes(
93 &self,
94 ) -> Retained<NSMutableDictionary<NSPrintInfoAttributeKey, AnyObject>>;
95 );
96}
97
98impl NSPDFInfo {
100 extern_methods!(
101 #[unsafe(method(init))]
102 #[unsafe(method_family = init)]
103 pub fn init(this: Allocated<Self>) -> Retained<Self>;
104
105 #[unsafe(method(new))]
106 #[unsafe(method_family = new)]
107 pub fn new() -> Retained<Self>;
108 );
109}
110
111impl DefaultRetained for NSPDFInfo {
112 #[inline]
113 fn default_retained() -> Retained<Self> {
114 Self::new()
115 }
116}