(defun www-format-apply-value (object feature-name
format props value
- &optional uri-char uri-feature
+ &optional uri-object uri-feature
without-tags without-edit)
(let (ret)
(setq ret
((eq format 'wiki-text)
(if without-tags
(www-xml-format-list value)
- (www-format-eval-list value object feature-name nil uri-char
+ (www-format-eval-list value object feature-name nil uri-object
without-tags without-edit))
)
((eq format 'S-exp)
><input type=\"submit\" value=\"edit\" /></a>"
ret
chise-wiki-edit-url
- uri-char uri-feature format))))
+ uri-object uri-feature format))))
-(defun www-format-eval-feature-value (char
+(defun www-format-eval-feature-value (object
feature-name
- &optional format lang uri-char value
+ &optional format lang uri-object value
without-tags without-edit)
(unless value
- (setq value (www-get-feature-value char feature-name)))
+ (setq value (www-get-feature-value object feature-name)))
(unless format
(setq format (www-feature-value-format feature-name)))
(cond
((symbolp format)
(www-format-apply-value
- char feature-name
+ object feature-name
format nil value
- uri-char (www-uri-encode-feature-name feature-name)
+ uri-object (www-uri-encode-feature-name feature-name)
without-tags without-edit)
)
((consp format)
(cond ((null (cdr format))
(setq format (car format))
(www-format-apply-value
- char feature-name
+ object feature-name
(car format) (nth 1 format) value
- uri-char (www-uri-encode-feature-name feature-name)
+ uri-object (www-uri-encode-feature-name feature-name)
without-tags without-edit)
)
(t
- (www-format-eval-list format char feature-name lang uri-char
+ (www-format-eval-list format object feature-name lang uri-object
without-tags without-edit)
)))))
-(defun www-format-eval-unit (exp char feature-name
- &optional lang uri-char value
+(defun www-format-eval-unit (exp object feature-name
+ &optional lang uri-object value
without-tags without-edit)
(unless value
- (setq value (www-get-feature-value char feature-name)))
- (unless uri-char
- (setq uri-char (www-uri-encode-char char)))
+ (setq value (www-get-feature-value object feature-name)))
+ (unless uri-object
+ (setq uri-object (www-uri-encode-char object)))
(cond
((stringp exp) (www-format-encode-string exp))
((null exp) "")
(setq fn (intern fn)))
(setq domain (char-feature-name-domain feature-name))
(setq domain-fn (char-feature-name-at-domain fn domain))
- (if (setq ret (www-get-feature-value char domain-fn))
+ (if (setq ret (www-get-feature-value object domain-fn))
(setq feature-name domain-fn
value ret)
(setq feature-name fn
- value (www-get-feature-value char fn)))
+ value (www-get-feature-value object fn)))
(push feature-name chise-wiki-displayed-features)
))
(if (eq (car exp) 'value)
- (www-format-eval-feature-value char feature-name
+ (www-format-eval-feature-value object feature-name
(plist-get (nth 1 exp) :format)
- lang uri-char value
+ lang uri-object value
without-tags without-edit)
(www-format-apply-value
- char feature-name
+ object feature-name
(car exp) (nth 1 exp) value
- uri-char (www-uri-encode-feature-name feature-name)
+ uri-object (www-uri-encode-feature-name feature-name)
without-tags without-edit))
)
((eq (car exp) 'name)
(format "<a href=\"%s\">%s</a>"
(www-uri-make-feature-name-url
(www-uri-encode-feature-name feature-name)
- uri-char)
+ uri-object)
(www-format-feature-name feature-name lang))
)
)
(setq feature-name domain-fn)))
(www-uri-make-feature-name-url
(www-uri-encode-feature-name feature-name)
- uri-char)
+ uri-object)
)
((eq (car exp) 'domain-name)
(let ((domain (char-feature-name-domain feature-name)))
((eq (car exp) 'link)
(if without-tags
(www-format-eval-list (nthcdr 2 exp)
- char feature-name lang uri-char
+ object feature-name lang uri-object
without-tags without-edit)
(format "<a
href=\"%s\"
>%s</a
>"
(www-format-eval-list (plist-get (nth 1 exp) :ref)
- char feature-name lang uri-char
+ object feature-name lang uri-object
'without-tags 'without-edit)
(www-format-eval-list (nthcdr 2 exp)
- char feature-name lang uri-char
+ object feature-name lang uri-object
without-tags without-edit)))
)
(t
>%s</%s
>"
(car exp)
- (www-format-eval-list (nthcdr 2 exp) char feature-name
- lang uri-char
+ (www-format-eval-list (nthcdr 2 exp) object feature-name
+ lang uri-object
without-tags without-edit)
(car exp)))))))
-(defun www-format-eval-list (format-list char feature-name
- &optional lang uri-char
+(defun www-format-eval-list (format-list object feature-name
+ &optional lang uri-object
without-tags without-edit)
(if (consp format-list)
(mapconcat
(lambda (exp)
- (www-format-eval-unit exp char feature-name lang uri-char
+ (www-format-eval-unit exp object feature-name lang uri-object
nil without-tags without-edit))
format-list "")
- (www-format-eval-unit format-list char feature-name lang uri-char
+ (www-format-eval-unit format-list object feature-name lang uri-object
nil without-tags without-edit)))