objc2_app_kit/generated/
NSTableHeaderView.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6#[cfg(feature = "objc2-core-foundation")]
7use objc2_core_foundation::*;
8use objc2_foundation::*;
9
10use crate::*;
11
12extern_class!(
13    /// [Apple's documentation](https://developer.apple.com/documentation/appkit/nstableheaderview?language=objc)
14    #[unsafe(super(NSView, NSResponder, NSObject))]
15    #[derive(Debug, PartialEq, Eq, Hash)]
16    #[cfg(all(feature = "NSResponder", feature = "NSView"))]
17    pub struct NSTableHeaderView;
18);
19
20#[cfg(all(
21    feature = "NSAccessibilityProtocols",
22    feature = "NSResponder",
23    feature = "NSView"
24))]
25extern_conformance!(
26    unsafe impl NSAccessibility for NSTableHeaderView {}
27);
28
29#[cfg(all(
30    feature = "NSAccessibilityProtocols",
31    feature = "NSResponder",
32    feature = "NSView"
33))]
34extern_conformance!(
35    unsafe impl NSAccessibilityElementProtocol for NSTableHeaderView {}
36);
37
38#[cfg(all(feature = "NSAnimation", feature = "NSResponder", feature = "NSView"))]
39extern_conformance!(
40    unsafe impl NSAnimatablePropertyContainer for NSTableHeaderView {}
41);
42
43#[cfg(all(feature = "NSAppearance", feature = "NSResponder", feature = "NSView"))]
44extern_conformance!(
45    unsafe impl NSAppearanceCustomization for NSTableHeaderView {}
46);
47
48#[cfg(all(feature = "NSResponder", feature = "NSView"))]
49extern_conformance!(
50    unsafe impl NSCoding for NSTableHeaderView {}
51);
52
53#[cfg(all(feature = "NSDragging", feature = "NSResponder", feature = "NSView"))]
54extern_conformance!(
55    unsafe impl NSDraggingDestination for NSTableHeaderView {}
56);
57
58#[cfg(all(feature = "NSResponder", feature = "NSView"))]
59extern_conformance!(
60    unsafe impl NSObjectProtocol for NSTableHeaderView {}
61);
62
63#[cfg(all(
64    feature = "NSResponder",
65    feature = "NSUserInterfaceItemIdentification",
66    feature = "NSView"
67))]
68extern_conformance!(
69    unsafe impl NSUserInterfaceItemIdentification for NSTableHeaderView {}
70);
71
72#[cfg(all(feature = "NSResponder", feature = "NSView"))]
73extern_conformance!(
74    unsafe impl NSViewToolTipOwner for NSTableHeaderView {}
75);
76
77#[cfg(all(feature = "NSResponder", feature = "NSView"))]
78impl NSTableHeaderView {
79    extern_methods!(
80        #[cfg(all(feature = "NSControl", feature = "NSTableView"))]
81        #[unsafe(method(tableView))]
82        #[unsafe(method_family = none)]
83        pub unsafe fn tableView(&self) -> Option<Retained<NSTableView>>;
84
85        #[cfg(all(feature = "NSControl", feature = "NSTableView"))]
86        /// This is a [weak property][objc2::topics::weak_property].
87        /// Setter for [`tableView`][Self::tableView].
88        #[unsafe(method(setTableView:))]
89        #[unsafe(method_family = none)]
90        pub unsafe fn setTableView(&self, table_view: Option<&NSTableView>);
91
92        #[unsafe(method(draggedColumn))]
93        #[unsafe(method_family = none)]
94        pub unsafe fn draggedColumn(&self) -> NSInteger;
95
96        #[cfg(feature = "objc2-core-foundation")]
97        #[unsafe(method(draggedDistance))]
98        #[unsafe(method_family = none)]
99        pub unsafe fn draggedDistance(&self) -> CGFloat;
100
101        #[unsafe(method(resizedColumn))]
102        #[unsafe(method_family = none)]
103        pub unsafe fn resizedColumn(&self) -> NSInteger;
104
105        #[unsafe(method(headerRectOfColumn:))]
106        #[unsafe(method_family = none)]
107        pub unsafe fn headerRectOfColumn(&self, column: NSInteger) -> NSRect;
108
109        #[unsafe(method(columnAtPoint:))]
110        #[unsafe(method_family = none)]
111        pub unsafe fn columnAtPoint(&self, point: NSPoint) -> NSInteger;
112    );
113}
114
115/// Methods declared on superclass `NSView`.
116#[cfg(all(feature = "NSResponder", feature = "NSView"))]
117impl NSTableHeaderView {
118    extern_methods!(
119        #[unsafe(method(initWithFrame:))]
120        #[unsafe(method_family = init)]
121        pub unsafe fn initWithFrame(this: Allocated<Self>, frame_rect: NSRect) -> Retained<Self>;
122
123        #[unsafe(method(initWithCoder:))]
124        #[unsafe(method_family = init)]
125        pub unsafe fn initWithCoder(
126            this: Allocated<Self>,
127            coder: &NSCoder,
128        ) -> Option<Retained<Self>>;
129    );
130}
131
132/// Methods declared on superclass `NSResponder`.
133#[cfg(all(feature = "NSResponder", feature = "NSView"))]
134impl NSTableHeaderView {
135    extern_methods!(
136        #[unsafe(method(init))]
137        #[unsafe(method_family = init)]
138        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
139    );
140}
141
142/// Methods declared on superclass `NSObject`.
143#[cfg(all(feature = "NSResponder", feature = "NSView"))]
144impl NSTableHeaderView {
145    extern_methods!(
146        #[unsafe(method(new))]
147        #[unsafe(method_family = new)]
148        pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
149    );
150}