1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-14 09:39:42 +00:00
Commit Graph

54 Commits

Author SHA1 Message Date
Richard M. Stallman
882cb60d1a (xml-parse-file): Clean up, and use with-temp-buffer. 2006-07-24 18:02:10 +00:00
Thien-Thi Nguyen
aaef169dc6 Update years in copyright notice; nfc. 2006-02-06 15:23:23 +00:00
Mark A. Hershberger
39d58fc034 use provided patch 2006-02-02 01:07:11 +00:00
Mark A. Hershberger
5178753d31 fixing bug report 2006-02-02 01:02:31 +00:00
Mark A. Hershberger
aaaa8abbd0 xml.el fixes 2005-11-03 03:56:38 +00:00
Richard M. Stallman
0bf41002b4 (xml-att-def-re): Add defvar. 2005-08-09 02:52:15 +00:00
Thien-Thi Nguyen
0d30b33766 Update years in copyright notice; nfc. 2005-08-06 22:13:43 +00:00
Lute Kamstra
086add1519 Update FSF's address. 2005-07-04 23:32:44 +00:00
Mark A. Hershberger
23d519e49c eliminate use of inefficient match-data 2005-06-10 15:37:37 +00:00
Mark A. Hershberger
f8ab034e35 2005-05-26 Mark A. Hershberger <mah@everybody.org>
* xml.el (xml-substitute-special): Don't die for undefined xml
	entities.
2005-05-26 14:35:47 +00:00
Richard M. Stallman
5ed3235280 (xml-name-re, xml-entity-value-re): Add defvars. 2004-12-13 19:37:32 +00:00
Mark A. Hershberger
63b446bce0 Skip parameter entity declarations. 2004-12-02 07:48:25 +00:00
Mark A. Hershberger
27720433ac Change existence of &; to not-well-formed. 2004-12-02 07:19:03 +00:00
Mark A. Hershberger
7e0f112355 Ensure that validity messages only show when xml-validating-parser is set. 2004-12-02 06:53:43 +00:00
Mark A. Hershberger
ae02611069 2004-11-30 Mark A. Hershberger <mah@everybody.org>
* xml.el (xml-substitute-special): Fix validity error messages to
	actually show the unexpandable entity.  Added validity error if &
	isn't followed by an entity.
	(xml-parse-tag): Concatnate any string following the a
	<![CDATA[]]> section to the parsed CDATA.
2004-12-01 04:45:08 +00:00
Mark A. Hershberger
f0d494374f 2004-10-07 Mark A. Hershberger <mah@everybody.org>
* xml.el (xml-substitute-special): Limit handling of external
	entities.
2004-10-07 18:13:43 +00:00
John Paul Wallington
07f7e9aede (xml-parse-dtd): Fix `error' call. 2004-10-06 06:04:41 +00:00
Mark A. Hershberger
a3110b5ddc fix to for xml-substitute-special to produce a single string instead
of several if a substitution is made.
2004-10-06 00:58:29 +00:00
Mark A. Hershberger
6d12a4dfbc 2004-07-09 Mark A. Hershberger <mah@everybody.org>
* xml.el (xml-maybe-do-ns, xml-parse-tag): Produce elements in the
	form
	(("ns" . "element") (attr-list) children) instead of
	((:ns . "element") (attr-list) children) in order to reduce the
	number of symbols used.
	(xml-skip-dtd): Change to use xml-parse-dtd but set
	xml-validating-parsing to nil.
	(xml-parse-dtd): Parse entity deleclarations in DOCTYPEs.
	(xml-substitute-entity): Remove in favor of new entity substitution.
	(xml-substitute-special): Rewrite in to substitute complex
	entities from DOCTYPE declarations.
	(xml-parse-fragment): Parse fragments from entity deleclarations.
	(xml-parse-region, xml-parse-tag, xml-parse-attlist)
	(xml-parse-dtd, xml-substitute-special): Make validity checks
	conditioned on xml-validating-parser.  Add "Not Well Formed" to
	error messages about well-formedness.
2004-07-09 14:22:33 +00:00
Stefan Monnier
8a02e1933c Arch-tags shouldn't be outline headers. 2004-05-02 17:26:52 +00:00
Alex Schroeder
27240aa42f (xml-debug-print-internal): Don't add newline and
indentation to text nodes and write empty elements as empty tags
instead of opening and closing tags.
(xml-debug-print): Take optional indent-string argument.
(xml-print): Alias for xml-debug-print.
2004-04-30 20:00:19 +00:00
Stefan Monnier
a1dfa9a36d Doc fixes.
(xml-get-children): Only looks at sub-tags and ignore strings.
2004-04-16 22:46:26 +00:00
Stefan Monnier
43b5fd8135 (xml-parse-tag): Avoid overwriting node-name. 2004-04-16 22:26:53 +00:00
Stefan Monnier
c7f8d055af (xml-maybe-do-ns): New function to handle namespace
parsing of both attribute and element names.
(xml-ns-parse-ns-attrs, xml-ns-expand-el, xml-ns-expand-attr)
(xml-intern-attrlist): Remove in favor of xml-maybe-do-ns.
(xml-parse-tag): Update assumed namespaces.  Clean up namespace parsing.
(xml-parse-attlist): Make it do its own namespace parsing.
2004-04-14 18:36:14 +00:00
Stefan Monnier
2e9bdf15e6 (xml-get-attribute-or-nil): Simplify. 2004-03-02 21:45:06 +00:00
Eli Zaretskii
65f3f60016 (xml-get-attribute-or-nil): Doc fix. 2003-12-29 13:00:09 +00:00
Eli Zaretskii
5ebe044393 Fix previous change. Remove redundant trailing whitespace. 2003-12-29 12:35:35 +00:00
Eli Zaretskii
9bcd6a7e94 (xml-get-attribute-or-nil): New function, like
xml-get-attribute, but returns nil if the attribute was not found.
(xml-get-attribute): Converted to defsubst, uses
xml-get-attribute-or-nil.
2003-12-29 12:13:27 +00:00
Andreas Schwab
461f3ad082 (xml-parse-dtd): Fix misplaced paren. 2003-11-07 16:05:26 +00:00
Eli Zaretskii
3463899629 Allow comments following the top-level element.
Separate out namespace parsing into special functions.
Change namespace parsing to return ('ns-uri . "local-name")
instead of '{ns-uri}local-name.
2003-11-01 17:56:08 +00:00
Miles Bader
ab5796a9f9 Add arch taglines 2003-09-01 15:45:59 +00:00
Juanma Barranquero
2d42509a3a (xml-parse-tag): Namespace support.
(xml-parse-file): Namespace suport.
(xml-parse-region): Namespace suport.
2003-07-14 20:45:43 +00:00
Richard M. Stallman
720058f25b Record new maintainer. 2003-06-30 10:34:50 +00:00
Stefan Monnier
aba7ce7740 (xml-parse-tag): Return (foo nil) rather than (foo nil "")
for <foo/>, to make it behave like <foo></foo>.
2003-05-30 16:02:26 +00:00
John Paul Wallington
ab16145759 (xml-name-regexp): Wrap in `eval-and-compile'. 2003-05-19 17:45:27 +00:00
Dave Love
a98e819b26 Doc fixes.
(xml-parse-file, xml-parse-region): Autoload.
(xml-syntax-table, xml-name-regexp): New.
(xml-parse-region): Narrow to region, set syntax-table and
case-fold-search.  Reject fewer valid documents.
(xml-parse-tag): Remove arg END.  Callers changed.
(xml-parse-tag): Use skip-syntax-forward.  Use PARSE-DTD arg
properly.  Don't use buffer-substring-no-properties.  Don't bind
case-fold-search.  Fix syntax for empty elements.  Hoist consing
of end-of-tag regexp out of loop.
(xml-parse-attlist): Remove arg.  Callers changed.  Use
skip-syntax-forward, replace-regexp-in-string, forward-sexp.
Allow non-ASCII names.
(xml-skip-dtd): Remove arg.  Callers changed.  Change matching
code.
(xml-parse-dtd): Grok external DTDs.  Allow non-ASCII.  Don't use
match-string-no-properties.
(xml-ucs-to-string): Deleted.
(xml-substitute-entity): New.
(xml-substitute-special): Use it.
(xml-debug-print-internal): Simplify insertions.
(xml-parse-file): Avoid finding file in xml-mode.
2003-05-19 16:03:45 +00:00
Juanma Barranquero
f0ec17115f (xml-parse-attlist): typo in attribute parsing. 2003-03-20 18:01:58 +00:00
Juanma Barranquero
a158ff811f (xml-ucs-to-string): New function to convert Unicode codepoints to strings.
Uses decode-char (mule.el) if available.
(xml-parse-tag, xml-parse-attlist, xml-skip-dtd, xml-parse-dtd,
xml-parse-elem-type): Use ' \t\n\r' instead of '[:space:]'.
(xml-parse-attlist): Added attribute normalization.
(xml-parse-tag): Replace "\r\n" and "\r" with "\n".
2003-03-16 10:48:34 +00:00
Juanma Barranquero
35de62b82b (xml-skip-dtd): Fix parsing of DOCTYPE. 2003-03-11 21:59:49 +00:00
Juanma Barranquero
0fa6f70c59 (xml-parse-elem-type): Fix use of character constant. 2003-02-14 09:58:04 +00:00
Juanma Barranquero
adb266eff0 (xml-parse-tag, xml-parse-attlist, xml-skip-dtd, xml-parse-dtd,
xml-parse-elem-type): Be more flexible in recognizing empty elements.
2003-01-10 08:34:04 +00:00
Richard M. Stallman
ceabd2726c Comment change. 2003-01-06 01:10:25 +00:00
Thien-Thi Nguyen
524425ae58 (xml-substitute-special): Move "&amp;" -> "&" last. 2003-01-04 09:32:17 +00:00
Stefan Monnier
6a9cb3ba1f (xml-parse-tag): Allow spaces between / and >. 2002-12-16 17:04:58 +00:00
ShengHuo ZHU
01adac0d5d * xml.el (xml-parse-attlist): Accept empty strings.
From Max Froumentin <mf@w3.org>.
2002-03-05 21:44:01 +00:00
Stefan Monnier
971489ea00 Use setq rather than (set 'foo bar).
Use push+nreverse rather than append.
(xml-node-name, xml-node-attributes, xml-node-children):
Use defsubst rather than macros.
(xml-parse-region): Handle a nil return value from xml-parse-tag.
(xml-parse-tag): Don't skip white space.  Return nil for a comment.
Concat the two strings surrounding a comment into a single string.
2001-12-14 22:12:30 +00:00
Stefan Monnier
e54030af30 (xml-parse-tag): Use eq on char-after's return value. 2001-10-18 20:24:09 +00:00
Gerd Moellmann
f58176e6fe (xml-parse-attlist): Quotes around attributes must be the
same on each side.  Make sure we properly handle simple quotes.
From Daiki Ueno <ueno@unixuser.org>.
2001-09-24 09:26:53 +00:00
Pavel Janík
1cd7adc68a Emacs lisp coding convention fixes. 2001-07-14 11:21:08 +00:00
Gerd Moellmann
1300e2720b (xml-parse-tag): The document may contain invalid characters.
From ShengHuo ZHU  <zsh@cs.rochester.edu>
2001-05-31 08:17:31 +00:00