Closed
Bug 1098150
Opened 10 years ago
Closed 9 years ago
Add a panel for basic mathematical constructions
Categories
(SeaMonkey :: Composer, defect)
SeaMonkey
Composer
Tracking
(seamonkey2.40 fixed)
RESOLVED
FIXED
seamonkey2.40
Tracking | Status | |
---|---|---|
seamonkey2.40 | --- | fixed |
People
(Reporter: fredw, Assigned: fredw)
References
(Blocks 1 open bug)
Details
Attachments
(2 files, 2 obsolete files)
11.16 KB,
patch
|
neil
:
review+
|
Details | Diff | Splinter Review |
11.41 KB,
image/png
|
Details |
Follow-up of bug 1077291. We should add another panel to enter basic mathematical constructions like "\frac{}{}", "\sqrt{}", etc
Comment 1•10 years ago
|
||
Is the product and component correct? Should it be SeaMonkey and Composer?
Flags: needinfo?(fred.wang)
Assignee | ||
Comment 2•10 years ago
|
||
Yes, sorry.
Component: MathML → Composer
Flags: needinfo?(fred.wang)
Product: Core → SeaMonkey
Assignee | ||
Comment 3•10 years ago
|
||
Here is a first patch showing the idea. I'm not exactly sure about the important constructions we want to present and how we will organize them (it's possible that we want several tabs).
Assignee: nobody → fred.wang
Attachment #8536006 -
Flags: feedback?(neil)
Comment 4•10 years ago
|
||
Comment on attachment 8536006 [details] [diff] [review]
Patch V1
I don't think the table ones work in the same tab as the others.
You might want to select the result of applying a unary function e.g. applying the boxed effect and then the slashed effect to the result.
Attachment #8536006 -
Flags: feedback?(neil) → feedback+
Assignee | ||
Updated•10 years ago
|
Assignee | ||
Comment 5•10 years ago
|
||
This addresses the two previous remarks.
There is one minor problem with the custom insertion code of insertLaTeXCommand: Undo/Redo does not work well. I tried a beginTransaction/endTransaction on input.editor but that did not help.
Attachment #8536006 -
Attachment is obsolete: true
Attachment #8560882 -
Flags: feedback?(neil)
Assignee | ||
Comment 6•10 years ago
|
||
@neil: any update on this?
Comment 7•9 years ago
|
||
Comment on attachment 8560882 [details] [diff] [review]
Patch V2
I probably got snowed under a flurry of requests or something, and it's just taken me far too long to work through them and think about catching up on some of my older requests. Sorry about that.
>+ // For a single math symbol, just use the insertText command.
>+ if (aButton.label) {
>+ gDialog.input.editor.QueryInterface(Components.interfaces.nsIPlaintextEditor).insertText(aButton.label);
>+ return;
>+ }
...
(In reply to Frédéric Wang from comment #5)
> There is one minor problem with the custom insertion code of
> insertLaTeXCommand: Undo/Redo does not work well. I tried a
> beginTransaction/endTransaction on input.editor but that did not help.
...
>+ // Update the input text and selection.
>+ gDialog.input.value =
>+ gDialog.input.value.substring(0, selectionStart) + latex +
>+ gDialog.input.value.substring(selectionEnd);
If you insertText(latex) instead (as per the first snippet) then that should just work.
>+ gDialog.input.selectionStart = selectionStart + latexNewStart;
>+ gDialog.input.selectionEnd = selectionStart + latexNewEnd;
Prefer .setSelectionRange()
Attachment #8560882 -
Flags: feedback?(neil) → feedback+
Assignee | ||
Comment 8•9 years ago
|
||
Thanks, that indeed seems to solve the undo/redo issue.
Attachment #8560882 -
Attachment is obsolete: true
Attachment #8657066 -
Flags: review?(neil)
Updated•9 years ago
|
Attachment #8657066 -
Flags: review?(neil) → review+
Assignee | ||
Updated•9 years ago
|
Keywords: checkin-needed
![]() |
||
Comment 9•9 years ago
|
||
Status: NEW → RESOLVED
Closed: 9 years ago
status-seamonkey2.40:
--- → fixed
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.40
Comment 10•9 years ago
|
||
We are talking about the 2 most left new TABs?
Assignee | ||
Comment 11•9 years ago
|
||
Yes, these tabs insert "complex" LaTeX constructions while the others insert only a single unicode character.
You need to log in
before you can comment on or make changes to this bug.
Description
•