Closed Bug 955314 Opened 10 years ago Closed 10 years ago

Nick completion should add punctuation after complete nicks

Categories

(Instantbird Graveyard :: Conversation, enhancement)

x86
Other
enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: florian, Assigned: aleth)

Details

Attachments

(1 file, 5 obsolete files)

*** Original post on bio 1881 at 2013-02-22 20:00:00 UTC ***

When I type jb<tab> I'm surprised that ": " isn't inserted.
Attached patch Patch (obsolete) — Splinter Review
*** Original post on bio 1881 as attmnt 2242 at 2013-02-22 22:30:00 UTC ***

This should fix it.
Attachment #8354006 - Flags: review?(florian)
Assignee: nobody → aleth
Status: NEW → ASSIGNED
Comment on attachment 8354006 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2242 at 2013-02-22 23:12:07 UTC ***

12:04:02 AM - flo-retina: aleth: if there's Standard8 and Standard8|mobile in the channel, and I type Standard8<tab> what's the expected behavior?
Attachment #8354006 - Flags: review?(florian) → review-
Attached patch Patch (obsolete) — Splinter Review
*** Original post on bio 1881 as attmnt 2243 at 2013-02-22 23:41:00 UTC ***

I think this is a more consistent experience for the case of multiple possible completions, but please test!
Attachment #8354007 - Flags: review?(florian)
Comment on attachment 8354006 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2242 at 2013-02-22 23:41:37 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8354006 - Attachment is obsolete: true
Attached patch Patch (obsolete) — Splinter Review
*** Original post on bio 1881 as attmnt 2245 at 2013-02-23 10:46:00 UTC ***

Edge case of the edge case: If there is already punctuation, don't add any more.
Attachment #8354009 - Flags: review?(florian)
Comment on attachment 8354007 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2243 at 2013-02-23 10:46:29 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8354007 - Attachment is obsolete: true
Attachment #8354007 - Flags: review?(florian)
Comment on attachment 8354009 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2245 at 2013-03-09 16:38:08 UTC ***

I just found a weird edge case with this patch applied.

In a room with me:
1. Type "clokep"
2. Press <tab> (you should now have "clokep: "
3. Press <backspace> (you should now have "clokep")
4. Press <backspace> (you still have "clokep"), I'd expect this to be "cloke".
Attachment #8354009 - Flags: review?(florian) → review-
Attached patch Patch (obsolete) — Splinter Review
*** Original post on bio 1881 as attmnt 2262 at 2013-03-09 17:36:00 UTC ***

Handles the edge case spotted by clokep (the additional backspace key press necessary was due to undoing a tab completion of zero length).
Attachment #8354027 - Flags: review?(florian)
Comment on attachment 8354009 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2245 at 2013-03-09 17:36:52 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8354009 - Attachment is obsolete: true
Attached patch Alternative patch (obsolete) — Splinter Review
*** Original post on bio 1881 as attmnt 2263 at 2013-03-09 17:45:00 UTC ***

Alternative way to organize exactly the same code.
Attachment #8354028 - Flags: review?(florian)
Comment on attachment 8354027 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2262 at 2013-03-09 18:02:21 UTC ***

First patch breaks e.g. character counts as it returns too early.
Attachment #8354027 - Attachment is obsolete: true
Attachment #8354027 - Flags: review?(florian)
*** Original post on bio 1881 at 2013-03-15 23:00:08 UTC ***

I tested the patch a bit.

Strange behavior:
1. Type "clokep<tab>", the result is: "clokep: "
2. Press <backspace>, the result is "clokep"
3. Press <tab> again, nothing changes (still "clokep", I would expect "clokep: ").
Attached patch PatchSplinter Review
*** Original post on bio 1881 as attmnt 2283 at 2013-03-16 15:34:00 UTC ***

Fixes that edge case. I can't see a more elegant way to do this.
Attachment #8354048 - Flags: review?(florian)
Comment on attachment 8354028 [details] [diff] [review]
Alternative patch

*** Original change on bio 1881 attmnt 2263 at 2013-03-16 15:34:48 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8354028 - Attachment is obsolete: true
Attachment #8354028 - Flags: review?(florian)
Comment on attachment 8354048 [details] [diff] [review]
Patch

*** Original change on bio 1881 attmnt 2283 at 2013-03-21 23:20:04 UTC ***

Thanks!
Attachment #8354048 - Flags: review?(florian) → review+
*** Original post on bio 1881 at 2013-03-22 10:20:58 UTC ***

http://hg.instantbird.org/instantbird/rev/c3afef072ba0

Can't wait to use this!
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.4
You need to log in before you can comment on or make changes to this bug.