Double-click editing in IDE affected by emojis

  1. 2 weeks ago

    David C

    Oct 7 Pre-Release Testers, Xojo Pro Derby, ITM
    Edited 2 weeks ago

    When I double-click the 'Insert Emoji into text' string in the IDE, the selection is shifted two characters to the right, on both the left and right sides. If I remove the emoji face, the double-clicking highlights correctly. This happens on macOS, but might happen on other platforms.
    [quote]Me.ToolbarAddButton("InsertEmoji", "

  2. Greg O

    Oct 7 Xojo Inc

    Did you stop mid message there?

  3. David C

    Oct 7 Pre-Release Testers, Xojo Pro Derby, ITM

    No, I typed it all in OK and it looked fine in Preview, but on clicking Reply it missed the emoji down. So I edited the bottom again and clicked OK and it lost it again!

  4. David C

    Oct 7 Pre-Release Testers, Xojo Pro Derby, ITM

    Me.ToolbarAddButton("InsertEmoji", "Emoji face goes here", "Insert Emoji into text")

    If any others have this issue too, I'll add a Feedback report.

  5. Beatrix W

    Oct 7 Pre-Release Testers, Third Party Store Europe (Germany)

    Not seeing this for High Sierra. Or you make a video about what you did.

  6. Tim P

    Oct 7 Pre-Release Testers Rochester, NY

    What you've run into is the forum doesn't accept all emojis and they just kinda break the post :P

  7. Tim P

    Oct 7 Pre-Release Testers Rochester, NY
    Edited 2 weeks ago

    Also, I see this behavior with how Dash does snippets. Dash sticks a light bulb emoji in where the caret is supposed to end up, and sometimes the insertion point ends up wrong. I would bet it's related to the emoji as you're seeing.

  8. Greg O

    Oct 7 Xojo Inc
    Edited 2 weeks ago

    @David C Me.ToolbarAddButton("InsertEmoji", "Emoji face goes here", "Insert Emoji into text")

    If any others have this issue too, I'll add a Feedback report.

    We use Graphics.StringWidth when measuring where the selection highlight should go. My off-the-cuff guess is that the Emoji actually consists of two or three “characters” when we do that, but displays as only one.

  9. last week

    David C

    Oct 8 Pre-Release Testers, Xojo Pro Derby, ITM

    Interestingly I have found a work around. In the IDE, with the line

    Me.ToolbarAddButton("InsertEmoji", "Emoji face goes here", "Insert Emoji into text")

    if I double-click on the word 'Insert' and drag right, the highlight is shifted. if I double-click on the word 'here' and drag left, the highlight is correct.
    -image-

or Sign Up to reply!