Selecting between underscores with double-click

chris's Avatar

chris

23 Jul, 2014 06:08 PM

In most common markdown cases, and a few others besides, double-clicking the text between delimiters (such as **XXX** *XXX* /XXX/ etc) does the right thing and selects just the text. However with underscores, which are an explicit option, double-clicking the text (_XXX_) also selects the delimiter. This seems like inconsistent behavior?

  1. Support Staff 1 Posted by Fletcher on 23 Jul, 2014 06:18 PM

    Fletcher's Avatar

    This is standard OS X behavior (try it in TextEdit). I'm not sure that
    I feel strongly enough about it to override. This is likely in part due
    to the fact that URL's can contain underscores and should be selected
    all at once.

    In fact, as I think about it, I am more inclined to think that this is
    the proper behavior.

    Fletcher

  2. 2 Posted by chris on 23 Jul, 2014 06:26 PM

    chris's Avatar

    Your call, but I don't really understand. Forward slashes are obviously allowed in URLs but they aren't included when double-clicking. Same with + signs, etc.

  3. Support Staff 3 Posted by Fletcher on 23 Jul, 2014 09:03 PM

    Fletcher's Avatar

    I grant you it doesn't entirely make sense. But it's an OS X behavior,
    not a Composer behavior. And I don't feel strongly enough about it to
    override the standard behavior users expect for this.

    I'm happy to override when it makes sense, but a certain amount of
    consistency is also important.

    And if it really bothers you, feel free to file a bug report with Apple. ;)

  4. 4 Posted by chris on 23 Jul, 2014 09:37 PM

    chris's Avatar

    I assume it would be too much to have it be an option, say triggered in parallel with the "use underscores for emphasis" option?

  5. Support Staff 5 Posted by Fletcher on 23 Jul, 2014 09:57 PM

    Fletcher's Avatar

    I don't currently modify the way the OS handles which letters get
    selected when you click/double click/triple click/whatever. That's all
    handled by the OS.

    The only time I interfere with selection is after the fact -- while you
    type or make changes to the text. To implement this change would mean
    overriding something I currently don't have any reason to override.

    I can keep this on the list of things to consider, but I have to be
    honest -- it's **way** down on the list and unlikely to be implemented
    any time soon, if at all. But never say never, and all that.

  6. 6 Posted by chris on 23 Jul, 2014 10:09 PM

    chris's Avatar

    Gotcha. I should probably just stop using underscores for emphasis...it's just a routine irritation to have that option explicitly supported in one way but behave so annoyingly in another. Thanks.

  7. chris closed this discussion on 23 Jul, 2014 10:09 PM.

  8. Fletcher re-opened this discussion on 23 Jul, 2014 10:19 PM

  9. Support Staff 7 Posted by Fletcher on 23 Jul, 2014 10:19 PM

    Fletcher's Avatar

    As an alternative, you can use the "Increase Selection" command to grab
    the word without the "_" markers if the cursor is inside a word. Might
    not solve all issues, but may help with some?

  10. 8 Posted by chris on 23 Jul, 2014 10:29 PM

    chris's Avatar

    That is incredibly useful. Thanks!

  11. Fletcher closed this discussion on 05 Aug, 2014 05:04 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac