[Tb] Ease of use

From: <jcherfas__AT__mac.com>
Date: Mon Mar 29 2004 - 08:53:48 EST

On 29 Mar 2004, at 15:41, Oliver Wrede wrote:

>
> Am 29.03.2004 um 14:32 schrieb jcherfas__AT__mac.com:
>
>> For lists, are you using TB's built in list-handling abilities? They
>> make life very simple, although there are problems with defining the
>> end of a list. I find I need at least one character, -- even &nbsp;
>> -- to ensure that a list closes correctly. If ytou don't like that,
>> it is also very easy to use macros to establish the lists and items
>> within that, which gives extra flexibility for putting lists into
>> different CSS classes.#
>
> I don't know what ?internal list handling capabilities? are.

Again, see the Release Notes. If you start a line with an asterisk *
you create a list with that line as the first item in the list. You can
nest lists by using two or more asterisks ** *** and so on.

A TB macro takes any number of arguments. But the arguments are defined
in the Macro tab of the Attributes window.
>
> listitem: <li>$1</li>
>
> But when I use this macro in this way:
>
> ^do(listitem,"1","2","3")^
>

That is because a single variable $1 is defined in the macro. You could
make the definition Listitem <li>$1</li ><li>$2</li ><li>$3</li > and
so but that would be pointless unless you know you will never have more
than that number of items.

You could, however, have

        ^do(listitem,Item 1)^
        ^do(listitem,Item 2)^
        ^do(listitem,Item 3)^

Which gives you more control if you want it. That would also be the
approach to defining different CSS classes for the items. You define a
Macro with two variables, one the listitem content and one the CSS
class of that item.

I agree that repeated calls seem wasteful, but it does give
flexibility. and the built-in lists handle things rather well too, so
there is actually no need to use a macro unless you want to.

Jeremy
Received on Mon Mar 29 08:53:48 2004

This archive was generated by hypermail 2.1.8 : Wed Dec 14 2005 - 10:45:20 EST