<!--
{
  "availability" : [
    "iOS: 17.4.0 -",
    "iPadOS: 17.4.0 -",
    "tvOS: 17.4.0 -",
    "visionOS: 1.1.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "BrowserEngineKit",
  "identifier" : "/documentation/BrowserEngineKit/BETextInteraction/showDictionary(forTextInContext:definingTextInRange:from:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "BrowserEngineKit"
    ],
    "preciseIdentifier" : "c:objc(cs)BETextInteraction(im)showDictionaryForTextInContext:definingTextInRange:fromRect:"
  },
  "title" : "showDictionary(forTextInContext:definingTextInRange:from:)"
}
-->

# showDictionary(forTextInContext:definingTextInRange:from:)

Presents a dictionary definition for the supplied text.

```
func showDictionary(forTextInContext textWithContext: String, definingTextInRange range: NSRange, from presentationRect: CGRect)
```

## Parameters

`textWithContext`

The text to supply a definition for, embedded in the sentence in which it appears in the text view’s document.

`range`

The range of the word to define in the context text.

`presentationRect`

The location of the text in the view, which the system uses to position the definition UI.

---

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)