#[repr(C)]pub struct CTRunDelegateCallbacks {
pub version: CFIndex,
pub dealloc: CTRunDelegateDeallocateCallback,
pub getAscent: CTRunDelegateGetAscentCallback,
pub getDescent: CTRunDelegateGetDescentCallback,
pub getWidth: CTRunDelegateGetWidthCallback,
}CTRunDelegate only.Expand description
Structure containing the callbacks of a CTRunDelegate.
These callbacks are provided by the owner of a run delegate and are used to modify glyph metrics during layout. The values returned by a delegate are applied to each glyph in the run(s) corresponding to the attribute containing that delegate.
Field: version The version number of the callbacks being passed in as a parameter to CTRunDelegateCreate. This field should always be set to kCTRunDelegateCurrentVersion.
Field: dealloc The callback used when a CTRunDelegate’s retain count reaches 0 and the CTRunDelegate is deallocated. This callback may be NULL.
Field: getAscent The callback used to indicate the ascent of the CTRunDelegate. This callback may be NULL, which is equivalent to a getAscent callback that always returns 0.
Field: getDescent The callback used to indicate the descent of the CTRunDelegate. This callback may be NULL, which is equivalent to a getDescent callback that always returns 0.
Field: getWidth The callback used to indicate the width of the CTRunDelegate. This callback may be NULL, which is equivalent to a getWidth callback that always returns 0.
See also Apple’s documentation
Fields§
§version: CFIndex§dealloc: CTRunDelegateDeallocateCallback§getAscent: CTRunDelegateGetAscentCallback§getDescent: CTRunDelegateGetDescentCallback§getWidth: CTRunDelegateGetWidthCallbackTrait Implementations§
Source§impl Clone for CTRunDelegateCallbacks
impl Clone for CTRunDelegateCallbacks
Source§fn clone(&self) -> CTRunDelegateCallbacks
fn clone(&self) -> CTRunDelegateCallbacks
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CTRunDelegateCallbacks
impl Debug for CTRunDelegateCallbacks
Source§impl Encode for CTRunDelegateCallbacks
Available on crate feature objc2 only.
impl Encode for CTRunDelegateCallbacks
objc2 only.Source§impl PartialEq for CTRunDelegateCallbacks
impl PartialEq for CTRunDelegateCallbacks
Source§impl RefEncode for CTRunDelegateCallbacks
Available on crate feature objc2 only.
impl RefEncode for CTRunDelegateCallbacks
objc2 only.