TaskList & Tasks textile formatting

Project:ProjectPier
Version:0.8.5.x-dev
Component:User interface
Category:bug report
Priority:normal
Assigned:andypost
Status:patch - code needs review
Description

When tasks are displayed, they lose formatting (paragraphs and line breaks). Oddly, if you click on the "edit" button you can see the text coreectly formatted.

Seriously. This was something Illija was strangely confident people wouldn't mind putting up with. I'm totally for making the formatting in tasks match the formatting elsewhere.

Right now tasks seems to be formatted using the clean() function which converts html characters like < into escapes like &gt;

Title:Tasks loose formatting» Tasks lose formatting
Version:»
Status:new» open - needs more info

The Textile text should no longer display HTML entities literally like that. Also, there's been a suggestion about also adding automatic URL recognition in, which seems like a good idea (see http://projectpier.org/node/538).

Most of the time when I'm entering tasks, I want line breaks since tasks often aren't just one-liners. Clients entering information also use line breaks so I don't understand why tasks are not "supposed" to have formatting. I think any place you're asking for input using a textarea, proper output formatting should be implemented.

I think a simple, robust function to handle this is the "autop" function from Wordpress. It automatically inserts line breaks and converts double line breaks to paragraphs. It will also recognize block level html so it won't improperly wrap something in a paragraph.

More info can be found at Matt's page:
http://ma.tt/scripts/autop/

Here's a link to the Wordpress source code that contains the latest, most debugged version. It's the 3rd function down:
http://trac.wordpress.org/browser/trunk/wp-includes/formatting.php

The function is available for public use, so there shouldn't be a problem copying it verbatim in ProjectPier. A comment attribution can always be added.

Can you please provide an example of a task you are trying enter?

Status:open - needs more info» closed - fixed

Textile formatting should now be working as expected as of r148.

Status:closed - fixed» closed - by issue author

Automatically closed -- issue fixed for two weeks with no activity.

Title:Tasks lose formatting» TaskList & Tasks textile formatting
Version:» 0.8.5.x-dev
Assigned to:Visitor» andypost
Status:closed - by issue author» patch - code needs review

I've reopen this with patch. Suppose textile is good enough to user it on tasks and last list description.

Idea from http://www.activecollab.com/forums/post/7019/#post7019

There's a change in css style 'desc' which is Italic style changed to 'taskListText' for better view!

AttachmentSize
taskList_task_textile.patch4.21 KB

style change can be replaced in theme task_list.css for

div.taskList .desc {
....some theme-style
  font-style:normal; /* add this */
}

so patch without css-rule change

PS all themes should be updated

AttachmentSize
taskList_task_textile2.patch4.21 KB