[squeak-dev] The Inbox: Collections-eem.732.mcz -- HtmlReadWriter

Eliot Miranda eliot.miranda at gmail.com
Thu Feb 9 20:06:38 UTC 2017


On Thu, Feb 9, 2017 at 11:44 AM, Bert Freudenberg <bert at freudenbergs.de>
wrote:

> On Thu, Feb 9, 2017 at 8:16 PM, Eliot Miranda <eliot.miranda at gmail.com>
> wrote:
>
>> Tobias,
>>
>>   ignore my email.  I'm reviewing your code.  But I will say that adding
>> inst vars is making things more complicated too.  I added three methods to
>> achieve what I wanted and you've added 8 and an inst var ;-)
>>
>
> The problem with your indentation-based approach was that when just
> copying a whole method as HTML, it would insert a <pre> tag *after* the
> method pattern (because that was the first indented line). That's why Tobi
> added the TextDoit stuff, to specifically mark code ... It's still not
> ideal but we couldn't come up with a better way for unifying your
> blog-post-in-a-workspace with the regular just-copy-some-code. Ideas
> welcome :)
>

OK, accepted, but if one is considering simply a text with indentation, say

This is a non-indented line.
    This is an indented line.
This is another unindented line.

We need to generate

 This is a non-indented line.<br>
<pre>    This is an indented line.
</pre>
This is another unindented line.<br>

Right?  Right now there is no way to achieve this.  Adding a <code></code>
tag pair around the indented line is wrong.  Having to mark it as a doit is
wrong.  But the only way to preserve the indentation is to use <pre>.
That's what my changes (save arguably adding the closing </pre> in the
wrong place) achieved.  No need to mark things as dots.  One simply
indents, and whitespace is preserved.  Simple.


> - Bert -
>
>
>
>


-- 
_,,,^..^,,,_
best, Eliot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20170209/a2f3faf0/attachment.html>


More information about the Squeak-dev mailing list