I use the mobile app quite frequently. Recently, I was trying to write the following text:

Put <-- language: lang-none --> before…

However, because mobile has no "code block" button in the comments, I have to select the text afterwards and tap-and-hold to get the appropriate context menu. When I tried to select the part to be put in a code block, I selected language, dragged it all the way to the right, which worked fine, then dragged the left side of the boundary to the left <. When I released it, the selection jumped to include Put as well, and no matter what I tried to get it to stop moving around after I released it, it continued to add Put to the selection. Eventually, I dealt with it by realizing the comment was based on an incorrect premise anyway and shouldn't be posted.

  • Ugh. This appears to be a fundamental flaw on short text views in iOS. If I paste the above text into Messages.app, I have the exact same problem. May 27 '16 at 19:27
  • @BrianNickel ...Huh. That's odd. I never noticed it in Google Docs. Maybe they fiddled with it? Or maybe I just write code rarely enough in it that I don't notice. Also, hi again!
    – Nic
    May 28 '16 at 2:10

This is an iOS bug unfortunately. iOS has built UITextView in such a way that if a user is selecting text and certain things happen (like scrolling), the user's selection should be treated as imprecise and that the selection should be expanded to the whole word on release.

In this case, whole word apparently means expanding from < to Put < and the thing that triggers imprecise selection is moving your finger above the bounds of the text view.

I've opened an bug report with Apple (rdar://26676423) that touching above the top of the text view while selecting the first line of text should not trigger this behavior.

  • Ugh, that's infuriating. And, like all Apple things, [rant omitted for brevity]. Thanks for the help!
    – Nic
    Jun 7 '16 at 18:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .