Code Yarns β€πŸ‘¨β€πŸ’»
Tech Blog ❖ Personal Blog

Firefox: Double-Click to Only Highlight Word

πŸ“… 2011-Apr-19 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ firefox, windows ⬩ πŸ“š Archive

Β 

Problem

If you double-click anywhere on a word of text in any application on Windows, it will highlight that word and any following whitespace characters upto the beginning of the next word. Supposedly, Mac behaves the same way too.

The reason for this behaviour seems to be to aid in copy-paste of a word inside a document. It also helps if one wants to delete a word, since the following whitespace is also nicely removed.

However, I find this behaviour quite anachronistic and irritating. Especially when I am editing text on Firefox and want to apply formatting on the highlighted word either in rich text mode or HTML mode.

Solution

Thankfully, there is an obscure feature hidden in Firefox to make it highlight only the word on a double-click and ignore the following whitespace. Open about:config and set layout.word_select.eat_space_to_next_word to false.

Reference

Tried with: Firefox 4


Β© 2022 Ashwin Nanjappa β€’ All writing under CC BY-SA license β€’ 🐘 @codeyarns@hachyderm.io β€’ πŸ“§