Closed
Bug 87321
Opened 24 years ago
Closed 22 years ago
[Access] Shift+Tab has duplicate behavior (event handled twice)
Categories
(MailNews Core :: Composition, defect, P2)
MailNews Core
Composition
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla1.2alpha
People
(Reporter: kmurray1115, Assigned: neil)
References
Details
Attachments
(1 file, 4 obsolete files)
5.99 KB,
patch
|
Brade
:
review+
sspitzer
:
superreview+
asa
:
approval1.3b+
|
Details | Diff | Splinter Review |
Using 0.9.1 (commercial build PR1) on Win2K:
In Mail compose, when editing a bulleted list item, and using shift+tab to
outdent, the caret does the following *two* things:
1. outdents the list item
2. jumps back to the subject field
Expected behavior:
When outdenting list items using Shift+tab, we should disable #2 above, but
contextually allow #1.
Updated•24 years ago
|
Component: Editor → Mail Window Front End
Product: Browser → MailNews
Comment 1•24 years ago
|
||
off to the mail team
Comment 3•24 years ago
|
||
OK, this makes HTML message compose completely suck for lists. There is,
however, a pretty simple workaround. Shift+Tab will outdent and focus subject
field. Hitting Tab will return focus to the last outdented position. So
Shift+tab then Tab gets you what you want.
Comment 4•24 years ago
|
||
An additional workaround is to hit Enter to outdent (instead of Shift+Tab).
Comment 5•24 years ago
|
||
not a stop ship bug for eMojo
Comment 6•24 years ago
|
||
moving to 0.9.7 and reassigning to varada.
Assignee: sspitzer → varada
Target Milestone: mozilla0.9.6 → mozilla0.9.7
Updated•24 years ago
|
Updated•24 years ago
|
Priority: -- → P2
This can be argued in another way - The user might want Shift-Tab to get from
the Message Text to the Subject line and not just do a outdent. It is confusing
to have one action do two things. Why dont we decide on one or the other and
give different keys for the two?
Status: NEW → ASSIGNED
Reporter | ||
Comment 8•23 years ago
|
||
Copying Aaronl and JGlick. Comments?
Comment 10•23 years ago
|
||
If the necessary Accessibility keys can be decided on then we can try to get the
fix in for this deadline. Can the folks in charge of that decide and agree on
the keys by today?
Comment 11•23 years ago
|
||
Editor folks need to agree and Aaron would need to suggest an available
accelerator.
Comment 12•23 years ago
|
||
So, is it correct that Accel+plus/minus are taken, as well as Accel+[/]?
Here are some not so perfect, but usable, possibilities:
1. change the behavior of Tab/Shift+tab only when text is selected and in an
editor control.
2. accel+9/0 -- these should be i18n, and on English keyboards at least, they're
the unshifted versions of ( and )
3. Alt+brackets or Alt+plus/minus
Reporter | ||
Comment 13•23 years ago
|
||
my original vote was for option #1. Still is.
Updated•23 years ago
|
Target Milestone: mozilla0.9.9 → mozilla1.0
Comment 14•23 years ago
|
||
I think we need to reach some sort of accord so that we can go ahead and start
implementing this.
Can anyone take the lead on this?
Jennifer?
Reporter | ||
Comment 15•23 years ago
|
||
At some point that pre-dates me, the editor team changed the indent/outdent
accelerators from ctrl+/ctrl-(4.x) to tab/shift+tab. That might have been Ok if
they didn't also add support for the same outcome via ctrl+]/ctrl+[ (try it,
they both work!). So, why don't we go back to ctrl+/ctrl- as the accelerators
for indent/outdent, and reserve tab/shift+tab for bouncing between fields?
If someone has a specific alternative recommendation, please state it soon so we
can progress. Varada, if you don't hear an alternative recommendation by EOD
Wednesday, 2/27, go ahead and implement the scenario I suggested.
Comment 16•23 years ago
|
||
Sounds good to me.
Comment 17•23 years ago
|
||
In Composer, here are some of the the current mappings:
control-+ (control-=) --> larger font size
control-- --> smaller font size
control-[ --> outdent
control-] --> indent
tab --> used to navigate table cells and indent list items
shift-tab --> used to navigate table cells and outdent list items
(notice we have problems here if you have a list in a table!)
Note: only tab and shift-tab are accessible on a European (or non-US) keyboard.
To me (a developer), the *big* issue here is that the event is handled twice
(not that it is getting handled by the wrong widget). That issue needs to be
investigated ASAP (who is ignoring flag, focus? editor?)
Next, if after the previous issue is addressed, there is still a problem
(editing widget handles tab instead of focus), then we'll probably need to
special case the tab and shift-tab key events in editor code to not do what they
do in Composer if certain conditions (flags?) are met.
By the way, in Netscape 6.2, Composer handled the tab (focus wasn't changed)
Summary: [Access] Shift+Tab has duplicate behavior → [Access] Shift+Tab has duplicate behavior (event handled twice)
Comment 18•23 years ago
|
||
Composer has bug 98624 to deal with the VERY messy issue of tab key behavior.
It is grossly overloaded. IMHO, using it to change focus from editing window
to other parts of Mail Composer UI is absolutely the LAST thing it should be
used for.
Comment 19•23 years ago
|
||
So where do go from here?
Reporter | ||
Comment 20•23 years ago
|
||
Given the info from brade, we should remove the ability to use tab to indent and
shift-tab to outdent. We already have an accelertator to do that (ctrl]/ctrl[).
Charlie, I understand your position, but we've made a broader decision to use
tab to move from element to element in the browser, and considerable work has
been done in the mail three pane window to tab from elememt to element there.
the natural extension of that in mail compose is to use tab to move from element
to element there and use ctrl+* within the message body to perform
indent/outdent operations.
Go for it varada.
KM
Comment 21•23 years ago
|
||
Kevin--I think that is entirely the wrong thing to do.
Control-[ and Control-] (as well as -,=, and +) are *not*
international-friendly. Those keybindings can't be used *AT ALL* on non-US
keyboards. We really should be moving away from *ALL* of those (at least until
we have configurable keybindings which won't happen for quite some time).
I think the right thing to do is find out why the event is getting handled
twice. Once we know what's going on there and address that issue, we can decide
how to proceed (possibly disabling tab key editing functions in mail compose only).
Honestly, I *really* believe that it is getting late to be changing *ANY* of
this stuff without introducing risks of huge regressions. This bug is more of
an RFE/enhancement than a bug. (Prior versions of Mail Compose only allowed for
users to reverse tab to get out of editing area.)
Varada--please let me know if you need help debugging the event stuff. If we
can't nail that it's pointless to try to fix this bug since someone else may
"fix" a bug and cause any band-aid fix we do to regress in a worse way.
Reporter | ||
Comment 22•23 years ago
|
||
Control-[ and Control-] (as well as -,=, and +) are *not*
international-friendly.
Somebody made the decision to support that without regard for international
then. So what's the low-cost and quick solution to this?
I think the right thing to do is find out why the event is getting handled
twice. Once we know what's going on there and address that issue, we can decide
how to proceed (possibly disabling tab key editing functions in mail compose only).
Sure - if it gets us where we need to be quickly, fine. But what we don't have
the luxury of doing is investigating this well outside the scope of 1.0. Absent
the ability to make real headway on solving the tough issues you cite above, we
should remove the redundancy.
Comment 23•23 years ago
|
||
i think that we could alter the behavior of ctrl+[shift+]arrows so that they
walked words and nodes. leaving [shift+]tab for indentation.
but i'm still trying to puzzle this through.
Comment 24•23 years ago
|
||
I don't see the "double-behavior" any more. Does anyone else?
Comment 25•23 years ago
|
||
nevermind; I was testing the wrong thing; I do see the problem
Comment 26•23 years ago
|
||
OK, I checked... Composer gets the event and handles it. It correctly sets the
"event handled" flag. The bug is coming later in focus when focus isn't paying
attention to the "handled" flag.
AaronL--do you know anything about this stuff or do we need to ship this bug off
to Chris Saari?
OS: Windows 2000 → All
Hardware: PC → All
Comment 27•23 years ago
|
||
removing myself from the cc list
Comment 28•23 years ago
|
||
Chris Saari--I think your expertise is needed here. Aaron can't help with this
bug right now. :-(
Varada--you should probably reassign this bug to Chris Saari or talk to him and
see if there is a better person to reassign this to.
Updated•23 years ago
|
Target Milestone: mozilla1.0 → mozilla1.2
Comment 30•23 years ago
|
||
Hi, what I would do is: a single Shift+Tab outdents the list. If, after that,
the next keystroke were another Shift+Tab, it would return to the Subject field.
I think it's better not to send the user away while he/she's typing the mail...
Comment 31•23 years ago
|
||
taking all of varada's bugs.
Assignee: varada → sspitzer
Status: ASSIGNED → NEW
Comment 32•22 years ago
|
||
*** Bug 84454 has been marked as a duplicate of this bug. ***
Comment 33•22 years ago
|
||
*** Bug 179250 has been marked as a duplicate of this bug. ***
Comment 34•22 years ago
|
||
*** Bug 187253 has been marked as a duplicate of this bug. ***
Comment 35•22 years ago
|
||
As a reminder,
bug 179250 (and possibly others) was about another case:
when editing a message without any list, Shift-Tab gets back to the subject
(:-)) but add a Tab in the message body (:-().
With obvious workaround of going back to the editor and removing the inserted
Tab (with Back, for example).
Assignee | ||
Comment 36•22 years ago
|
||
Assignee | ||
Comment 37•22 years ago
|
||
Assignee | ||
Updated•22 years ago
|
Attachment #112410 -
Flags: superreview?(alecf)
Attachment #112410 -
Flags: review?(ducarroz)
Comment 38•22 years ago
|
||
Comment on attachment 112410 [details] [diff] [review]
Proposed patch
I'll let sspitzer do the review as I am too busy right know...
Attachment #112410 -
Flags: review?(ducarroz) → review?(sspitzer)
Assignee | ||
Comment 39•22 years ago
|
||
brade thinks I need a couple of extra lines:
+ if (isShift)
+ return NS_OK; // don't type text for shift tabs
}
else if (keyCode == nsIDOMKeyEvent::DOM_VK_RETURN
|| keyCode == nsIDOMKeyEvent::DOM_VK_ENTER)
{
+ aKeyEvent->PreventDefault();
nsString empty;
if (isShift && !(mFlags&eEditorPlaintextMask))
{
@@ -1346,6 +1352,7 @@
}
else if (keyCode == nsIDOMKeyEvent::DOM_VK_ESCAPE)
{
+ aKeyEvent->PreventDefault();
// pass escape keypresses through as empty strings: needed forime support
nsString empty;
return TypedText(empty, eTypedText);
Assignee | ||
Comment 40•22 years ago
|
||
Fixing component.
Assignee: sspitzer → ducarroz
Component: Mail Window Front End → Composition
Comment 41•22 years ago
|
||
Comment on attachment 112410 [details] [diff] [review]
Proposed patch
let's get a review from brade first, then I can sr.
Attachment #112410 -
Flags: superreview?(sspitzer)
Attachment #112410 -
Flags: superreview?(alecf)
Attachment #112410 -
Flags: review?(sspitzer)
Attachment #112410 -
Flags: review?(brade)
Comment 43•22 years ago
|
||
Comment on attachment 112410 [details] [diff] [review]
Proposed patch
r=brade with the addition of the changes in comment 39
Attachment #112410 -
Flags: review?(brade) → review+
Comment 44•22 years ago
|
||
Comment on attachment 112410 [details] [diff] [review]
Proposed patch
sr=sspitzer, once you make brade's requested changes.
can you attach that final path to this bug, for completeness?
Attachment #112410 -
Flags: superreview?(sspitzer) → superreview+
Assignee | ||
Comment 45•22 years ago
|
||
Attachment #112409 -
Attachment is obsolete: true
Attachment #112410 -
Attachment is obsolete: true
Assignee | ||
Comment 46•22 years ago
|
||
Comment on attachment 112974 [details] [diff] [review]
Patch incorporating review comments for completeness
/me wishes there was an easier way to transfer r/sr
Attachment #112974 -
Flags: superreview?(sspitzer)
Attachment #112974 -
Flags: review?(brade)
Attachment #112974 -
Flags: approval1.3b?
Updated•22 years ago
|
Attachment #112974 -
Flags: review?(brade) → review+
Comment 47•22 years ago
|
||
Comment on attachment 112974 [details] [diff] [review]
Patch incorporating review comments for completeness
sr=sspitzer, assuming tab and shift tab still do the right thing in the other
scenarios.
Attachment #112974 -
Flags: superreview?(sspitzer) → superreview+
Comment 48•22 years ago
|
||
Neil--I have your patch in my current tree and I just ran into a problem:
inside a table in Composer, press tab
expectation: move to next table cell
actual result: 4 spaces inserted
I have lots of patches in my tree but yours seems like an obvious candidate for
this regression. Can you verify that tabbing in lists and tables works with
your patch?
Thanks!
Assignee | ||
Comment 49•22 years ago
|
||
You're right, when I split up the condition I missed off a ! by mistake...
Testing this, I found an issue with shift+tab in editor, so I added a fix.
Attachment #112974 -
Attachment is obsolete: true
Assignee | ||
Comment 50•22 years ago
|
||
Comment on attachment 113090 [details] [diff] [review]
Fixed missing !
The ! was missing on this line:
>+ if (!(mFlags & eEditorPlaintextMask)) {
Attachment #113090 -
Flags: superreview?(sspitzer)
Attachment #113090 -
Flags: review?(brade)
Assignee | ||
Updated•22 years ago
|
Attachment #112974 -
Flags: approval1.3b?
Comment 51•22 years ago
|
||
Comment on attachment 113090 [details] [diff] [review]
Fixed missing !
I know this was in the old code but I'd like to see it fixed for consistency.
For PRBool assignments, I prefer this format: PRBool isBlock = PR_FALSE;
instead of: PRBool isBlock (PR_FALSE);
What is the new change in editor.xul? What issue does that fix? I'd prefer
not to make that change unless it fixes a known issue.
Comment 52•22 years ago
|
||
waiting for r=brade before I sr.
Comment 53•22 years ago
|
||
Comment on attachment 113090 [details] [diff] [review]
Fixed missing !
r=brade IF the change to editor.xul include a check to only call
event.preventDefault() if the keypress is a tab. I'm worried about regressions
for other keys which we don't want to handle.
Attachment #113090 -
Flags: review?(brade) → review+
Assignee | ||
Comment 54•22 years ago
|
||
onkeypress="if (event.keyCode == KeyEvent.DOM_VK_TAB) event.preventDefault();"
Assignee | ||
Updated•22 years ago
|
Attachment #113392 -
Flags: superreview?(sspitzer)
Attachment #113392 -
Flags: review?(brade)
Assignee | ||
Comment 55•22 years ago
|
||
Comment on attachment 113090 [details] [diff] [review]
Fixed missing !
oops, forgot to mark obsolete
Attachment #113090 -
Attachment is obsolete: true
Attachment #113090 -
Flags: superreview?(sspitzer)
Comment 56•22 years ago
|
||
Comment on attachment 113392 [details] [diff] [review]
brade was right, I was too hasty :-[
r=brade
Attachment #113392 -
Flags: review?(brade) → review+
Comment 57•22 years ago
|
||
Comment on attachment 113392 [details] [diff] [review]
brade was right, I was too hasty :-[
sr=sspitzer
Attachment #113392 -
Flags: superreview?(sspitzer) → superreview+
Comment 58•22 years ago
|
||
Comment on attachment 113392 [details] [diff] [review]
brade was right, I was too hasty :-[
a=asa (on behalf of drivers) for checkin to 1.3beta.
Attachment #113392 -
Flags: approval1.3b+
Assignee | ||
Comment 59•22 years ago
|
||
Fix checked in.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Updated•21 years ago
|
Product: MailNews → Core
Updated•17 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•