<!--
{
  "availability" : [
    "macCatalyst: 13.1.0 -",
    "macOS: 10.4.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreGraphics",
  "identifier" : "/documentation/CoreGraphics/CGEvent/post(tap:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Core Graphics",
      "CoreGraphics"
    ],
    "preciseIdentifier" : "c:@F@CGEventPost"
  },
  "title" : "post(tap:)"
}
-->

# post(tap:)

Posts a Quartz event into the event stream at a specified location.

```
func post(tap: CGEventTapLocation)
```

## Parameters

`tap`

The location at which to post the event. Pass one of the constants listed in [`CGEventTapLocation`](/documentation/CoreGraphics/CGEventTapLocation).

## Discussion

This function posts the specified event immediately before any event taps instantiated for that location, and the event passes through any such taps.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)