Open
Bug 46993
Opened 24 years ago
Updated 2 years ago
Fake flowed for plaintext
Categories
(Thunderbird :: Mail Window Front End, enhancement)
Thunderbird
Mail Window Front End
Tracking
(Not tracked)
NEW
People
(Reporter: BenB, Unassigned)
Details
Attachments
(3 files, 1 obsolete file)
Most mails I recieve
- are (non-"format=flowed") plaintext
- contain text that flowed when it had been composed
- do not contain ascii-art
However, some of them contain fixed lines, i.e. linebreaks matter, e.g. source
code.
I would like these mails to be displayed as if they were format=flowed. I.e.
don't end the line on the screen, where it ends in the msg source, but continue
the paragraph until an empty line. It is an IMO logical extension to variable
width fonts and "wrap long lines". In other words, this feature is about
"wrapping all lines other than empty ones".
I consider this being more comfortable for reading, because I can adjust the
display width as I like, not at exactly 80 chars ("wrap long lines" doesn't
help, unless you adjust at exactly 40 chars).
I want to add a hidden pref, default off, to switch this on. Default off,
because it's only heuristic and is potentially destructive in the failure case.
Hidden, because this feature and its consequences are hard to communicate to
average users.
Implementation:
- Generally, output neither <br> nor <pre>.
- Insert <p>, if an empty line is detected.
- Address the "source-code problem" with a bit more heuristic:
- If a line contains less than n chars (with n ~ 60), insert <br>, if the next
line is empty.
I am working on it right now.
Reporter | ||
Updated•24 years ago
|
Severity: normal → enhancement
Status: NEW → ASSIGNED
Target Milestone: --- → M18
Reporter | ||
Comment 1•24 years ago
|
||
I have this working in my tree. Will attach patch after more testing/finetuning.
Reporter | ||
Comment 2•24 years ago
|
||
> if the next line is empty.
before each line until the next empty line.
Reporter | ||
Comment 3•24 years ago
|
||
Reporter | ||
Comment 4•24 years ago
|
||
Reporter | ||
Comment 5•24 years ago
|
||
Reporter | ||
Comment 6•24 years ago
|
||
Reporter | ||
Comment 7•24 years ago
|
||
Logic:
Added a bit more heuristics. Now works (mostly) fine for bugzilla spam and
supercite quotes (so, the example 3 screenshot is invalid).
Patch:
The majority of the new code is only executed, if the pref
"mail.all_plaintext_flowed" is enabled.
Also
- removed old ifdefs
- preallocate a reasonably sized string using |SetCapacity|, so it should run
faster, if the pref is off.
- fixed a leak in a failure case
Rich, can you review, please?
Design:
In the long term, this functionality should be added to the generic TXT->HTML
converter mozTXTToHTMLConv, but we'd have to use it as stream converter in
libmime then, which is non-trival.
Keywords: review
Reporter | ||
Comment 8•24 years ago
|
||
Need a bit more time. Sorry.
Hacking in some support for ASCII-art detecting (need to do most of it anyway
for this bug) - see bug 20195.
Keywords: review
Reporter | ||
Comment 9•24 years ago
|
||
Moving out to M20, out of pity for poor Netscape :). Hope, it won't rott.
Target Milestone: M18 → M20
Reporter | ||
Comment 10•24 years ago
|
||
Tell me, why didn't I attach a patch? Or at least make a local backup? I tried
to delete ~/.mozilla, but actually deleted ~/mozilla, the folder with all my
changes :-(((. All lost. Hurray.
Reporter | ||
Updated•24 years ago
|
Target Milestone: M20 → mozilla0.9.1
Reporter | ||
Comment 11•24 years ago
|
||
for mozTXTToHTMLConv
Component: MIME → Networking
Product: MailNews → Browser
Target Milestone: mozilla0.9.1 → ---
Reporter | ||
Comment 12•24 years ago
|
||
Changing personal priorities. Giving away most of my bugs :-( (reassigning to
default owner).
I will still track these bugs closely. If you need my input, feel free to ask me.
New owner: Please do *not* close these bugs (as WONTFIX or whatever you may
find) unless they are fixed. Rather, reassign to <nobody@mozilla.org>, if you
don't want to work on them.
Assignee: mozilla → neeti
Status: ASSIGNED → NEW
QA Contact: lchiang → tever
Comment 15•20 years ago
|
||
-> mailnews
Assignee: nobody → sspitzer
Component: Networking → Networking: MailNews General
Product: Browser → MailNews
QA Contact: benc → grylchan
Updated•20 years ago
|
Product: MailNews → Core
Comment 16•17 years ago
|
||
sorry for the spam. making bugzilla reflect reality as I'm not working on these bugs. filter on FOOBARCHEESE to remove these in bulk.
Assignee: sspitzer → nobody
Comment 17•16 years ago
|
||
Interesting.
You can Message -> Edit as New, and then Edit -> Rewrap.
Giving more visibility.
Component: MailNews: Networking → Mail Window Front End
Priority: P3 → --
Product: Core → Thunderbird
QA Contact: grylchan → front-end
Version: Trunk → unspecified
Reporter | ||
Comment 18•16 years ago
|
||
Joshua, this needs to be fixed in libmime, specifically mozTXTToHTMLConv, that's why it was Core.
Reporter | ||
Comment 19•16 years ago
|
||
eh, I mean mimetpla.cpp
Reporter | ||
Updated•16 years ago
|
Attachment #12386 -
Attachment is obsolete: true
Comment 20•16 years ago
|
||
Unless I'm mistaken, mimetpla.cpp != Networking,
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•