Subject: Re: Indent problem From: Tony Graham <tgraham@xxxxxxxxxxxxxxxx> Date: Fri, 19 Feb 1999 12:43:16 -0500 (EST) |
At 16 Feb 1999 21:55 -0500, Didier PH Martin wrote: > Here is the problem: I want to display a SGML or XML document with markups > displayed with their properties and the content displayed in these markups. > Actually, The included script that does that but the problem is to indent > the markups to show the markups hierarchical relationships. Each markup is a > paragraph object. I need to set the "start-indent" property to a value that > reflect the markup position within the hierarchy. So that it would be > possible to see the markups hierarchy and their content. start-indent is an inherited characteristic, so merely increment the inherited start-indent. The following is untested, but it just changes your sosofo-append to a display-group with a specified start-indent characteristic (plus moves the specification for the paragraph flow object containing the children inside the test for must-omit-end-tag?): (default (make display-group start-indent: (+ (inherited-start-indent) 1pi) (make paragraph color: sea-green-color (literal "<" (gi (current-node)) (copy-attributes (current-node) (string-append " ")) ">")) (if (node-property 'must-omit-end-tag? (current-node)) (empty-sosofo) (sosofo-append (make paragraph lines: 'asis (process-children)) (make paragraph color: sea-green-color (literal "</" (gi (current-node)) ">")))))) Regards, Tony Graham ====================================================================== Tony Graham mailto:tgraham@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9632 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ====================================================================== DSSSList info and archive: http://www.mulberrytech.com/dsssl/dssslist
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Indent problem, Didier PH Martin | Thread | RE: Indent problem, Didier PH Martin |
Re: Postioning Graphics side by sid, Tony Graham | Date | Re: grouping elements, Tony Graham |
Month |