addToBuilderAsBlocking static method

void addToBuilderAsBlocking(
  1. ObjCProtocolBuilder builder, {
  2. DartNSUInteger layoutManager_shouldGenerateGlyphs_properties_characterIndexes_font_forGlyphRange_(
    1. NSLayoutManager,
    2. Pointer<CGGlyph>,
    3. Pointer<NSInteger>,
    4. Pointer<NSUInteger>,
    5. NSFont,
    6. NSRange,
    )?,
  3. DartCGFloat layoutManager_lineSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_(
    1. NSLayoutManager,
    2. DartNSUInteger,
    3. NSRect
    )?,
  4. DartCGFloat layoutManager_paragraphSpacingBeforeGlyphAtIndex_withProposedLineFragmentRect_(
    1. NSLayoutManager,
    2. DartNSUInteger,
    3. NSRect
    )?,
  5. DartCGFloat layoutManager_paragraphSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_(
    1. NSLayoutManager,
    2. DartNSUInteger,
    3. NSRect
    )?,
  6. NSControlCharacterAction layoutManager_shouldUseAction_forControlCharacterAtIndex_(
    1. NSLayoutManager,
    2. NSControlCharacterAction,
    3. DartNSUInteger
    )?,
  7. bool layoutManager_shouldBreakLineByWordBeforeCharacterAtIndex_(
    1. NSLayoutManager,
    2. DartNSUInteger
    )?,
  8. bool layoutManager_shouldBreakLineByHyphenatingBeforeCharacterAtIndex_(
    1. NSLayoutManager,
    2. DartNSUInteger
    )?,
  9. NSRect layoutManager_boundingBoxForControlGlyphAtIndex_forTextContainer_proposedLineFragment_glyphPosition_characterIndex_(
    1. NSLayoutManager,
    2. DartNSUInteger,
    3. NSTextContainer,
    4. NSRect,
    5. NSPoint,
    6. DartNSUInteger,
    )?,
  10. bool layoutManager_shouldSetLineFragmentRect_lineFragmentUsedRect_baselineOffset_inTextContainer_forGlyphRange_(
    1. NSLayoutManager,
    2. Pointer<NSRect>,
    3. Pointer<NSRect>,
    4. Pointer<CGFloat>,
    5. NSTextContainer,
    6. NSRange,
    )?,
  11. void layoutManagerDidInvalidateLayout_(
    1. NSLayoutManager
    )?,
  12. void layoutManager_didCompleteLayoutForTextContainer_atEnd_(
    1. NSLayoutManager,
    2. NSTextContainer?,
    3. bool
    )?,
  13. void layoutManager_textContainer_didChangeGeometryFromSize_(
    1. NSLayoutManager,
    2. NSTextContainer,
    3. NSSize
    )?,
  14. NSDictionary? layoutManager_shouldUseTemporaryAttributes_forDrawingToScreen_atCharacterIndex_effectiveRange_(
    1. NSLayoutManager,
    2. NSDictionary,
    3. bool,
    4. DartNSUInteger,
    5. NSRangePointer,
    )?,
  15. bool $keepIsolateAlive = true,
})

Adds the implementation of the NSLayoutManagerDelegate protocol to an existing objc.ObjCProtocolBuilder. All methods that can be implemented as blocking listeners will be.

Note: You cannot call this method after you have called builder.build.

Implementation

static void addToBuilderAsBlocking(
  objc.ObjCProtocolBuilder builder, {
  DartNSUInteger Function(
    NSLayoutManager,
    ffi.Pointer<CGGlyph>,
    ffi.Pointer<NSInteger>,
    ffi.Pointer<NSUInteger>,
    NSFont,
    NSRange,
  )?
  layoutManager_shouldGenerateGlyphs_properties_characterIndexes_font_forGlyphRange_,
  DartCGFloat Function(NSLayoutManager, DartNSUInteger, NSRect)?
  layoutManager_lineSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_,
  DartCGFloat Function(NSLayoutManager, DartNSUInteger, NSRect)?
  layoutManager_paragraphSpacingBeforeGlyphAtIndex_withProposedLineFragmentRect_,
  DartCGFloat Function(NSLayoutManager, DartNSUInteger, NSRect)?
  layoutManager_paragraphSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_,
  NSControlCharacterAction Function(
    NSLayoutManager,
    NSControlCharacterAction,
    DartNSUInteger,
  )?
  layoutManager_shouldUseAction_forControlCharacterAtIndex_,
  bool Function(NSLayoutManager, DartNSUInteger)?
  layoutManager_shouldBreakLineByWordBeforeCharacterAtIndex_,
  bool Function(NSLayoutManager, DartNSUInteger)?
  layoutManager_shouldBreakLineByHyphenatingBeforeCharacterAtIndex_,
  NSRect Function(
    NSLayoutManager,
    DartNSUInteger,
    NSTextContainer,
    NSRect,
    NSPoint,
    DartNSUInteger,
  )?
  layoutManager_boundingBoxForControlGlyphAtIndex_forTextContainer_proposedLineFragment_glyphPosition_characterIndex_,
  bool Function(
    NSLayoutManager,
    ffi.Pointer<NSRect>,
    ffi.Pointer<NSRect>,
    ffi.Pointer<CGFloat>,
    NSTextContainer,
    NSRange,
  )?
  layoutManager_shouldSetLineFragmentRect_lineFragmentUsedRect_baselineOffset_inTextContainer_forGlyphRange_,
  void Function(NSLayoutManager)? layoutManagerDidInvalidateLayout_,
  void Function(NSLayoutManager, NSTextContainer?, bool)?
  layoutManager_didCompleteLayoutForTextContainer_atEnd_,
  void Function(NSLayoutManager, NSTextContainer, NSSize)?
  layoutManager_textContainer_didChangeGeometryFromSize_,
  objc.NSDictionary? Function(
    NSLayoutManager,
    objc.NSDictionary,
    bool,
    DartNSUInteger,
    NSRangePointer,
  )?
  layoutManager_shouldUseTemporaryAttributes_forDrawingToScreen_atCharacterIndex_effectiveRange_,
  bool $keepIsolateAlive = true,
}) {
  NSLayoutManagerDelegate
      .layoutManager_shouldGenerateGlyphs_properties_characterIndexes_font_forGlyphRange_
      .implement(
        builder,
        layoutManager_shouldGenerateGlyphs_properties_characterIndexes_font_forGlyphRange_,
      );
  NSLayoutManagerDelegate
      .layoutManager_lineSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_
      .implement(
        builder,
        layoutManager_lineSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_,
      );
  NSLayoutManagerDelegate
      .layoutManager_paragraphSpacingBeforeGlyphAtIndex_withProposedLineFragmentRect_
      .implement(
        builder,
        layoutManager_paragraphSpacingBeforeGlyphAtIndex_withProposedLineFragmentRect_,
      );
  NSLayoutManagerDelegate
      .layoutManager_paragraphSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_
      .implement(
        builder,
        layoutManager_paragraphSpacingAfterGlyphAtIndex_withProposedLineFragmentRect_,
      );
  NSLayoutManagerDelegate
      .layoutManager_shouldUseAction_forControlCharacterAtIndex_
      .implement(
        builder,
        layoutManager_shouldUseAction_forControlCharacterAtIndex_,
      );
  NSLayoutManagerDelegate
      .layoutManager_shouldBreakLineByWordBeforeCharacterAtIndex_
      .implement(
        builder,
        layoutManager_shouldBreakLineByWordBeforeCharacterAtIndex_,
      );
  NSLayoutManagerDelegate
      .layoutManager_shouldBreakLineByHyphenatingBeforeCharacterAtIndex_
      .implement(
        builder,
        layoutManager_shouldBreakLineByHyphenatingBeforeCharacterAtIndex_,
      );
  NSLayoutManagerDelegate
      .layoutManager_boundingBoxForControlGlyphAtIndex_forTextContainer_proposedLineFragment_glyphPosition_characterIndex_
      .implement(
        builder,
        layoutManager_boundingBoxForControlGlyphAtIndex_forTextContainer_proposedLineFragment_glyphPosition_characterIndex_,
      );
  NSLayoutManagerDelegate
      .layoutManager_shouldSetLineFragmentRect_lineFragmentUsedRect_baselineOffset_inTextContainer_forGlyphRange_
      .implement(
        builder,
        layoutManager_shouldSetLineFragmentRect_lineFragmentUsedRect_baselineOffset_inTextContainer_forGlyphRange_,
      );
  NSLayoutManagerDelegate.layoutManagerDidInvalidateLayout_
      .implementAsBlocking(builder, layoutManagerDidInvalidateLayout_);
  NSLayoutManagerDelegate
      .layoutManager_didCompleteLayoutForTextContainer_atEnd_
      .implementAsBlocking(
        builder,
        layoutManager_didCompleteLayoutForTextContainer_atEnd_,
      );
  NSLayoutManagerDelegate
      .layoutManager_textContainer_didChangeGeometryFromSize_
      .implementAsBlocking(
        builder,
        layoutManager_textContainer_didChangeGeometryFromSize_,
      );
  NSLayoutManagerDelegate
      .layoutManager_shouldUseTemporaryAttributes_forDrawingToScreen_atCharacterIndex_effectiveRange_
      .implement(
        builder,
        layoutManager_shouldUseTemporaryAttributes_forDrawingToScreen_atCharacterIndex_effectiveRange_,
      );
  builder.addProtocol($protocol);
}