1use 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
12#[repr(transparent)]
15#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
16pub struct NSButtonType(pub NSUInteger);
17impl NSButtonType {
18 #[doc(alias = "NSButtonTypeMomentaryLight")]
19 pub const MomentaryLight: Self = Self(0);
20 #[doc(alias = "NSButtonTypePushOnPushOff")]
21 pub const PushOnPushOff: Self = Self(1);
22 #[doc(alias = "NSButtonTypeToggle")]
23 pub const Toggle: Self = Self(2);
24 #[doc(alias = "NSButtonTypeSwitch")]
25 pub const Switch: Self = Self(3);
26 #[doc(alias = "NSButtonTypeRadio")]
27 pub const Radio: Self = Self(4);
28 #[doc(alias = "NSButtonTypeMomentaryChange")]
29 pub const MomentaryChange: Self = Self(5);
30 #[doc(alias = "NSButtonTypeOnOff")]
31 pub const OnOff: Self = Self(6);
32 #[doc(alias = "NSButtonTypeMomentaryPushIn")]
33 pub const MomentaryPushIn: Self = Self(7);
34 #[doc(alias = "NSButtonTypeAccelerator")]
35 pub const Accelerator: Self = Self(8);
36 #[doc(alias = "NSButtonTypeMultiLevelAccelerator")]
37 pub const MultiLevelAccelerator: Self = Self(9);
38}
39
40unsafe impl Encode for NSButtonType {
41 const ENCODING: Encoding = NSUInteger::ENCODING;
42}
43
44unsafe impl RefEncode for NSButtonType {
45 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
46}
47
48#[repr(transparent)]
51#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
52pub struct NSBezelStyle(pub NSUInteger);
53impl NSBezelStyle {
54 #[doc(alias = "NSBezelStyleAutomatic")]
56 pub const Automatic: Self = Self(0);
57 #[doc(alias = "NSBezelStylePush")]
59 pub const Push: Self = Self(1);
60 #[doc(alias = "NSBezelStyleFlexiblePush")]
62 pub const FlexiblePush: Self = Self(2);
63 #[doc(alias = "NSBezelStyleDisclosure")]
65 pub const Disclosure: Self = Self(5);
66 #[doc(alias = "NSBezelStyleCircular")]
68 pub const Circular: Self = Self(7);
69 #[doc(alias = "NSBezelStyleHelpButton")]
71 pub const HelpButton: Self = Self(9);
72 #[doc(alias = "NSBezelStyleSmallSquare")]
74 pub const SmallSquare: Self = Self(10);
75 #[doc(alias = "NSBezelStyleToolbar")]
77 pub const Toolbar: Self = Self(11);
78 #[doc(alias = "NSBezelStyleAccessoryBarAction")]
80 pub const AccessoryBarAction: Self = Self(12);
81 #[doc(alias = "NSBezelStyleAccessoryBar")]
83 pub const AccessoryBar: Self = Self(13);
84 #[doc(alias = "NSBezelStylePushDisclosure")]
86 pub const PushDisclosure: Self = Self(14);
87 #[doc(alias = "NSBezelStyleBadge")]
89 pub const Badge: Self = Self(15);
90 #[deprecated]
92 #[doc(alias = "NSBezelStyleShadowlessSquare")]
93 pub const ShadowlessSquare: Self = Self(6);
94 #[deprecated]
96 #[doc(alias = "NSBezelStyleTexturedSquare")]
97 pub const TexturedSquare: Self = Self(8);
98 #[deprecated]
100 #[doc(alias = "NSBezelStyleRounded")]
101 pub const Rounded: Self = Self(NSBezelStyle::Push.0);
102 #[deprecated]
104 #[doc(alias = "NSBezelStyleRegularSquare")]
105 pub const RegularSquare: Self = Self(NSBezelStyle::FlexiblePush.0);
106 #[deprecated]
108 #[doc(alias = "NSBezelStyleTexturedRounded")]
109 pub const TexturedRounded: Self = Self(NSBezelStyle::Toolbar.0);
110 #[deprecated]
112 #[doc(alias = "NSBezelStyleRoundRect")]
113 pub const RoundRect: Self = Self(NSBezelStyle::AccessoryBarAction.0);
114 #[deprecated]
116 #[doc(alias = "NSBezelStyleRecessed")]
117 pub const Recessed: Self = Self(NSBezelStyle::AccessoryBar.0);
118 #[deprecated]
120 #[doc(alias = "NSBezelStyleRoundedDisclosure")]
121 pub const RoundedDisclosure: Self = Self(NSBezelStyle::PushDisclosure.0);
122 #[deprecated]
124 #[doc(alias = "NSBezelStyleInline")]
125 pub const Inline: Self = Self(NSBezelStyle::Badge.0);
126}
127
128unsafe impl Encode for NSBezelStyle {
129 const ENCODING: Encoding = NSUInteger::ENCODING;
130}
131
132unsafe impl RefEncode for NSBezelStyle {
133 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
134}
135
136extern_class!(
137 #[unsafe(super(NSActionCell, NSCell, NSObject))]
139 #[derive(Debug, PartialEq, Eq, Hash)]
140 #[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
141 pub struct NSButtonCell;
142);
143
144#[cfg(all(
145 feature = "NSAccessibilityProtocols",
146 feature = "NSActionCell",
147 feature = "NSCell"
148))]
149unsafe impl NSAccessibility for NSButtonCell {}
150
151#[cfg(all(
152 feature = "NSAccessibilityProtocols",
153 feature = "NSActionCell",
154 feature = "NSCell"
155))]
156unsafe impl NSAccessibilityElementProtocol for NSButtonCell {}
157
158#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
159unsafe impl NSCoding for NSButtonCell {}
160
161#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
162unsafe impl NSCopying for NSButtonCell {}
163
164#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
165unsafe impl CopyingHelper for NSButtonCell {
166 type Result = Self;
167}
168
169#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
170unsafe impl NSObjectProtocol for NSButtonCell {}
171
172#[cfg(all(
173 feature = "NSActionCell",
174 feature = "NSCell",
175 feature = "NSUserInterfaceItemIdentification"
176))]
177unsafe impl NSUserInterfaceItemIdentification for NSButtonCell {}
178
179#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
180impl NSButtonCell {
181 extern_methods!(
182 #[unsafe(method(initTextCell:))]
183 #[unsafe(method_family = init)]
184 pub unsafe fn initTextCell(this: Allocated<Self>, string: &NSString) -> Retained<Self>;
185
186 #[cfg(feature = "NSImage")]
187 #[unsafe(method(initImageCell:))]
188 #[unsafe(method_family = init)]
189 pub unsafe fn initImageCell(
190 this: Allocated<Self>,
191 image: Option<&NSImage>,
192 ) -> Retained<Self>;
193
194 #[unsafe(method(initWithCoder:))]
195 #[unsafe(method_family = init)]
196 pub unsafe fn initWithCoder(this: Allocated<Self>, coder: &NSCoder) -> Retained<Self>;
197
198 #[unsafe(method(bezelStyle))]
199 #[unsafe(method_family = none)]
200 pub unsafe fn bezelStyle(&self) -> NSBezelStyle;
201
202 #[unsafe(method(setBezelStyle:))]
204 #[unsafe(method_family = none)]
205 pub unsafe fn setBezelStyle(&self, bezel_style: NSBezelStyle);
206
207 #[unsafe(method(setButtonType:))]
208 #[unsafe(method_family = none)]
209 pub unsafe fn setButtonType(&self, r#type: NSButtonType);
210
211 #[unsafe(method(highlightsBy))]
212 #[unsafe(method_family = none)]
213 pub unsafe fn highlightsBy(&self) -> NSCellStyleMask;
214
215 #[unsafe(method(setHighlightsBy:))]
217 #[unsafe(method_family = none)]
218 pub unsafe fn setHighlightsBy(&self, highlights_by: NSCellStyleMask);
219
220 #[unsafe(method(showsStateBy))]
221 #[unsafe(method_family = none)]
222 pub unsafe fn showsStateBy(&self) -> NSCellStyleMask;
223
224 #[unsafe(method(setShowsStateBy:))]
226 #[unsafe(method_family = none)]
227 pub unsafe fn setShowsStateBy(&self, shows_state_by: NSCellStyleMask);
228
229 #[unsafe(method(title))]
230 #[unsafe(method_family = none)]
231 pub unsafe fn title(&self) -> Retained<NSString>;
232
233 #[unsafe(method(setTitle:))]
235 #[unsafe(method_family = none)]
236 pub unsafe fn setTitle(&self, title: Option<&NSString>);
237
238 #[unsafe(method(attributedTitle))]
239 #[unsafe(method_family = none)]
240 pub unsafe fn attributedTitle(&self) -> Retained<NSAttributedString>;
241
242 #[unsafe(method(setAttributedTitle:))]
244 #[unsafe(method_family = none)]
245 pub unsafe fn setAttributedTitle(&self, attributed_title: &NSAttributedString);
246
247 #[unsafe(method(alternateTitle))]
248 #[unsafe(method_family = none)]
249 pub unsafe fn alternateTitle(&self) -> Retained<NSString>;
250
251 #[unsafe(method(setAlternateTitle:))]
253 #[unsafe(method_family = none)]
254 pub unsafe fn setAlternateTitle(&self, alternate_title: &NSString);
255
256 #[unsafe(method(attributedAlternateTitle))]
257 #[unsafe(method_family = none)]
258 pub unsafe fn attributedAlternateTitle(&self) -> Retained<NSAttributedString>;
259
260 #[unsafe(method(setAttributedAlternateTitle:))]
262 #[unsafe(method_family = none)]
263 pub unsafe fn setAttributedAlternateTitle(
264 &self,
265 attributed_alternate_title: &NSAttributedString,
266 );
267
268 #[cfg(feature = "NSImage")]
269 #[unsafe(method(alternateImage))]
270 #[unsafe(method_family = none)]
271 pub unsafe fn alternateImage(&self) -> Option<Retained<NSImage>>;
272
273 #[cfg(feature = "NSImage")]
274 #[unsafe(method(setAlternateImage:))]
276 #[unsafe(method_family = none)]
277 pub unsafe fn setAlternateImage(&self, alternate_image: Option<&NSImage>);
278
279 #[unsafe(method(imagePosition))]
280 #[unsafe(method_family = none)]
281 pub unsafe fn imagePosition(&self) -> NSCellImagePosition;
282
283 #[unsafe(method(setImagePosition:))]
285 #[unsafe(method_family = none)]
286 pub unsafe fn setImagePosition(&self, image_position: NSCellImagePosition);
287
288 #[unsafe(method(imageScaling))]
289 #[unsafe(method_family = none)]
290 pub unsafe fn imageScaling(&self) -> NSImageScaling;
291
292 #[unsafe(method(setImageScaling:))]
294 #[unsafe(method_family = none)]
295 pub unsafe fn setImageScaling(&self, image_scaling: NSImageScaling);
296
297 #[unsafe(method(keyEquivalent))]
298 #[unsafe(method_family = none)]
299 pub unsafe fn keyEquivalent(&self) -> Retained<NSString>;
300
301 #[unsafe(method(setKeyEquivalent:))]
303 #[unsafe(method_family = none)]
304 pub unsafe fn setKeyEquivalent(&self, key_equivalent: &NSString);
305
306 #[cfg(feature = "NSEvent")]
307 #[unsafe(method(keyEquivalentModifierMask))]
308 #[unsafe(method_family = none)]
309 pub unsafe fn keyEquivalentModifierMask(&self) -> NSEventModifierFlags;
310
311 #[cfg(feature = "NSEvent")]
312 #[unsafe(method(setKeyEquivalentModifierMask:))]
314 #[unsafe(method_family = none)]
315 pub unsafe fn setKeyEquivalentModifierMask(
316 &self,
317 key_equivalent_modifier_mask: NSEventModifierFlags,
318 );
319
320 #[unsafe(method(isTransparent))]
321 #[unsafe(method_family = none)]
322 pub unsafe fn isTransparent(&self) -> bool;
323
324 #[unsafe(method(setTransparent:))]
326 #[unsafe(method_family = none)]
327 pub unsafe fn setTransparent(&self, transparent: bool);
328
329 #[unsafe(method(isOpaque))]
330 #[unsafe(method_family = none)]
331 pub unsafe fn isOpaque(&self) -> bool;
332
333 #[unsafe(method(imageDimsWhenDisabled))]
334 #[unsafe(method_family = none)]
335 pub unsafe fn imageDimsWhenDisabled(&self) -> bool;
336
337 #[unsafe(method(setImageDimsWhenDisabled:))]
339 #[unsafe(method_family = none)]
340 pub unsafe fn setImageDimsWhenDisabled(&self, image_dims_when_disabled: bool);
341
342 #[unsafe(method(showsBorderOnlyWhileMouseInside))]
343 #[unsafe(method_family = none)]
344 pub unsafe fn showsBorderOnlyWhileMouseInside(&self) -> bool;
345
346 #[unsafe(method(setShowsBorderOnlyWhileMouseInside:))]
348 #[unsafe(method_family = none)]
349 pub unsafe fn setShowsBorderOnlyWhileMouseInside(
350 &self,
351 shows_border_only_while_mouse_inside: bool,
352 );
353
354 #[cfg(feature = "NSSound")]
355 #[unsafe(method(sound))]
356 #[unsafe(method_family = none)]
357 pub unsafe fn sound(&self) -> Option<Retained<NSSound>>;
358
359 #[cfg(feature = "NSSound")]
360 #[unsafe(method(setSound:))]
362 #[unsafe(method_family = none)]
363 pub unsafe fn setSound(&self, sound: Option<&NSSound>);
364
365 #[cfg(feature = "NSColor")]
366 #[unsafe(method(backgroundColor))]
367 #[unsafe(method_family = none)]
368 pub unsafe fn backgroundColor(&self) -> Option<Retained<NSColor>>;
369
370 #[cfg(feature = "NSColor")]
371 #[unsafe(method(setBackgroundColor:))]
373 #[unsafe(method_family = none)]
374 pub unsafe fn setBackgroundColor(&self, background_color: Option<&NSColor>);
375
376 #[unsafe(method(setPeriodicDelay:interval:))]
377 #[unsafe(method_family = none)]
378 pub unsafe fn setPeriodicDelay_interval(&self, delay: c_float, interval: c_float);
379
380 #[unsafe(method(getPeriodicDelay:interval:))]
381 #[unsafe(method_family = none)]
382 pub unsafe fn getPeriodicDelay_interval(
383 &self,
384 delay: NonNull<c_float>,
385 interval: NonNull<c_float>,
386 );
387
388 #[unsafe(method(performClick:))]
389 #[unsafe(method_family = none)]
390 pub unsafe fn performClick(&self, sender: Option<&AnyObject>);
391
392 #[cfg(feature = "NSEvent")]
393 #[unsafe(method(mouseEntered:))]
394 #[unsafe(method_family = none)]
395 pub unsafe fn mouseEntered(&self, event: &NSEvent);
396
397 #[cfg(feature = "NSEvent")]
398 #[unsafe(method(mouseExited:))]
399 #[unsafe(method_family = none)]
400 pub unsafe fn mouseExited(&self, event: &NSEvent);
401
402 #[cfg(all(feature = "NSResponder", feature = "NSView"))]
403 #[unsafe(method(drawBezelWithFrame:inView:))]
404 #[unsafe(method_family = none)]
405 pub unsafe fn drawBezelWithFrame_inView(&self, frame: NSRect, control_view: &NSView);
406
407 #[cfg(all(feature = "NSImage", feature = "NSResponder", feature = "NSView"))]
408 #[unsafe(method(drawImage:withFrame:inView:))]
409 #[unsafe(method_family = none)]
410 pub unsafe fn drawImage_withFrame_inView(
411 &self,
412 image: &NSImage,
413 frame: NSRect,
414 control_view: &NSView,
415 );
416
417 #[cfg(all(feature = "NSResponder", feature = "NSView"))]
418 #[unsafe(method(drawTitle:withFrame:inView:))]
419 #[unsafe(method_family = none)]
420 pub unsafe fn drawTitle_withFrame_inView(
421 &self,
422 title: &NSAttributedString,
423 frame: NSRect,
424 control_view: &NSView,
425 ) -> NSRect;
426 );
427}
428
429#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
431impl NSButtonCell {
432 extern_methods!(
433 #[unsafe(method(init))]
434 #[unsafe(method_family = init)]
435 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
436 );
437}
438
439#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
441impl NSButtonCell {
442 extern_methods!(
443 #[unsafe(method(new))]
444 #[unsafe(method_family = new)]
445 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
446 );
447}
448
449#[deprecated]
452#[repr(transparent)]
453#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
454pub struct NSGradientType(pub NSUInteger);
455impl NSGradientType {
456 #[doc(alias = "NSGradientNone")]
457 pub const None: Self = Self(0);
458 #[doc(alias = "NSGradientConcaveWeak")]
459 pub const ConcaveWeak: Self = Self(1);
460 #[doc(alias = "NSGradientConcaveStrong")]
461 pub const ConcaveStrong: Self = Self(2);
462 #[doc(alias = "NSGradientConvexWeak")]
463 pub const ConvexWeak: Self = Self(3);
464 #[doc(alias = "NSGradientConvexStrong")]
465 pub const ConvexStrong: Self = Self(4);
466}
467
468unsafe impl Encode for NSGradientType {
469 const ENCODING: Encoding = NSUInteger::ENCODING;
470}
471
472unsafe impl RefEncode for NSGradientType {
473 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
474}
475
476pub static NSMomentaryLightButton: NSButtonType = NSButtonType(NSButtonType::MomentaryLight.0);
478
479pub static NSPushOnPushOffButton: NSButtonType = NSButtonType(NSButtonType::PushOnPushOff.0);
481
482pub static NSToggleButton: NSButtonType = NSButtonType(NSButtonType::Toggle.0);
484
485pub static NSSwitchButton: NSButtonType = NSButtonType(NSButtonType::Switch.0);
487
488pub static NSRadioButton: NSButtonType = NSButtonType(NSButtonType::Radio.0);
490
491pub static NSMomentaryChangeButton: NSButtonType = NSButtonType(NSButtonType::MomentaryChange.0);
493
494pub static NSOnOffButton: NSButtonType = NSButtonType(NSButtonType::OnOff.0);
496
497pub static NSMomentaryPushInButton: NSButtonType = NSButtonType(NSButtonType::MomentaryPushIn.0);
499
500pub static NSAcceleratorButton: NSButtonType = NSButtonType(NSButtonType::Accelerator.0);
502
503pub static NSMultiLevelAcceleratorButton: NSButtonType =
505 NSButtonType(NSButtonType::MultiLevelAccelerator.0);
506
507pub static NSMomentaryPushButton: NSButtonType = NSButtonType(NSButtonType::MomentaryLight.0);
509
510pub static NSMomentaryLight: NSButtonType = NSButtonType(NSButtonType::MomentaryPushIn.0);
512
513pub static NSRoundedBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::Push.0);
515
516pub static NSRegularSquareBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::FlexiblePush.0);
518
519pub static NSDisclosureBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::Disclosure.0);
521
522pub static NSShadowlessSquareBezelStyle: NSBezelStyle =
524 NSBezelStyle(NSBezelStyle::ShadowlessSquare.0);
525
526pub static NSCircularBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::Circular.0);
528
529pub static NSTexturedSquareBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::TexturedSquare.0);
531
532pub static NSHelpButtonBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::HelpButton.0);
534
535pub static NSSmallSquareBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::SmallSquare.0);
537
538pub static NSTexturedRoundedBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::Toolbar.0);
540
541pub static NSRoundRectBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::AccessoryBarAction.0);
543
544pub static NSRecessedBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::AccessoryBar.0);
546
547pub static NSRoundedDisclosureBezelStyle: NSBezelStyle =
549 NSBezelStyle(NSBezelStyle::PushDisclosure.0);
550
551pub static NSInlineBezelStyle: NSBezelStyle = NSBezelStyle(NSBezelStyle::Badge.0);
553
554pub static NSSmallIconButtonBezelStyle: NSBezelStyle = NSBezelStyle(2);
556
557pub static NSThickSquareBezelStyle: NSBezelStyle = NSBezelStyle(3);
559
560pub static NSThickerSquareBezelStyle: NSBezelStyle = NSBezelStyle(4);
562
563#[cfg(all(feature = "NSActionCell", feature = "NSCell"))]
565impl NSButtonCell {
566 extern_methods!(
567 #[deprecated = "The gradientType property is unused, and setting it has no effect."]
568 #[unsafe(method(gradientType))]
569 #[unsafe(method_family = none)]
570 pub unsafe fn gradientType(&self) -> NSGradientType;
571
572 #[deprecated = "The gradientType property is unused, and setting it has no effect."]
574 #[unsafe(method(setGradientType:))]
575 #[unsafe(method_family = none)]
576 pub unsafe fn setGradientType(&self, gradient_type: NSGradientType);
577
578 #[deprecated = "Mnemonics are not used on macOS. Set the title property directly instead."]
579 #[unsafe(method(setTitleWithMnemonic:))]
580 #[unsafe(method_family = none)]
581 pub unsafe fn setTitleWithMnemonic(&self, string_with_ampersand: Option<&NSString>);
582
583 #[deprecated = "Mnemonics are not used on macOS. Set the alternateTitle property directly instead."]
584 #[unsafe(method(setAlternateTitleWithMnemonic:))]
585 #[unsafe(method_family = none)]
586 pub unsafe fn setAlternateTitleWithMnemonic(
587 &self,
588 string_with_ampersand: Option<&NSString>,
589 );
590
591 #[deprecated = "Mnemonics are not used on macOS. Calling this method has no effect."]
592 #[unsafe(method(setAlternateMnemonicLocation:))]
593 #[unsafe(method_family = none)]
594 pub unsafe fn setAlternateMnemonicLocation(&self, location: NSUInteger);
595
596 #[deprecated = "Mnemonics are not used on macOS. This property always returns NSNotFound."]
597 #[unsafe(method(alternateMnemonicLocation))]
598 #[unsafe(method_family = none)]
599 pub unsafe fn alternateMnemonicLocation(&self) -> NSUInteger;
600
601 #[deprecated = "Mnemonics are not used on macOS. This property always returns an empty string."]
602 #[unsafe(method(alternateMnemonic))]
603 #[unsafe(method_family = none)]
604 pub unsafe fn alternateMnemonic(&self) -> Option<Retained<NSString>>;
605
606 #[cfg(feature = "NSFont")]
607 #[deprecated = "The keyEquivalentFont property is no longer used. It always returns the NSButtonCell's font, and setting it has no effect."]
608 #[unsafe(method(keyEquivalentFont))]
609 #[unsafe(method_family = none)]
610 pub unsafe fn keyEquivalentFont(&self) -> Option<Retained<NSFont>>;
611
612 #[cfg(feature = "NSFont")]
613 #[deprecated = "The keyEquivalentFont property is no longer used. It always returns the NSButtonCell's font, and setting it has no effect."]
615 #[unsafe(method(setKeyEquivalentFont:))]
616 #[unsafe(method_family = none)]
617 pub unsafe fn setKeyEquivalentFont(&self, key_equivalent_font: Option<&NSFont>);
618
619 #[cfg(feature = "objc2-core-foundation")]
620 #[deprecated = "The keyEquivalentFont property is no longer used. Setting it has no effect."]
621 #[unsafe(method(setKeyEquivalentFont:size:))]
622 #[unsafe(method_family = none)]
623 pub unsafe fn setKeyEquivalentFont_size(&self, font_name: &NSString, font_size: CGFloat);
624 );
625}