VM

fill quoted text in reply

Bug #586704 reported by mere user
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
VM
Fix Released
Low
Uday Reddy

Bug Description

Hi Uday, Given a plain text message with a text such as

1-Exact name as it appears in your photo id: Last, First Middle Others
2-Date of birth: Month/ Date /Year
3-Travel dates
4-Preferred travel times
5-Airport of departure
6-Seat preference
7-Frequent Flyer member number that we'll use if applicable.
8-Other requests

in the reply it looks like

 > 1-Exact name as it appears in your photo id: Last, First Middle
 > Others 2-Date of birth: Month/ Date /Year 3-Travel dates
 > 4-Preferred travel times 5-Airport of departure 6-Seat preference
 > 7-Frequent Flyer member number that we'll use if applicable.
 > 8-Other requests

it seems to me that it would be best to wrap long lines but not combine different lines as this more often than not leads to undesired results.

let me know if I should send a full report with my settings.

thanks as always, E

Tags: filling reply

Related branches

Revision history for this message
Uday Reddy (reddyuday) wrote : Re: [Bug 586704] [NEW] fill quoted text in reply

Hi Eli, This is a well-known problem with "filling" paragraphs, which
is why I discourage the use of filling. It is Emacs functionality,
and there is not much we can do from our end.

What I normally do is to first quote the text without filling and then
use filling for individual paragraphs manually whenever needed.

On the wonderworks web site, you will find Kyle Jones's filladapt.el
library, which is more intelligent than Emacs's adaptive-fill. You
might try loading that and see if it helps.

Cheers,
Uday

Revision history for this message
mere user (emacs-user) wrote :

Hey Uday, I once wrote a short code to fill one line at a time, which avoids this problem, and rob included it in vm. I suppose that's not an option anymore? what do you think of this approach? cheers, E

> Date: Fri, 28 May 2010 10:45:27 +0000
> From: <email address hidden>
> To: <email address hidden>
> Subject: Re: [Bug 586704] [NEW] fill quoted text in reply
>
> Hi Eli, This is a well-known problem with "filling" paragraphs, which
> is why I discourage the use of filling. It is Emacs functionality,
> and there is not much we can do from our end.
>
> What I normally do is to first quote the text without filling and then
> use filling for individual paragraphs manually whenever needed.
>
> On the wonderworks web site, you will find Kyle Jones's filladapt.el
> library, which is more intelligent than Emacs's adaptive-fill. You
> might try loading that and see if it helps.
>
> Cheers,
> Uday
>
> --
> fill quoted text in reply
> https://bugs.launchpad.net/bugs/586704
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in VM (View Mail) for Emacs: New
>
> Bug description:
> Hi Uday, Given a plain text message with a text such as
>
> 1-Exact name as it appears in your photo id: Last, First Middle Others
> 2-Date of birth: Month/ Date /Year
> 3-Travel dates
> 4-Preferred travel times
> 5-Airport of departure
> 6-Seat preference
> 7-Frequent Flyer member number that we'll use if applicable.
> 8-Other requests
>
> in the reply it looks like
>
> > 1-Exact name as it appears in your photo id: Last, First Middle
> > Others 2-Date of birth: Month/ Date /Year 3-Travel dates
> > 4-Preferred travel times 5-Airport of departure 6-Seat preference
> > 7-Frequent Flyer member number that we'll use if applicable.
> > 8-Other requests
>
> it seems to me that it would be best to wrap long lines but not combine different lines as this more often than not leads to undesired results.
>
> let me know if I should send a full report with my settings.
>
> thanks as always, E
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/vm/+bug/586704/+subscribe

_________________________________________________________________
Hotmail is redefining busy with tools for the New Busy. Get more from your inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_2

Revision history for this message
Uday Reddy (reddyuday) wrote :

> Hey Uday, I once wrote a short code to fill one line at a time, which avoids
> this problem, and rob included it in vm. I suppose that's not an option
> anymore? what do you think of this approach? cheers, E

If you can identify the revision number where this got included, I can
check to find out what happened to it.

In your bzr-enabled vm directory, do

  bzr log --include-merges >! bzr.log

That will produce a file called bzr.log, and you can look through it.

Cheers,
Uday

Revision history for this message
mere user (emacs-user) wrote :
Download full text (4.6 KiB)

Uday, here is what I can find. at the bottom here, some code I sent kyle (2002...) and his comments. I think this was eventually incorporated and completely modified by rob, but it might be the simplest way to explain the "idea"... I see in the bzr log that some bugs were fixed later, and the revision number and log entry are given below. does this help at all? E
------------------------------------------------------------revno: 83committer: Robert Widhopf timestamp: Thu 2005-10-27 01:06:32 +0000message: Allow vm-fill-paragraphs-containing-long-lines to be 'window-width and then fill the message based on the window-width. Before we had some obscure code taking the minimum of the various fill-column variables and window-width. The new longline.el support did not use this code an so window-width was not "honored" anymore. Thanks to Eli T. for reporting this.------------------------------------------------------------

To: Kyle Jones Subject: vm-fill-paragraphs-containing-long-linesX-Mailer: VM 7.07 under Emacs 21.3.50.1
sorry, I got it wrong below, the fix should have been:
 replace the following line in function vm-fill-paragraphs-containing-long-lines: (fill-paragraph nil)
with this or equivalent: (save-excursion (beginning-of-line) (setq fill_start (point)) (end-of-line) (setq fill_end (point)) (fill-region fill_start fill_end))
 > when I get messages with long lines, and the above parameter is set > to, say 72, vm fills paragraphs as requested. However, because such > messages don't necessarily use empty lines between paragraphs, > the paragraph filling actually messes the message up. What is needed > instead is that each line will be filled separately as a separate > paragraph. this is easily obtained, I believe, changing the function > vm-fill-paragraphs-containing-long-lines as follows: > > replace the line > (fill-paragraph nil) > > with this one: > (fill-region (beginning-of-line) (end-of-line)) > > and this seems to work when I try it. Hope this is useful, E >

From: Kyle Jones Subject: vm-fill-paragraphs-containing-long-linesDate: Sun, 28 Jul 2002 20:09:38 -0700
The reason VM doesn't fill pragraps one line at a time is thatfor somemessages it will produce the results like this--- onenormal lengthline followed by a very short line, foolowed by a normal lengthline, and so on.
Either Emacs' paragraph recogniition machinery needs to be improved orthe rest of the word needs to learn to use block paragraph style.I think the latter is coming along nicely, at least in the onlinerealms.

> Date: Fri, 28 May 2010 15:32:15 +0000
> From: u.s.reddy
> Subject: RE: [Bug 586704] [NEW] fill quoted text in reply
>
> > Hey Uday, I once wrote a short code to fill one line at a time, which avoids
> > this problem, and rob included it in vm. I suppose that's not an option
> > anymore? what do you think of this approach? cheers, E
>
> If you can identify the revision number where this got included, I can
> check to find out what happened to it.
>
> In your bzr-enabled vm directory, do
>
> bzr log --include-merges >! bzr.log
>
> That will produce a file called bzr.log, and you can look thro...

Read more...

Revision history for this message
Uday Reddy (reddyuday) wrote :

Uday, here is what I can find. at the bottom here, some code I sent kyle
(2002...) and his comments. I think this was eventually incorporated and
completely modified by rob, but it might be the simplest way to explain the
"idea"... I see in the bzr log that some bugs were fixed later, and the
revision number and log entry are given below. does this help at all? E
------------------------------------------------------------
revno: 83
committer: Robert Widhopf
timestamp: Thu 2005-10-27 01:06:32 +0000

message: Allow vm-fill-paragraphs-containing-long-lines to be
'window-width and then fill the message based on the window-width.
Before we had some obscure code taking the minimum of the various
fill-column variables and window-width. The new longline.el support
did not use this code an so window-width was not "honored" anymore.

Thanks to Eli T. for reporting this.

------------------------------------------------------------

To: Kyle Jones
Subject: vm-fill-paragraphs-containing-long-lines
X-Mailer: VM 7.07 under Emacs 21.3.50.1

sorry, I got it wrong below, the fix should have been:
 replace the following line in function
vm-fill-paragraphs-containing-long-lines:
    (fill-paragraph nil)
with this or equivalent:
        (save-excursion
    (beginning-of-line)
    (setq fill_start (point))
    (end-of-line)
    (setq fill_end (point))
    (fill-region fill_start fill_end))

> when I get messages with long lines, and the above parameter is set
> to, say 72, vm fills paragraphs as requested. However, because such
> messages don't necessarily use empty lines between paragraphs,
> the paragraph filling actually messes the message up. What is needed
> instead is that each line will be filled separately as a separate
> paragraph. this is easily obtained, I believe, changing the function
> vm-fill-paragraphs-containing-long-lines as follows:
> > replace the line
> (fill-paragraph nil)
> > with this one:
> (fill-region (beginning-of-line) (end-of-line))
> > and this seems to work when I try it. Hope this is useful, E
>

From: Kyle Jones
Subject: vm-fill-paragraphs-containing-long-lines
Date: Sun, 28 Jul 2002 20:09:38 -0700

The reason VM doesn't fill pragraps one line at a time is that for some
messages it will produce the results like this ---

one normal lengthline followed by a
very short line,
foolowed by a normal lengthline,
and so on.

Either Emacs' paragraph recogniition machinery needs to be improved orthe rest
of the word needs to learn to use block paragraph style.I think the latter is
coming along nicely, at least in the online realms.

Revision history for this message
Uday Reddy (reddyuday) wrote :

Dear Eli,

I don't see this kind of code introduced in revision 83. What is
there in the revision is a method of filling using the longlines.el
package. That is still included in VM, but you need to set
vm-word-wrap-paragraphs to t. Do you have this variable set?

Cheers,
Uday

Changed in vm:
status: New → Incomplete
importance: Undecided → Low
assignee: nobody → Uday Reddy (reddyuday)
tags: added: filling
Revision history for this message
mere user (emacs-user) wrote :

I tried setting it to t, but it still fills several lines together, leading to the behavior described originally... sorry I couldn't find the right revision. E

> I don't see this kind of code introduced in revision 83. What is
> there in the revision is a method of filling using the longlines.el
> package. That is still included in VM, but you need to set
> vm-word-wrap-paragraphs to t. Do you have this variable set?
>
> Cheers,
> Uday

_________________________________________________________________
The New Busy is not the old busy. Search, chat and e-mail from your inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_3

Uday Reddy (reddyuday)
Changed in vm:
status: Incomplete → Triaged
milestone: none → 8.1.91a
Revision history for this message
Uday Reddy (reddyuday) wrote :

Ok, I notice that I had turned off longlines.el in quoted text because it didn't work right. The problem is that it quotes lines before wrapping them, which results in the first line being quoted and the rest unquoted.

I will think about how to get it right, but meanwhile you are welcome to use the broken quotation mechanism. Please set the new variable vm-word-wrap-paragraphs-in-reply to t.

Cheers,
Uday

Changed in vm:
status: Triaged → In Progress
Revision history for this message
Uday Reddy (reddyuday) wrote :

mere user writes:

> I tried setting it to t, but it still fills several lines together,
> leading to the behavior described originally... sorry I couldn't
> find the right revision. E

Hi Eli,

I think you found the revision ok, but the fix that was implemented
was the use of the longlines package. That gave similar results to
what you had in mind.

I think the longlines package is working pretty well for message
display. But it is not working correctly for replies. It will need
more work. For the time being, your best bet is to set
vm-fill-long-lines-in-reply to nil, and use C-q manually to fill the
paragraphs that need filling.

Cheers,
Uday

Revision history for this message
mere user (emacs-user) wrote :

OK, will do, thanks! I didn't find a vm-word-wrap-paragraphs-in-reply variable in the recent development version, but I understand I don't need to look for it now. cheers, E

> Date: Mon, 31 May 2010 20:18:10 +0000
> From: <email address hidden>
> To: <email address hidden>
> Subject: RE: [Bug 586704] [NEW] fill quoted text in reply
>
> mere user writes:
>
> > I tried setting it to t, but it still fills several lines together,
> > leading to the behavior described originally... sorry I couldn't
> > find the right revision. E
>
> Hi Eli,
>
> I think you found the revision ok, but the fix that was implemented
> was the use of the longlines package. That gave similar results to
> what you had in mind.
>
> I think the longlines package is working pretty well for message
> display. But it is not working correctly for replies. It will need
> more work. For the time being, your best bet is to set
> vm-fill-long-lines-in-reply to nil, and use C-q manually to fill the
> paragraphs that need filling.
>
> Cheers,
> Uday
>
> --
> fill quoted text in reply
> https://bugs.launchpad.net/bugs/586704
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in VM (View Mail) for Emacs: In Progress
>
> Bug description:
> Hi Uday, Given a plain text message with a text such as
>
> 1-Exact name as it appears in your photo id: Last, First Middle Others
> 2-Date of birth: Month/ Date /Year
> 3-Travel dates
> 4-Preferred travel times
> 5-Airport of departure
> 6-Seat preference
> 7-Frequent Flyer member number that we'll use if applicable.
> 8-Other requests
>
> in the reply it looks like
>
> > 1-Exact name as it appears in your photo id: Last, First Middle
> > Others 2-Date of birth: Month/ Date /Year 3-Travel dates
> > 4-Preferred travel times 5-Airport of departure 6-Seat preference
> > 7-Frequent Flyer member number that we'll use if applicable.
> > 8-Other requests
>
> it seems to me that it would be best to wrap long lines but not combine different lines as this more often than not leads to undesired results.
>
> let me know if I should send a full report with my settings.
>
> thanks as always, E
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/vm/+bug/586704/+subscribe

_________________________________________________________________
The New Busy is not the too busy. Combine all your e-mail accounts with Hotmail.
http://www.windowslive.com/campaign/thenewbusy?tile=multiaccount&ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_4

Uday Reddy (reddyuday)
tags: added: reply
Revision history for this message
Uday Reddy (reddyuday) wrote :

Closing this bug report for now. Handling flowed text (bug 642058) will be a comprehensive solution to these problems.

Changed in vm:
status: In Progress → Fix Committed
milestone: 8.1.94a → 8.1.93a
Uday Reddy (reddyuday)
Changed in vm:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.