1 ;; -*- coding: utf-8-mcs-er -*-
2 (require 'cwiki-format)
3 (require 'char-db-json)
4 (require 'concord-turtle-dump)
6 (defvar chise-wiki-view-url "view.cgi")
7 (defvar chise-wiki-edit-url "edit.cgi")
8 (defvar chise-wiki-add-url "add.cgi")
10 (defun www-edit-display-feature-input-box (char feature-name
11 &optional format value)
13 (setq char (or (concord-decode-object '=id char 'feature)
14 (concord-make-object 'feature char))))
16 (setq format 'default))
18 (setq value (www-get-feature-value char feature-name)))
19 (if (and (symbolp value)
20 (eq format 'wiki-text))
21 (setq value (list (list value))))
23 (format "<p><input type=\"text\" name=\"feature-name\"
24 size=\"32\" maxlength=\"256\" value=\"%s\">"
26 (princ (encode-coding-string " \u2190 " 'utf-8-mcs-er))
28 (format "%s<input type=\"text\" name=\"%s\"
29 size=\"64\" maxlength=\"256\" value=\"%s\">
30 <input type=\"submit\" value=\"set\" /></p>
32 (if (or (eq format 'HEX)(eq format 'hex))
36 (mapconcat (lambda (c)
38 ;; ((eq c ?<) "&lt;")
39 ;; ((eq c ?>) "&gt;")
40 ((eq c ?\u0022) """)
43 (est-format-list value format nil nil " ")
47 (defun www-display-object-desc (genre uri-object &optional uri-feature-name
50 uri-feature-name-to-edit editing-format)
53 (let ((object (www-uri-decode-object genre uri-object))
54 (est-eval-list-feature-items-limit est-eval-list-feature-items-limit)
55 (est-view-url-prefix (if uri-feature-name
58 (rdf-uri-object (if est-hide-cgi-mode
59 (if (string-match "=" uri-object)
61 (est-uri-decode-feature-name-body
62 (substring uri-object 0 (match-beginning 0)))
64 (est-uri-decode-feature-name-body
65 (substring uri-object (match-end 0))))
67 feature-name-to-display feature-name-to-edit
68 base-name-to-edit metadata-name-to-edit
70 logical-feature chise-wiki-displayed-features
72 GlyphWiki-id HNG-card HNG-card-id HNG-card-cobj ret object-spec
74 item-code page char-num glyph-image-id
75 width height image-cobj base-image x y w h)
79 (setq without-header t))
81 (when uri-feature-name-to-edit
82 (setq feature-name-to-edit
83 (www-uri-decode-feature-name uri-feature-name-to-edit))
84 (setq ret (symbol-name feature-name-to-edit))
85 (if (string-match "\\*" ret)
86 (setq base-name-to-edit (intern
87 (substring ret 0 (match-beginning 0)))
88 metadata-name-to-edit (intern
89 (substring ret (match-end 0))))
90 (setq base-name-to-edit feature-name-to-edit))
91 (when (stringp editing-format)
92 (setq editing-format (intern editing-format))))
93 (when (and (eq genre 'character)
94 (= (length uri-object) 1))
95 (setq uri-object (www-uri-encode-object object)))
100 <style type=\"text/css\">
103 .ids { vertical-align: middle; font-size: 40px; line-height: 100%%; }
104 a { text-decoration: none; }
105 .ids a { color: black; }
106 ul { margin: 0 0; color: black; }
107 li { margin: 0 0 0 2em; }
108 .feature-name { font-family: sans-serif; font-weight: bold; }
109 .feature-name a { color: black; }
113 display: inline-block;
114 border-bottom: 1px dotted black;
117 .tooltip .tooltiptext {
123 background-color: black;
133 .value .image-list img { height: 320px; vertical-align: top; }
135 .list .tooltip:hover .tooltiptext {
142 src=\"http://hng.chise.org/openseadragon/openseadragon.min.js\"></script>
144 <title>EsT %s = %s</title>
147 (decode-uri-string uri-object 'utf-8-mcs-er))
150 (when (eq genre 'character)
151 (dolist (feature (char-feature-property '$object 'additional-features))
152 (mount-char-attribute-table
153 (char-feature-name-at-domain feature '$rev=latest))))
157 (if est-hide-cgi-mode
158 "<div style=\"text-align:right;\">
159 <a href=\"../../edit/view.cgi?%s=%s\">
160 <input type=\"submit\" value=\"Edit\" />
162 "<div style=\"text-align:right;\">
163 <a href=\"edit/view.cgi?%s=%s\">
164 <input type=\"submit\" value=\"Edit\" />
166 genre rdf-uri-object)
168 "<div style=\"text-align:right;\">
169 <a href=\"../view/%s/%s\">
170 <input type=\"submit\" value=\"Simple\" />
173 (if (string-match ":" uri-object)
175 (est-uri-encode-feature-name-body
176 (substring uri-object 0 (match-beginning 0)))
178 (est-uri-encode-feature-name-body
179 (substring uri-object (match-end 0))))))))
181 (format "<input type=\"submit\" value=\"New Account\" />
182 <a href=\"./%s/index.ttl\"><input type=\"submit\" value=\"RDF (Turtle)\" /></a>
183 <a href=\"http://www.chise.org/est/rdf.cgi?%s=%s\">
184 <input type=\"submit\" value=\"XML (old RDF)\" />
190 (if (eq genre 'character)
192 <a href=\"/est/view/%s/%s/data.json\">
193 <input type=\"submit\" value=\"JSON\" />
196 (if (and (or (char-feature object '->HNG@CN/manuscript)
197 (char-feature object '->HNG@CN/printed)
198 (char-feature object '->HNG@JP/manuscript)
199 (char-feature object '->HNG@JP/printed)
200 (char-feature object '->HNG@KR)
201 (char-feature object '->HNG@MISC))
202 (setq ucs (char-ucs object))
203 (setq ret (decode-char '=ucs ucs))
205 (if (setq ucs (get-char-attribute
207 (decode-char '=ucs ucs)
210 <a href=\"https://search.hng-data.org/search/%s\">
211 <input type=\"submit\" value=\"HNG-data\" />
213 (www-uri-encode-object ret))
216 (when (setq parents (www-get-feature-value object '<-denotational))
217 (if (characterp parents)
218 (setq parents (list parents)))
219 (princ (format "<p>%s %s</p>\n<hr>\n"
220 (www-format-value-as-char-list parents)
221 (www-format-feature-name '->denotational lang))))
222 (when (setq parents (www-get-feature-value object '<-subsumptive))
223 (if (characterp parents)
224 (setq parents (list parents)))
225 (princ (format "<p>%s %s</p>\n<hr>\n"
226 (www-format-value-as-char-list parents)
227 (www-format-feature-name '->subsumptive lang))))
228 (when (eq genre 'character)
229 (setq GlyphWiki-id (char-GlyphWiki-id object)))
231 ((eq genre 'image-resource)
233 (if (setq ret (concord-object-get object '=location@iiif))
235 (car (concord-object-get object '<-image-segment)))
236 (format "<a href=\"%s...$.zoom-xywh=%d,%d,%d,%d\"
237 ><img alt=\"%s\" src=\"%s\" /></a>"
238 (www-uri-encode-object base-image)
239 (concord-object-get object 'image-offset-x)
240 (concord-object-get object 'image-offset-y)
241 (concord-object-get object 'image-width)
242 (concord-object-get object 'image-height)
244 (if (and image-selection
245 (string-match "\\([0-9]+\\),\\([0-9]+\\),\\([0-9]+\\),\\([0-9]+\\)" image-selection))
247 (setq x (string-to-int (match-string 1 image-selection))
248 y (string-to-int (match-string 2 image-selection))
249 w (string-to-int (match-string 3 image-selection))
250 h (string-to-int (match-string 4 image-selection)))
252 (concord-object-get object 'image-width)))
253 ;; (setq height (float
254 ;; (concord-object-get object 'image-height)))
255 (format "<div id=\"openseadragon1\"
256 style=\"width: 800px; height: 600px;\"></div>
258 <script type=\"text/javascript\">
260 viewer = OpenSeadragon({
261 id: \"openseadragon1\",
262 prefixUrl: \"http://hng.chise.org/openseadragon/images/\",
263 preserveViewport: true,
268 tileSources: [ \"%s/info.json\" ]
270 viewer.addHandler('open', function () {
271 var newBounds = new OpenSeadragon.Rect( %f, %f, %f, %f, 0 );
272 viewer.viewport.fitBounds(newBounds, true);
273 viewer.viewport.applyConstraints();
283 (format "<div id=\"openseadragon1\"
284 style=\"width: 800px; height: 600px;\"></div>
286 <script type=\"text/javascript\">
288 id: \"openseadragon1\",
289 prefixUrl: \"http://hng.chise.org/openseadragon/images/\",
290 preserveViewport: true,
295 tileSources: [ \"%s/info.json\" ]
300 (setq ret (concord-object-get object '=location))
301 (format "<img alt=\"%s\" src=\"%s\" />"
304 ((or (and (eq genre 'glyph-image)
306 (car (concord-object-get object '->image-resource))))
307 (and (eq genre 'character)
308 (setq ret (www-format-encode-string
309 (est-format-object object 'readable)))
311 "<img alt=\"SW-JIGUGE\\([45]\\)-\\([0-9][0-9][0-9]\\)\\([0-9][0-9]\\)"
313 (setq item-code (string-to-int (match-string 1 ret))
314 page (string-to-int (match-string 2 ret))
315 char-num (string-to-int (match-string 3 ret)))
317 (cond ((eq item-code 4)
319 (format "zinbun/toho/A024/A024%04d/char=%d"
320 (+ page 18) char-num))
324 (format "zinbun/toho/A020/A020%04d/char=%d"
325 (+ page 16) char-num))
328 (concord-decode-object '=id glyph-image-id 'glyph-image))
330 (car (concord-object-get image-cobj '->image-resource)))
332 (if (and (setq ret (concord-object-get image-cobj '=location@iiif))
334 (car (concord-object-get image-cobj '<-image-segment))))
336 (format "<a href=\"../image-resource/%s...$.zoom-xywh=%d,%d,%d,%d\"
337 ><img alt=\"%s\" src=\"%s\" /></a>"
338 (www-uri-encode-object base-image)
339 (concord-object-get image-cobj 'image-offset-x)
340 (concord-object-get image-cobj 'image-offset-y)
341 (concord-object-get image-cobj 'image-width)
342 (concord-object-get image-cobj 'image-height)
344 (setq ret (concord-object-get image-cobj '=location))
345 (princ (format "<img alt=\"%s\" src=\"%s\" />"
348 ((and (eq genre 'hng-card)
349 (setq ret (concord-object-get object '=hng-card))
350 (setq ret (symbol-name ret))
351 (string-match "\\([0-9]+\\)-\\([0-9]+\\)" ret))
354 "<img alt=\"HNG-card:%s\"
355 src=\"http://hng.chise.org/images/HNG/%03d/card/%04d.jpg\"
356 style=\"height: 480px;\" />"
358 (string-to-int (match-string 1 ret))
359 (string-to-int (match-string 2 ret))))
362 (car (concord-object-get object '->image-resource)))
363 (format "<a href=\"../image-resource/%s\">%s</a>"
364 (www-uri-encode-object image-cobj)
369 (setq ret (www-format-encode-string
370 (est-format-object object 'readable)))
372 "<img alt=\"HNG\\([0-9]+\\)-\\([0-9]+\\)[a-z]?\"" ret)
376 (string-to-int (match-string 1 ret))
377 (string-to-int (match-string 2 ret)))))
379 (format "hng-card/rep.id=%s" HNG-card-id)))
381 (format "<h%d>%s%s</h%d>\n"
385 (format "<a href=\"%s\">%s</a>"
386 ;; (if est-hide-cgi-mode
387 ;; "<a href=\"../%s\">%s</a>"
388 ;; "<a href=\"%s\">%s</a>")
389 (www-uri-make-object-url object uri-object)
394 "<a href=\"../%s\">%s</a>"
400 " <a href=\"http://glyphwiki.org/wiki/%s\"><img alt=\"%s\" src=\"http://glyphwiki.org/glyph/%s.50px.png\" /></a>"
402 GlyphWiki-id GlyphWiki-id)
408 (when feature-name-to-edit
409 (princ "<form action=\"set.cgi\" method=\"GET\">\n")
411 (encode-coding-string
412 (format "<p>(%s : <input type=\"text\" name=\"%s\"
413 size=\"30\" maxlength=\"30\" value=\"%s\">)</p>
416 (decode-uri-string uri-object 'utf-8-mcs-er))
418 (when (and HNG-card-id
419 (eq genre 'character)
421 (concord-decode-object
424 (put-char-attribute object 'sources@HNG/card (list HNG-card-cobj))
425 (cond ((setq ret (concord-object-get
427 '->glyph-image@zinbun/takuhon))
428 (put-char-attribute object 'sources@zinbun/takuhon ret)
430 ((setq ret (concord-object-get
432 '->glyph-image@gallica))
433 (put-char-attribute object 'sources@gallica ret)
439 (setq feature-name-to-display
440 (www-uri-decode-feature-name uri-feature-name))
441 (setq est-eval-list-feature-items-limit nil)
443 (cons feature-name-to-display
444 (if (eq genre 'character)
445 (get-char-attribute object feature-name-to-display)
446 (concord-object-get object feature-name-to-display)))))
448 (if (eq genre 'character)
449 (char-attribute-alist object)
450 (concord-object-spec object)))))
451 (when feature-name-to-edit
452 (unless (assq base-name-to-edit object-spec)
453 (setq object-spec (cons (cons base-name-to-edit nil)
455 (dolist (cell (sort object-spec
457 (char-attribute-name<
458 (char-feature-name-sans-versions (car a))
459 (char-feature-name-sans-versions (car b))))))
460 (setq logical-feature (char-feature-name-sans-versions (car cell)))
461 (unless (memq logical-feature chise-wiki-displayed-features)
462 (push logical-feature chise-wiki-displayed-features)
464 ((and feature-name-to-edit
465 (eq (car cell) feature-name-to-edit))
466 (www-edit-display-feature-input-box
467 object feature-name-to-edit editing-format)
472 "<div class=\"feature\" style=\"line-height:150%\">\n"
475 (www-format-eval-list
476 (www-feature-format logical-feature)
478 logical-feature ; (car cell)
483 (format " <a href=\"%s?%s=%s&feature=%s&format=wiki-text\"
484 ><input type=\"submit\" value=\"note\" /></a>"
487 (www-format-encode-string uri-object)
488 (www-format-encode-string
489 (www-uri-encode-feature-name
490 (intern (format "%s*note"
491 logical-feature ; (car cell)
493 (when (and feature-name-to-edit
494 (eq base-name-to-edit (car cell)) metadata-name-to-edit)
497 (www-edit-display-feature-input-box
498 object feature-name-to-edit editing-format)
511 (when feature-name-to-edit
515 (format "<a href=\"%s?%s=%s\"
516 ><input type=\"submit\" value=\"add feature\" /></a>
520 (www-format-encode-string uri-object))))
525 (when (eq genre 'character)
526 (let ((object-str (est-format-object object))
527 encoded-object-for-form)
529 "<form action=\"http://www.chise.org/ids-find\">\n")
530 (princ (www-format-encode-string object-str))
531 (setq encoded-object-for-form
533 (insert (encode-coding-string object-str 'utf-8-jp-er))
534 (goto-char (point-min))
535 (while (search-forward ">-" nil t)
536 (replace-match "&GT-" t t)
541 " <input type=\"text\" name=\"components\"
542 size=\"30\" maxlength=\"30\" value=\"%s\" />"
543 encoded-object-for-form))
545 (www-format-encode-string
546 "を\u542Bむ\u6F22\u5B57を\u63A2す"))
547 (princ " <input type=\"submit\" value=\"search\" />\n")
551 "<form action=\"http://www.chise.org/hng-ids-find\">\n")
552 (princ (www-format-encode-string object-str))
556 " <input type=\"text\" name=\"components\"
557 size=\"30\" maxlength=\"30\" value=\"%s\" />"
558 encoded-object-for-form))
560 (www-format-encode-string
561 "を\u542Bむ HNG の\u6F22\u5B57を\u63A2す"))
562 (princ " <input type=\"submit\" value=\"search\" />\n")
571 (defun www-display-feature-desc (uri-feature-name genre uri-object
572 &optional lang simple)
573 (let ((rdf-uri-object (if est-hide-cgi-mode
575 (string-match "=" uri-object)
577 (est-uri-decode-feature-name-body
578 (substring uri-object 0 (match-beginning 0)))
580 (est-uri-decode-feature-name-body
581 (substring uri-object (match-end 0)))))
583 (feature-name (www-uri-decode-feature-name uri-feature-name))
584 (name@lang (intern (format "name@%s" lang))))
586 (encode-coding-string
588 <title>EsT feature: %s</title>
596 (if est-hide-cgi-mode
597 "<div style=\"text-align:right;\">
598 <a href=\"../../../edit/view.cgi?feature=%s&%s=%s\">
599 <input type=\"submit\" value=\"Edit\" />
601 <input type=\"submit\" value=\"New Account\" />
604 "<div style=\"text-align:right;\">
605 <a href=\"edit/view.cgi?feature=%s&%s=%s\">
606 <input type=\"submit\" value=\"Edit\" />
608 <input type=\"submit\" value=\"New Account\" />
611 uri-feature-name genre rdf-uri-object)
613 "<div style=\"text-align:right;\">
614 <a href=\"../view/feature/%s&%s/%s\">
615 <input type=\"submit\" value=\"Simple\" />
619 uri-feature-name genre uri-object)))
621 (format "<h1>%s</h1>\n"
622 (www-format-encode-string
623 (symbol-name feature-name))))
624 (princ (format "<p>name : %s "
625 (or (www-format-feature-name feature-name) "")))
629 " <a href=\"%s?feature=%s&property=name&format=string&%s=%s\">"
634 (princ "<input type=\"submit\" value=\"edit\" /></a>\n"))
639 (www-format-encode-string
642 (or (char-feature-property feature-name name@lang) ""))))
646 " <a href=\"%s?feature=%s&property=%s&format=string&%s=%s\">"
652 (princ "<input type=\"submit\" value=\"edit\" /></a>\n"))
654 (www-html-display-paragraph
656 (or (www-feature-type feature-name)
657 ;; (char-feature-property feature-name 'type)
659 (princ (format "<p>value-format : %s "
662 (or (www-feature-value-format feature-name)
670 " <a href=\"%s?feature=%s&property=value-format&format=wiki-text&%s=%s\"
676 (princ "<input type=\"submit\" value=\"edit\" /></a>\n"))
679 (princ (format "<p>value-presentation-format : %s "
681 nil 'value-presentation-format
682 (or (www-feature-value-format feature-name)
690 " <a href=\"%s?feature=%s&property=value-presentation-format&format=wiki-text&%s=%s\"
696 (princ "<input type=\"submit\" value=\"edit\" /></a>\n"))
699 (princ "<p>format : ")
700 (www-html-display-text
701 (decode-coding-string
703 (www-feature-format feature-name))
708 " <a href=\"%s?feature=%s&property=format&format=wiki-text&%s=%s\"
714 (princ "<input type=\"submit\" value=\"edit\" /></a>\n"))
717 (www-html-display-paragraph
718 (format "description : %s"
719 (or (decode-coding-string
720 (or (char-feature-property feature-name 'description)
725 (www-html-display-paragraph
726 (format "description@%s : %s"
728 (or (char-feature-property
730 (intern (format "description@%s" lang)))
734 (defun www-batch-view ()
735 (setq terminal-coding-system 'binary)
737 (let* ((target (pop command-line-args-left))
738 (user (pop command-line-args-left))
739 (accept-language (pop command-line-args-left))
740 (mode (intern (pop command-line-args-left)))
745 (car (split-string accept-language ","))
749 (princ "Content-Type: text/html; charset=UTF-8
751 <!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"
752 \"http://www.w3.org/TR/html4/loose.dtd\">
757 (when (string-match "^char=\\(&[^&;]+;\\)" target)
758 (setq ret (match-end 0))
761 (www-uri-encode-object
762 (www-uri-decode-object
763 'character (match-string 1 target)))
764 (substring target ret))))
766 (mapcar (lambda (cell)
767 (if (string-match "=" cell)
769 (setq genre (substring cell 0 (match-beginning 0))
770 ret (substring cell (match-end 0)))
773 (decode-uri-string genre 'utf-8-mcs-er))
775 (list (decode-uri-string cell 'utf-8-mcs-er))))
776 (split-string target "&")))
777 (setq ret (car target))
778 (cond ((eq (car ret) 'char)
779 (www-display-object-desc
780 'character (cdr ret) (cdr (assq 'feature target))
785 ((eq (car ret) 'feature)
786 (www-display-feature-desc
787 (decode-uri-string (cdr ret) 'utf-8-mcs-er)
794 (www-display-object-desc
795 (car ret) (cdr ret) (cdr (assq 'feature target))
802 (princ (format "mode=%S\n" mode))
803 (princ (format "user=%s\n" user))
804 ;; (princ (format "local user=%s\n" (user-login-name)))
805 (princ (format "lang=%S\n" lang))
806 (princ (encode-coding-string (emacs-version) 'utf-8-jp-er))
808 ;; (princ xemacs-chise-version)
814 (princ (format "%S" err)))
817 (defun www-batch-view-smart ()
818 (setq debug-on-error t)
819 (setq terminal-coding-system 'binary)
821 (let* ((est-hide-cgi-mode t)
822 (target (pop command-line-args-left))
823 (user (pop command-line-args-left))
824 (accept-language (pop command-line-args-left))
825 (mode (intern (pop command-line-args-left)))
830 (car (split-string accept-language ","))
833 ret genre feature obj-url json turtle obj)
837 ((string-match "/data\\.json$" target)
839 target (substring target 0 (match-beginning 0)))
841 ((string-match "/index\\.ttl$" target)
843 target (substring target 0 (match-beginning 0)))
845 (when (string-match "^char/\\(&[^&;]+;\\)" target)
846 (setq ret (match-end 0))
849 (www-uri-encode-object
850 (www-uri-decode-object
851 'character (match-string 1 target)))
852 (substring target ret))))
856 (if (string-match "/" cell)
858 (setq genre (substring cell 0 (match-beginning 0))
859 ret (substring cell (match-end 0)))
861 (intern (decode-uri-string genre 'utf-8-mcs-er))
863 ((string-match "/feature=" ret)
864 (list (substring ret 0 (match-beginning 0))
865 (substring ret (match-end 0)))
867 ((string-match "...$.zoom-xywh=" ret)
868 (list (substring ret 0 (match-beginning 0))
870 (substring ret (match-end 0)))
874 (list (decode-uri-string cell 'utf-8-mcs-er)))
875 ;; (setq ret (split-string cell "/"))
877 ;; (decode-uri-string (car ret) 'utf-8-mcs-er))
880 (split-string target "&")))
881 (setq ret (car target))
883 (princ "Content-Type: text/turtle; charset=UTF-8
888 (princ "Content-Type: application/json; charset=UTF-8
893 (princ "Content-Type: text/html; charset=UTF-8
895 <!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"
896 \"http://www.w3.org/TR/html4/loose.dtd\">
900 ;; (princ (format "<p>%S, %S, %S</p>"
901 ;; (car ret)(nth 1 ret)(nth 2 ret)))
902 ;; (princ (format "// %S %S\n" ret json))
905 (setq obj (www-uri-decode-object (car ret)(nth 1 ret)))
906 (concord-turtle-insert-char-data obj)
907 (goto-char (point-min))
908 (concord-turtle-insert-prefix)
910 (encode-coding-region
911 (point-min)(point-max)
912 char-db-file-coding-system)
913 (princ (buffer-string)))
915 ((or (eq (car ret) 'char)
916 (eq (car ret) 'character))
918 (setq obj (www-uri-decode-object
919 (car ret)(nth 1 ret)))
922 ;; (princ (encode-coding-string
923 ;; (format "// %S\n" obj)
924 ;; char-db-file-coding-system))
925 (char-db-json-char-data-with-variant obj 'printable)
926 (encode-coding-region
927 (point-min)(point-max)
928 char-db-file-coding-system)
929 (princ (buffer-string))
931 (www-display-object-desc
932 'character (nth 1 ret) (nth 2 ret)
937 ((eq (car ret) 'feature)
938 (www-display-feature-desc
939 (decode-uri-string (nth 1 ret) 'utf-8-mcs-er)
941 (nth 1 (nth 1 target))
945 ;; ((eq (car ret) 'image-resource)
947 ;; ;; ((string-match "^\\.iiif=" (nth 1 ret))
948 ;; ;; (setq obj-url (decode-uri-string
949 ;; ;; (substring (nth 1 ret) (match-end 0))
950 ;; ;; 'utf-8-mcs-er))
951 ;; ;; (setq obj (concord-images-add-iiif obj-url))
952 ;; ;; (www-display-object-desc
953 ;; ;; 'image-resource
954 ;; ;; (www-uri-encode-object obj)
957 ;; ;; (eq mode 'simple))
960 ;; (princ (nth 1 ret))
961 ;; (www-display-object-desc
962 ;; 'image-resource (nth 1 ret) (nth 2 ret)
964 ;; (eq mode 'simple))
968 (www-display-object-desc
969 (car ret) (nth 1 ret) (nth 2 ret)
975 (unless (or json turtle)
977 (princ (format "mode=%S\n" mode))
978 (princ (format "user=%s\n" user))
979 ;; (princ (format "local user=%s\n" (user-login-name)))
980 (princ (format "lang=%S\n" lang))
981 (princ (encode-coding-string (emacs-version) 'utf-8-jp-er))
983 ;; (princ xemacs-chise-version)
990 (princ (format "%S" err)))
993 (provide 'cwiki-view)