Closed
Bug 130886
Opened 23 years ago
Closed 23 years ago
caret doesn't respect character position WRT certain <mo> entities
Categories
(Core :: MathML, defect)
Tracking
()
RESOLVED
FIXED
mozilla1.0
People
(Reporter: steve.swanson, Assigned: rbs)
References
()
Details
Attachments
(2 files)
|
3.77 KB,
patch
|
roc
:
review+
attinasi
:
superreview+
|
Details | Diff | Splinter Review |
|
2.51 KB,
patch
|
rbs
:
review+
asa
:
superreview+
asa
:
approval+
|
Details | Diff | Splinter Review |
(This is undoubtedly related to bug 129560, but will probably be easier to
track down.)
1. Turn on your caret when browsing with
user_pref("accessibility.browsewithcaret", true);
2. Open the following XHTML+MathML document
<?xml version="1.0"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN"
"http://www.w3.org/TR/MathML2/dtd/xhtml-math11-f.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<body>
First
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mo>∑</mo>
</math>
Second
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mrow>
<mtable>
<mtr>
<mtd> <mi>x</mi> </mtd>
<mtd> <mi>y</mi> </mtd>
</mtr>
<mtr>
<mtd> <mi>z</mi> </mtd>
<mtd> <mi>w</mi> </mtd>
</mtr>
</mtable>
</mrow>
</math>
Last.
</body>
</html>
3. Put the caret on the start of the line and arrow right. When you hit the
summation sign, note how the caret is below the glyph.
URL to testcase (same as in bug 130889):
http://bugzilla.mozilla.org/attachment.cgi?id=75116&action=view
Steve, do your bugzilla permissions allow making attachments? If so, it moe
convenient to attach the tescases directly.
I have updated your bugzilla privileges to allow you to edit all aspects of any
bug.
Since the MathMLChar doesn't handle all operations (e.g., caret), the patch is
sizing the inner child text frame so that when it takes over, its size isn't
too bad. With the patch the caret tracks stretchy chars, i.e., a small/normal
caret when next to normal chars or a matching tall caret when next to stretchy
chars.
[There is a separate glitch when moving the caret with the arrow key to/from an
<mo> frame. The caret goes off by one character caused by the way PeekOffset()
works. But users can move it back.]
Cc:ing roc/attinasi for r/sr
Targeting m1.0 since Steve wishes to use this for his JavaScripted MathML
editor.
Target Milestone: --- → mozilla1.0
Comment on attachment 75179 [details] [diff] [review]
proposed patch
r=roc+moz
Attachment #75179 -
Flags: review+
Comment 7•23 years ago
|
||
Comment on attachment 75179 [details] [diff] [review]
proposed patch
OK - sr=attinasi
Attachment #75179 -
Flags: superreview+
Comment 8•23 years ago
|
||
Comment on attachment 75183 [details] [diff] [review]
same patch with 'cvs diff -wu' for reading only
a=asa (on behalf of drivers) for checkin to the 1.0 trunk and bringing the r=
and sr= forward to the current patch.
Attachment #75183 -
Flags: superreview+
Attachment #75183 -
Flags: needs-work+
Attachment #75183 -
Flags: approval+
Comment on attachment 75183 [details] [diff] [review]
same patch with 'cvs diff -wu' for reading only
typo
Attachment #75183 -
Flags: needs-work+ → review+
| Assignee | ||
Comment 10•23 years ago
|
||
Patch checked in.
[Not 100% perfect since some MathML elements overlap a lot w.r.t. the CSS rects
that Gecko generally uses for hit testing.]
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•