I’m having some issues when scrolling a multiline InputField using PageUp/PageDown keys:
Even if the text doesn’t need to scroll, when pressing PageDown key, the text goes all the way down disappearing from view. Then, when trying to go up again using PageUp, it slowly scrolls up as you can see in the screenshot below:
I suppose this is a bug, but is there a workaround for this issue? As the source code of TMP isn’t public and the legacy InputField doesn’t support scrolling with PageUp/PageDown keys, I don’t have a clue of what’s going on.
I’ll try taking a look at this later tonight or over the weekend.
The package manager version of TextMesh Pro include source code. You can access the various scripts by navigating to the Packages folder in the project as seen below.
Note that changes made there are only done to the local cached version of the package located in the local project’s “Library/PackageCache/…” folder.
Resurrecting this thread because this is still a reproducible bug, PageUp and PageDown keys still cause a multiline input field to scroll.
However, I have managed to find a temporary solution.
It appears that tapping PageUp or PageDown causes the RectTransform.anchoredPosition to shift on the visible input field, alongside the RectTransform.anchoredPosition of the caret the input instantiates.
The solution is simply to revert their positions when the PageUp and PageDown keys are tapped.