[Kde-pim] Towards better nested list handling in KMail

Stephen Kelly steveire at gmail.com
Sun Mar 16 12:59:50 GMT 2008


Hi,

This is another feature I've been working on for kjots.

KMEditor supports lists currently, but not nested lists. I've been
experiementing with adding a DoTheRightThing nested list feature in kjots
and kmail.

To try it out,

Apply the attached patch, and try out the new actions.

Here's what works and doesn't work using the attached screenshot:

1) Make a list with the list style drop down.
2) Increase the indent of some items. All numbers are recalculated
correctly.
3) Decrease the indent of some items to zero. This splits two lists.
4) Append or prepend adjactent items to the list. The bounding margin below
the list is preserved.
5) Change the type of list item of a certain level in a list.

~~ This is where things start to break.
6) Press enter after 'seven' and the bounding margin is not handled
correctly.
7) Take an item out of the list using the backspace key and the list is not
reformatted.

8) Doing some action on the list reformats it and fixes both of the above.
The user shouldn't have to do a workaround like that though.

In reality I think the QTextList needs some new API to add this stuff
cleanly and make the reformatList method unneccessary. I had a look at the
code and it looks like qt code is too complex for me at the moment to send
a patch to them. I'll fill a wishlist item with them, but as it won't be
high priority I'd prefer to send a patch with it.

Does anyone know enough about the QTextList section of Qt to give me a
kickstart on this?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kmailbetterlistsexperiment.patch
Type: text/x-diff
Size: 9441 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20080316/5913c451/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kmailbetterlists.png
Type: image/png
Size: 24584 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20080316/5913c451/attachment.png>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list