← Prev in month ← Prev in thread

Re: DOCBOOK-APPS: Yet more confusion over strings and objects in Lisp.

From
"Logule, Qyo"
Date
2002-06-24T16:53:02+00:00
ID
Thread
Re: DOCBOOK-APPS: Yet more confusion over strings and objects in Lisp.
On 6/25/02 0:07, "Gre7g Luterman" <> wrote:
>> (make element gi: "DIV"
>>   attributes: '(("CLASS" "NAVHEADER"))
>>   (nav-context elemnode)
>>   (if (string=? (nav-context elemnode) "") (empty-sosofo)
>>     (make empty-element gi: "HR"
>>       attributes: (list
>>       (list "ALIGN" "LEFT")
>>       (list "WIDTH" %gentext-nav-tblwidth%)))))
> 
> Doesn't anyone know the correct Lisp code to do the above?
> 
> It can't be too much more sophisticated than the above, can it?

I'm not sure "correct Lisp code" means but you can shorten list expressions
by using quasiquotation.

(make element gi: "DIV"
  attributes: '(("CLASS" "NAVHEADER"))
  (nav-context elemnode)
  (if (string=? (nav-context elemnode) "") (empty-sosofo)
    (make empty-element gi: "HR"
      attributes: `(("ALIGN" "LEFT") ("WIDTH" ,%gentext-nav-tblwidth%)))))

Regards,
  Kogulé, Ryo
← Prev in month ← Prev in thread