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))]
25unsafe impl NSAccessibility for NSTableHeaderView {}
26
27#[cfg(all(
28    feature = "NSAccessibilityProtocols",
29    feature = "NSResponder",
30    feature = "NSView"
31))]
32unsafe impl NSAccessibilityElementProtocol for NSTableHeaderView {}
33
34#[cfg(all(feature = "NSAnimation", feature = "NSResponder", feature = "NSView"))]
35unsafe impl NSAnimatablePropertyContainer for NSTableHeaderView {}
36
37#[cfg(all(feature = "NSAppearance", feature = "NSResponder", feature = "NSView"))]
38unsafe impl NSAppearanceCustomization for NSTableHeaderView {}
39
40#[cfg(all(feature = "NSResponder", feature = "NSView"))]
41unsafe impl NSCoding for NSTableHeaderView {}
42
43#[cfg(all(feature = "NSDragging", feature = "NSResponder", feature = "NSView"))]
44unsafe impl NSDraggingDestination for NSTableHeaderView {}
45
46#[cfg(all(feature = "NSResponder", feature = "NSView"))]
47unsafe impl NSObjectProtocol for NSTableHeaderView {}
48
49#[cfg(all(
50    feature = "NSResponder",
51    feature = "NSUserInterfaceItemIdentification",
52    feature = "NSView"
53))]
54unsafe impl NSUserInterfaceItemIdentification for NSTableHeaderView {}
55
56#[cfg(all(feature = "NSResponder", feature = "NSView"))]
57unsafe impl NSViewToolTipOwner for NSTableHeaderView {}
58
59#[cfg(all(feature = "NSResponder", feature = "NSView"))]
60impl NSTableHeaderView {
61    extern_methods!(
62        #[cfg(all(feature = "NSControl", feature = "NSTableView"))]
63        #[unsafe(method(tableView))]
64        #[unsafe(method_family = none)]
65        pub unsafe fn tableView(&self) -> Option<Retained<NSTableView>>;
66
67        #[cfg(all(feature = "NSControl", feature = "NSTableView"))]
68        /// This is a [weak property][objc2::topics::weak_property].
69        /// Setter for [`tableView`][Self::tableView].
70        #[unsafe(method(setTableView:))]
71        #[unsafe(method_family = none)]
72        pub unsafe fn setTableView(&self, table_view: Option<&NSTableView>);
73
74        #[unsafe(method(draggedColumn))]
75        #[unsafe(method_family = none)]
76        pub unsafe fn draggedColumn(&self) -> NSInteger;
77
78        #[cfg(feature = "objc2-core-foundation")]
79        #[unsafe(method(draggedDistance))]
80        #[unsafe(method_family = none)]
81        pub unsafe fn draggedDistance(&self) -> CGFloat;
82
83        #[unsafe(method(resizedColumn))]
84        #[unsafe(method_family = none)]
85        pub unsafe fn resizedColumn(&self) -> NSInteger;
86
87        #[unsafe(method(headerRectOfColumn:))]
88        #[unsafe(method_family = none)]
89        pub unsafe fn headerRectOfColumn(&self, column: NSInteger) -> NSRect;
90
91        #[unsafe(method(columnAtPoint:))]
92        #[unsafe(method_family = none)]
93        pub unsafe fn columnAtPoint(&self, point: NSPoint) -> NSInteger;
94    );
95}
96
97/// Methods declared on superclass `NSView`.
98#[cfg(all(feature = "NSResponder", feature = "NSView"))]
99impl NSTableHeaderView {
100    extern_methods!(
101        #[unsafe(method(initWithFrame:))]
102        #[unsafe(method_family = init)]
103        pub unsafe fn initWithFrame(this: Allocated<Self>, frame_rect: NSRect) -> Retained<Self>;
104
105        #[unsafe(method(initWithCoder:))]
106        #[unsafe(method_family = init)]
107        pub unsafe fn initWithCoder(
108            this: Allocated<Self>,
109            coder: &NSCoder,
110        ) -> Option<Retained<Self>>;
111    );
112}
113
114/// Methods declared on superclass `NSResponder`.
115#[cfg(all(feature = "NSResponder", feature = "NSView"))]
116impl NSTableHeaderView {
117    extern_methods!(
118        #[unsafe(method(init))]
119        #[unsafe(method_family = init)]
120        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
121    );
122}
123
124/// Methods declared on superclass `NSObject`.
125#[cfg(all(feature = "NSResponder", feature = "NSView"))]
126impl NSTableHeaderView {
127    extern_methods!(
128        #[unsafe(method(new))]
129        #[unsafe(method_family = new)]
130        pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
131    );
132}