[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] Re: Future Worg publishing failure :)

From: Nicolas
Subject: [O] Re: Future Worg publishing failure :)
Date: Fri, 18 Mar 2011 16:42:49 +0100


Nick Dokos <address@hidden> writes:

>> The only solution I could think of is somewhere in the patchwork server
>> ("Auto-fill shouldn't insert new items").
> Are you saying that the patchwork server introduced this? Or that the
> patchwork server should solve it? In the case I stumbled upon (a Worg
> file), the patchwork server is nowhere in sight, I think: the change was
> (I'm guessing here) directly committed, so maybe the original writer had
> auto-fill turned on, but maybe not and just typed it that way. So
> neither the patchwork server nor making auto-fill smarter would provide
> a guaranteed solution. But maybe there is no such thing.

I'm not sure to understand. I mean that there is a patch waiting to be
processed in the patchwork server, that should get us as close to the
solution as I can think of (so, probably not very close).

It is true that the patch only solves the problem if it would happen
with auto-fill (or fill-paragraph). On the other hand, if the original
writer typed it that way, it's an user problem, and I don't think we
should add cruft to solve it.

> Perhaps a heuristic in html export to just take care of the error: if
> it looks like a numbered list item but there is no item body, bail and
> assume it's part of the text.

I introduced support for empty items on purpose. That would be
a regression.

> Or a combination of that together with the item number > 1. Would that
> work?

It would partly work. But:
- You would get false positives (rarely, but still),
- It wouldn't handle case when line, beside the bullet, isn't empty,
- It isn't only about HTML export, not even about export, as the same
  situation happens in Org buffers. 

Again, preventing the problem to happen automatically, i.e. without the
user knowing for sure about it, is taken care of by the patch (provided
it doesn't break anything else, thus its journey on the patchwork
server). In every other case, we can assume that the user knows (should
know) both Org syntax and what he is doing.

Now, for already introduced problems, it is indeed possible to build
a function using heuristics to scan files, and when matching, offer to
join lines and fill-paragraph. I don't think there are enough cases to
justify this, though.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]