DSSSL Library Reference: Part of the Modular DocBook Stylesheet distribution
Prev |  | Next

# parse-pi-attribute

## Name

parse-pi-attribute -- no documented purpose

## Synopsis

    (parse-pi-attribute pivalues #!optional (skip #f))

## Source Code

    (define (parse-pi-attribute pivalues #!optional (skip #f))
      (let* ((equalpos (string-index pivalues "="))
    	 (name     (substring pivalues 0 equalpos))
    	 (quotchar (substring pivalues (+ equalpos 1) (+ equalpos 2)))
    	 (rest     (substring pivalues
    			      (+ equalpos 2)
    			      (string-length pivalues)))
    	 (quotpos  (string-index rest quotchar))
    	 (value    (substring rest 0 quotpos))
    	 (morevals (strip (substring rest
    				     (+ quotpos 1)
    				     (string-length rest)))))
        (if skip
    	morevals
    	(list name value))))

Prev | Home | Next
string-index | Up | parse-skip-pi-attribute