---
title: "adjustTextPosition(byCharacterOffset:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uitextdocumentproxy/adjusttextposition(bycharacteroffset:)"
---

# adjustTextPosition(byCharacterOffset:)

Moves the insertion point forward or backward in the current text input object.

## Declaration

```swift
func adjustTextPosition(byCharacterOffset offset: Int)
```

## Parameters

- `offset`: The number of characters to adjust the insertion point by. A positive value moves the insertion point forward (according to the text storage direction for the current language). A negative value moves the insertion point backward.

## Mentioned in

Handling text interactions in custom keyboards
