lout-users
[Top][All Lists]
Advanced

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

Re: Adding a custom symbol


From: Mark Summerfield
Subject: Re: Adding a custom symbol
Date: Mon, 16 Jan 2012 09:33:02 +0000

Hi Uwe,

On Fri, 13 Jan 2012 21:55:12 +0400
"Valeriy E. Ushakov" <address@hidden> wrote:
[snip]
> Ok, got around to actually test it:
> 
> @SysInclude { doc }
> 
> export @Monochrome
> def @MyOptions
>   named @Monochrome { No }
> {}
> 
> @Use { @MyOptions }
> 
> @Doc @Text @Begin
> @LP Monochrome is @Monochrome
> @End @Text
> 
> 
> $ lout -p -s override.lt | uniq
> 
>           Monochrome is No
> 
> $ lout -p -s --'@Monochrome{Yes}' override.lt | uniq
> 
>           Monochrome is Yes

I did this and put lines like this in my document:

    @CD @Monochrome @Case {
    Yes @Yield @IncludeGraphic{"images/quadratic2-linux-bw.eps.gz"}
    else @Yield @IncludeGraphic{"images/quadratic2-linux.eps.gz"}
    }

This gave no error messages but didn't work reliably.

So I changed them to this:

    @CD @Monochrome @Case {
    Yes @Yield @IncludeGraphic{"images/quadratic2-linux-bw.eps.gz"}
    No @Yield @IncludeGraphic{"images/quadratic2-linux.eps.gz"}
    }

This seems to work reliably but outputs some strange error messages (but
only in the --'@Monochrome{Yes}' case:

    replacing unknown @Case option ?? by Yes

Anyway, it works, so that you very much:-)

-- 
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
    C++, Python, Qt, PyQt - training and consultancy
        "Programming in Go" - ISBN 0321774639
            http://www.qtrac.eu/gobook.html



reply via email to

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