Gedit word select doesn't include space

Bug #638503 reported by Rising Eagle
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gedit
Won't Fix
Low
gedit (Ubuntu)
Triaged
Wishlist
Unassigned

Bug Description

When I select a word from a sentence by double clicking, it should include the nearest space and or non letter character (trailing if I click near the last letter and leading if I click near the first letter). Then when I drag or delete, I don't have to go back and delete the extra space from where the word was taken and type one in where the word is dropped off. Not everyone wants this, so select behavior should be set in a preferences menu. Microsoft word has this feature and it's selection behavior is even more sophisticated. Check it out.
Example 1:
These are the that times try men's souls -- now I select the word "times"
These are the that *times* try men's souls -- now if I drag to proper location, I get
These are the timesthat try men's souls -- now I have to insert a space between "times" and "that" and delete one after "that"
Corrected Example 1:
These are the that times try men's souls -- now I select the word "times" which includes trailing space (dbl clk on "es")
These are the that *times *try men's souls -- now if I drag to proper location, I get
These are the times that try men's souls -- now it's perfect
Example 2 - commas
I'll take red, orange, brown, *yellow, *and white marbles -- select "yellow" including comma and trailing space and move it
I'll take yellow, red, orange, brown, and white marbles -- now it's perfect

Tags: patch
Revision history for this message
Matthew Paul Thomas (mpt) wrote :

Preferences are good for things that a lot of people want all of the time and a lot of people want none of the time. They're annoying for things that everyone wants only some of the time.

Selecting the nearest space when double-clicking would work for the deletion and dragging cases, but it would fail for the case where you want to retype the word; and it would fail for the case where you want to apply, just to the word, an underline, a background color, or any other formatting that would be visible for the adjacent space. So that selection behavior would be something everyone wants only some of the time, and a preference would not be any help, because changing the preference would be even slower than correcting the mistake.

OpenOffice.org Writer handles this a better way: selecting the word does not select the nearest space, but deleting or dragging automatically deletes or moves the adjacent space as well. That works for the retyping and formatting cases as well as the deleting and dragging cases, and even with OOo's vast array of options, it doesn't have -- or need -- an option for it.

Revision history for this message
Rising Eagle (borntobesteve) wrote :

"OpenOffice.org Writer handles this a better way: selecting the word does not select the nearest space, but deleting or dragging automatically deletes or moves the adjacent space as well. That works for the retyping and formatting cases as well as the deleting and dragging cases, and even with OOo's vast array of options, it doesn't have -- or need -- an option for it."

Matthew's idea is way better. Do the fix that way.

Revision history for this message
Vish (vish) wrote :

This bug is an upstream one and it would be quite helpful if somebody experiencing it could send the bug the to the people writing the software. You can learn more about how to do this for various upstreams at https://wiki.ubuntu.com/Bugs/Upstream/GNOME .
Once submitted upstream , do report back here with the upstream bug number.Thanks in advance!

Changed in gedit (Ubuntu):
importance: Undecided → Wishlist
status: New → Confirmed
Changed in hundredpapercuts:
importance: Undecided → Wishlist
status: New → Confirmed
Revision history for this message
Tom Hurd (thurd) wrote :

This bug has been reported to the developers of the software. You can track it and make comments here: https://bugzilla.gnome.org/show_bug.cgi?id=634956

Vish (vish)
Changed in gedit:
importance: Undecided → Unknown
status: New → Unknown
Changed in gedit (Ubuntu):
status: Confirmed → Triaged
Changed in hundredpapercuts:
assignee: nobody → Papercuts Ninja (papercuts-ninja)
milestone: none → nt5-office
status: Confirmed → Triaged
Changed in gedit:
importance: Unknown → Low
status: Unknown → New
Revision history for this message
Alexandru Guduleasa (gulyan89) wrote :

I've sent a patch to upstream for this bug.
I'm attaching it here also.

This patch checks the source and destination of the drag.
If both source and destination have a space near them it will try to
extend the select to a space near the source to preserve the tokens (words).

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "drag & drop word patch" of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-reviewers team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
Revision history for this message
Sebastien Bacher (seb128) wrote :

Thank you for your work, I will review the patch next week if upstream doesn't beat me to it

Changed in hundredpapercuts:
milestone: nt5-office → quantal-2-productivity
Changed in hundredpapercuts:
milestone: quantal-2-productivity → gedit
Changed in hundredpapercuts:
milestone: gedit → papercuts-s-gedit
Changed in hundredpapercuts:
assignee: Papercuts Ninjas (papercuts-ninja) → nobody
Changed in gedit:
status: New → Won't Fix
Revision history for this message
Paul White (paulw2u) wrote :

Upstream bug report was closed as "RESOLVED WONTFIX" on 2015-02-07
Removing Papercuts task as Ubuntu won't ever carry a patch to offer
this additional functionality through subsequent releases of gedit.

no longer affects: hundredpapercuts
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.