Closed
Bug 611549
Opened 14 years ago
Closed 14 years ago
Web Console console input box should be LTR even for RTL locales
Categories
(DevTools :: General, defect, P1)
DevTools
General
Tracking
(blocking2.0 -)
RESOLVED
FIXED
Firefox 4.0b8
Tracking | Status | |
---|---|---|
blocking2.0 | --- | - |
People
(Reporter: pcwalton, Assigned: ehsan.akhgari)
References
Details
(Keywords: rtl)
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
Details | Diff | Splinter Review |
The input pointer needs to point the other way in RTL locales.
Reporter | ||
Updated•14 years ago
|
blocking2.0: --- → ?
Comment 1•14 years ago
|
||
I'm not sure I understand - the RTL caret indicator should be handled by the platform. Unless by "input pointer" you mean something else?
Reporter | ||
Comment 2•14 years ago
|
||
I mean the big > prompt in the input box (which is implemented as a background image IIRC). It should point to the left in RTL locales.
Comment 3•14 years ago
|
||
(In reply to comment #2)
> I mean the big > prompt in the input box (which is implemented as a background
> image IIRC). It should point to the left in RTL locales.
Is that how terminals are handled on Windows and Unix in RTL locales?
Reporter | ||
Comment 4•14 years ago
|
||
(In reply to comment #3)
> (In reply to comment #2)
> > I mean the big > prompt in the input box (which is implemented as a background
> > image IIRC). It should point to the left in RTL locales.
>
> Is that how terminals are handled on Windows and Unix in RTL locales?
Well, right now we have a ">" way over on the left, but text is entered right-to-left, since it's a plain old XUL textbox and inherits the default locale settings. I suppose another solution could be to force the textbox to left-to-right mode.
Comment 5•14 years ago
|
||
(In reply to comment #3)
ehsan:
Is that how any terminals (other than in Firefox) are handled on Windows and Unix in RTL locales?
Comment 6•14 years ago
|
||
It would be interesting to know how WebKit Inspector handles RTL for its console.
Comment 7•14 years ago
|
||
thinking about this further, the console is for entering JavaScript, not plain text. The "window" object is called window no matter which locale you're in.
We do want to do the right and consistent thing here, but I don't think it's clear cut what that is.
Comment 8•14 years ago
|
||
(In reply to comment #7)
> thinking about this further, the console is for entering JavaScript, not plain
> text. The "window" object is called window no matter which locale you're in.
>
> We do want to do the right and consistent thing here, but I don't think it's
> clear cut what that is.
I *think* this bug is INVALID as you are never going to manipulate the DOM or write JS in an RTL locale. I assume it will always be english.
Comment 9•14 years ago
|
||
(In reply to comment #8)
> I *think* this bug is INVALID as you are never going to manipulate the DOM or
> write JS in an RTL locale. I assume it will always be english.
If that's the case, then we should verify that the input box assumes LTR, even if the user's locale is RTL. Regardless, I think it would be worth investigating how other consoles behave.
Comment 10•14 years ago
|
||
if it's just a background image, we should be able to use a -moz-transform to flip the image in rtl environments.
Reporter | ||
Comment 11•14 years ago
|
||
(In reply to comment #8)
> (In reply to comment #7)
> > thinking about this further, the console is for entering JavaScript, not plain
> > text. The "window" object is called window no matter which locale you're in.
> >
> > We do want to do the right and consistent thing here, but I don't think it's
> > clear cut what that is.
>
> I *think* this bug is INVALID as you are never going to manipulate the DOM or
> write JS in an RTL locale. I assume it will always be english.
Unless I misunderstand what you're saying, I disagree. I think people in non-RTL locales will want to use the Web Console.
Comment 12•14 years ago
|
||
.js-term-input:-moz-locale-dir(rtl) {
background: url("chrome://global/skin/icons/commandline.png") 4px 2px, no-repeat;
-moz-transform: matrix(-1, 0, 0, 1, 0, 0);
}
Comment 13•14 years ago
|
||
I think we should really wait for Ehsan to get out of bed and give design input (i.e. answer comment 4), and then discuss technical solutions to get there.
Comment 14•14 years ago
|
||
(In reply to comment #11)
> Unless I misunderstand what you're saying, I disagree. I think people in
> non-RTL locales will want to use the Web Console.
Indeed you did misunderstand. I'm asking Ehsan to clarify if any of his Persian terminal (Mac Terminal, Linux Gnome Term, etc) is typed into RTL or LTR
Reporter | ||
Comment 15•14 years ago
|
||
(In reply to comment #14)
> (In reply to comment #11)
>
> > Unless I misunderstand what you're saying, I disagree. I think people in
> > non-RTL locales will want to use the Web Console.
>
> Indeed you did misunderstand. I'm asking Ehsan to clarify if any of his
> Persian terminal (Mac Terminal, Linux Gnome Term, etc) is typed into RTL or LTR
Well, either way, it's not an invalid bug: if people in RTL locales enter text in consoles from left to right, then we should hammer LTR mode into the text box.
Assignee | ||
Comment 16•14 years ago
|
||
Sorry for the delay here guys.
So, the data which goes into this text box is inherently LTR (all DOM object names are in latin alphabet), so what we need to do here is to treat the entire box as LTR (and don't flip the arrow image in RTL mode), similar to how we handle the location bar. Patch forthcoming.
Assignee | ||
Comment 17•14 years ago
|
||
Assignee: pwalton → ehsan
Attachment #490678 -
Flags: review?(ddahl)
Assignee | ||
Updated•14 years ago
|
Comment 18•14 years ago
|
||
(In reply to comment #17)
> Created attachment 490678 [details] [diff] [review]
> Patch (v1)
So, the direction will always be LTR? Just making sure I understand this.
Comment 19•14 years ago
|
||
(In reply to comment #18)
> (In reply to comment #17)
> > Created attachment 490678 [details] [diff] [review] [details]
> > Patch (v1)
>
> So, the direction will always be LTR? Just making sure I understand this.
yessir.
Adjusting summary.
Summary: Web Console console input box isn't localized for RTL → Web Console console input box should be LTR even for RTL locales
Comment 20•14 years ago
|
||
Comment on attachment 490678 [details] [diff] [review]
Patch (v1)
Feeback+, passing to gavin for a real r+
Attachment #490678 -
Flags: review?(gavin.sharp)
Attachment #490678 -
Flags: review?(ddahl)
Attachment #490678 -
Flags: review+
Assignee | ||
Comment 21•14 years ago
|
||
(In reply to comment #18)
> (In reply to comment #17)
> > Created attachment 490678 [details] [diff] [review]
> > Patch (v1)
>
> So, the direction will always be LTR? Just making sure I understand this.
Yes, that is correct.
Comment 22•14 years ago
|
||
thanks, ehsan!
Assignee | ||
Comment 23•14 years ago
|
||
Gavin: ping?
Comment 24•14 years ago
|
||
Comment on attachment 490678 [details] [diff] [review]
Patch (v1)
include a semi-colon?
Attachment #490678 -
Flags: review?(gavin.sharp)
Attachment #490678 -
Flags: review+
Attachment #490678 -
Flags: approval2.0+
Assignee | ||
Comment 26•14 years ago
|
||
Attachment #490678 -
Attachment is obsolete: true
Assignee | ||
Updated•14 years ago
|
Whiteboard: [needs landing]
Assignee | ||
Comment 27•14 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Whiteboard: [needs landing]
Target Milestone: --- → Firefox 4.0b8
Updated•14 years ago
|
blocking2.0: ? → -
Comment 28•14 years ago
|
||
CC-ing after the fact. This is fixed.
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•