diff options
| -rw-r--r-- | lisp/textmodes/sgml-mode.el | 82 |
1 files changed, 74 insertions, 8 deletions
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index e6eb060d8a4..0937c00fbd0 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el | |||
| @@ -1779,11 +1779,12 @@ This takes effect when first loading the library.") | |||
| 1779 | "Value of `sgml-display-text' for HTML mode.") | 1779 | "Value of `sgml-display-text' for HTML mode.") |
| 1780 | 1780 | ||
| 1781 | 1781 | ||
| 1782 | ;; should code exactly HTML 3 here when that is finished | ||
| 1783 | (defvar html-tag-alist | 1782 | (defvar html-tag-alist |
| 1784 | (let* ((1-7 '(("1") ("2") ("3") ("4") ("5") ("6") ("7"))) | 1783 | (let* ((1-7 '(("1") ("2") ("3") ("4") ("5") ("6") ("7"))) |
| 1785 | (1-9 `(,@1-7 ("8") ("9"))) | 1784 | (1-9 `(,@1-7 ("8") ("9"))) |
| 1786 | (align '(("align" ("left") ("center") ("right")))) | 1785 | (align '(("align" ("left") ("center") ("right")))) |
| 1786 | (ialign '(("align" ("top") ("middle") ("bottom") ("left") | ||
| 1787 | ("right")))) | ||
| 1787 | (valign '(("top") ("middle") ("bottom") ("baseline"))) | 1788 | (valign '(("top") ("middle") ("bottom") ("baseline"))) |
| 1788 | (rel '(("next") ("previous") ("parent") ("subdocument") ("made"))) | 1789 | (rel '(("next") ("previous") ("parent") ("subdocument") ("made"))) |
| 1789 | (href '("href" ("ftp:") ("file:") ("finger:") ("gopher:") ("http:") | 1790 | (href '("href" ("ftp:") ("file:") ("finger:") ("gopher:") ("http:") |
| @@ -1796,16 +1797,26 @@ This takes effect when first loading the library.") | |||
| 1796 | ("title"))) | 1797 | ("title"))) |
| 1797 | (list '((nil \n ("List item: " "<li>" str | 1798 | (list '((nil \n ("List item: " "<li>" str |
| 1798 | (if sgml-xml-mode "</li>") \n)))) | 1799 | (if sgml-xml-mode "</li>") \n)))) |
| 1800 | (shape '(("shape" ("rect") ("circle") ("poly") ("default")))) | ||
| 1799 | (cell `(t | 1801 | (cell `(t |
| 1800 | ,@align | 1802 | ,@align |
| 1801 | ("valign" ,@valign) | 1803 | ("valign" ,@valign) |
| 1802 | ("colspan" ,@1-9) | 1804 | ("colspan" ,@1-9) |
| 1803 | ("rowspan" ,@1-9) | 1805 | ("rowspan" ,@1-9) |
| 1804 | ("nowrap" t)))) | 1806 | ("nowrap" t))) |
| 1807 | (cellhalign '(("align" ("left") ("center") ("right") | ||
| 1808 | ("justify") ("char")) | ||
| 1809 | ("char") ("charoff"))) | ||
| 1810 | (cellvalign '(("valign" ("top") ("middle") ("bottom") | ||
| 1811 | ("baseline"))))) | ||
| 1805 | ;; put ,-expressions first, else byte-compile chokes (as of V19.29) | 1812 | ;; put ,-expressions first, else byte-compile chokes (as of V19.29) |
| 1806 | ;; and like this it's more efficient anyway | 1813 | ;; and like this it's more efficient anyway |
| 1807 | `(("a" ,name ,@link) | 1814 | `(("a" ,name ,@link) |
| 1815 | ("area" t ,@shape ("coords") ("href") ("nohref" "nohref") ("alt") | ||
| 1816 | ("tabindex") ("accesskey") ("onfocus") ("onblur")) | ||
| 1808 | ("base" t ,@href) | 1817 | ("base" t ,@href) |
| 1818 | ("col" t ,@cellhalign ,@cellvalign ("span") ("width")) | ||
| 1819 | ("colgroup" \n ,@cellhalign ,@cellvalign ("span") ("width")) | ||
| 1809 | ("dir" ,@list) | 1820 | ("dir" ,@list) |
| 1810 | ("font" nil "size" ("-1") ("+1") ("-2") ("+2") ,@1-7) | 1821 | ("font" nil "size" ("-1") ("+1") ("-2") ("+2") ,@1-7) |
| 1811 | ("form" (\n _ \n "<input type=\"submit\" value=\"\"" | 1822 | ("form" (\n _ \n "<input type=\"submit\" value=\"\"" |
| @@ -1818,6 +1829,9 @@ This takes effect when first loading the library.") | |||
| 1818 | ("h5" ,@align) | 1829 | ("h5" ,@align) |
| 1819 | ("h6" ,@align) | 1830 | ("h6" ,@align) |
| 1820 | ("hr" t ("size" ,@1-9) ("width") ("noshade" t) ,@align) | 1831 | ("hr" t ("size" ,@1-9) ("width") ("noshade" t) ,@align) |
| 1832 | ("iframe" \n ,@ialign ("longdesc") ("name") ("src") | ||
| 1833 | ("frameborder" ("1") ("0")) ("marginwidth") ("marginheight") | ||
| 1834 | ("scrolling" ("yes") ("no") ("auto")) ("height") ("width")) | ||
| 1821 | ("img" t ("align" ,@valign ("texttop") ("absmiddle") ("absbottom")) | 1835 | ("img" t ("align" ,@valign ("texttop") ("absmiddle") ("absbottom")) |
| 1822 | ("src") ("alt") ("width" "1") ("height" "1") | 1836 | ("src") ("alt") ("width" "1") ("height" "1") |
| 1823 | ("border" "1") ("vspace" "1") ("hspace" "1") ("ismap" t)) | 1837 | ("border" "1") ("vspace" "1") ("hspace" "1") ("ismap" t)) |
| @@ -1839,14 +1853,17 @@ This takes effect when first loading the library.") | |||
| 1839 | "<tr><" str ?> _ | 1853 | "<tr><" str ?> _ |
| 1840 | (if sgml-xml-mode (concat "<" str "></tr>")) \n)) | 1854 | (if sgml-xml-mode (concat "<" str "></tr>")) \n)) |
| 1841 | ("border" t ,@1-9) ("width" "10") ("cellpadding")) | 1855 | ("border" t ,@1-9) ("width" "10") ("cellpadding")) |
| 1856 | ("tbody" \n ,@cellhalign ,@cellvalign) | ||
| 1842 | ("td" ,@cell) | 1857 | ("td" ,@cell) |
| 1843 | ("textarea" ,name ("rows" ,@1-9) ("cols" ,@1-9)) | 1858 | ("textarea" ,name ("rows" ,@1-9) ("cols" ,@1-9)) |
| 1859 | ("tfoot" \n ,@cellhalign ,@cellvalign) | ||
| 1844 | ("th" ,@cell) | 1860 | ("th" ,@cell) |
| 1861 | ("thead" \n ,@cellhalign ,@cellvalign) | ||
| 1845 | ("ul" ,@list ("type" ("disc") ("circle") ("square"))) | 1862 | ("ul" ,@list ("type" ("disc") ("circle") ("square"))) |
| 1846 | 1863 | ||
| 1847 | ,@sgml-tag-alist | 1864 | ,@sgml-tag-alist |
| 1848 | 1865 | ||
| 1849 | ("abbrev") | 1866 | ("abbr") |
| 1850 | ("acronym") | 1867 | ("acronym") |
| 1851 | ("address") | 1868 | ("address") |
| 1852 | ("array" (nil \n | 1869 | ("array" (nil \n |
| @@ -1856,19 +1873,24 @@ This takes effect when first loading the library.") | |||
| 1856 | ("aside" \n) | 1873 | ("aside" \n) |
| 1857 | ("au") | 1874 | ("au") |
| 1858 | ("b") | 1875 | ("b") |
| 1876 | ("bdo" nil ("lang") ("dir" ("ltr") ("rtl"))) | ||
| 1859 | ("big") | 1877 | ("big") |
| 1860 | ("blink") | 1878 | ("blink") |
| 1861 | ("blockquote" \n) | 1879 | ("blockquote" \n ("cite")) |
| 1862 | ("body" \n ("background" ".gif") ("bgcolor" "#") ("text" "#") | 1880 | ("body" \n ("background" ".gif") ("bgcolor" "#") ("text" "#") |
| 1863 | ("link" "#") ("alink" "#") ("vlink" "#")) | 1881 | ("link" "#") ("alink" "#") ("vlink" "#")) |
| 1864 | ("box" (nil _ "<over>" _ (if sgml-xml-mode "</over>"))) | 1882 | ("box" (nil _ "<over>" _ (if sgml-xml-mode "</over>"))) |
| 1865 | ("br" t ("clear" ("left") ("right"))) | 1883 | ("br" t ("clear" ("left") ("right"))) |
| 1884 | ("button" nil ("name") ("value") | ||
| 1885 | ("type" ("submit") ("reset") ("button")) | ||
| 1886 | ("disabled" "disabled") | ||
| 1887 | ("tabindex") ("accesskey") ("onfocus") ("onblur")) | ||
| 1866 | ("caption" ("valign" ("top") ("bottom"))) | 1888 | ("caption" ("valign" ("top") ("bottom"))) |
| 1867 | ("center" \n) | 1889 | ("center" \n) |
| 1868 | ("cite") | 1890 | ("cite") |
| 1869 | ("code" \n) | 1891 | ("code" \n) |
| 1870 | ("dd" ,(not sgml-xml-mode)) | 1892 | ("dd" ,(not sgml-xml-mode)) |
| 1871 | ("del") | 1893 | ("del" nil ("cite") ("datetime")) |
| 1872 | ("dfn") | 1894 | ("dfn") |
| 1873 | ("div") | 1895 | ("div") |
| 1874 | ("dl" (nil \n | 1896 | ("dl" (nil \n |
| @@ -1878,8 +1900,13 @@ This takes effect when first loading the library.") | |||
| 1878 | ("dt" (t _ (if sgml-xml-mode "</dt>") | 1900 | ("dt" (t _ (if sgml-xml-mode "</dt>") |
| 1879 | "<dd>" (if sgml-xml-mode "</dd>") \n)) | 1901 | "<dd>" (if sgml-xml-mode "</dd>") \n)) |
| 1880 | ("em") | 1902 | ("em") |
| 1903 | ("fieldset" \n) | ||
| 1881 | ("fn" "id" "fn") ;; Footnotes were deprecated in HTML 3.2 | 1904 | ("fn" "id" "fn") ;; Footnotes were deprecated in HTML 3.2 |
| 1882 | ("footer" \n) | 1905 | ("footer" \n) |
| 1906 | ("frame" t ("longdesc") ("name") ("src") | ||
| 1907 | ("frameborder" ("1") ("0")) ("marginwidth") ("marginheight") | ||
| 1908 | ("noresize" "noresize") ("scrolling" ("yes") ("no") ("auto"))) | ||
| 1909 | ("frameset" \n ("rows") ("cols") ("onload") ("onunload")) | ||
| 1883 | ("head" \n) | 1910 | ("head" \n) |
| 1884 | ("header" \n) | 1911 | ("header" \n) |
| 1885 | ("hgroup" \n) | 1912 | ("hgroup" \n) |
| @@ -1894,22 +1921,37 @@ This takes effect when first loading the library.") | |||
| 1894 | "</body>" | 1921 | "</body>" |
| 1895 | )) | 1922 | )) |
| 1896 | ("i") | 1923 | ("i") |
| 1897 | ("ins") | 1924 | ("ins" nil ("cite") ("datetime")) |
| 1898 | ("isindex" t ("action") ("prompt")) | 1925 | ("isindex" t ("action") ("prompt")) |
| 1899 | ("kbd") | 1926 | ("kbd") |
| 1927 | ("label" nil ("for") ("accesskey") ("onfocus") ("onblur")) | ||
| 1900 | ("lang") | 1928 | ("lang") |
| 1929 | ("legend" nil ("accesskey")) | ||
| 1901 | ("li" ,(not sgml-xml-mode)) | 1930 | ("li" ,(not sgml-xml-mode)) |
| 1931 | ("map" \n ("name")) | ||
| 1902 | ("math" \n) | 1932 | ("math" \n) |
| 1933 | ("meta" t ("http-equiv") ("name") ("content") ("scheme")) | ||
| 1903 | ("nav" \n) | 1934 | ("nav" \n) |
| 1904 | ("nobr") | 1935 | ("nobr") |
| 1936 | ("noframes" \n) | ||
| 1937 | ("noscript" \n) | ||
| 1938 | ("object" \n ("declare" "declare") ("classid") ("codebase") | ||
| 1939 | ("data") ("type") ("codetype") ("archive") ("standby") | ||
| 1940 | ("height") ("width") ("usemap") ("name") ("tabindex")) | ||
| 1941 | ("optgroup" \n ("name") ("size") ("multiple" "multiple") | ||
| 1942 | ("disabled" "disabled") ("tabindex") ("onfocus") ("onblur") | ||
| 1943 | ("onchange")) | ||
| 1905 | ("option" t ("value") ("label") ("selected" t)) | 1944 | ("option" t ("value") ("label") ("selected" t)) |
| 1906 | ("over" t) | 1945 | ("over" t) |
| 1946 | ("param" t ("name") ("value") | ||
| 1947 | ("valuetype" ("data") ("ref") ("object")) ("type")) | ||
| 1907 | ("person") ;; Tag for person's name tag deprecated in HTML 3.2 | 1948 | ("person") ;; Tag for person's name tag deprecated in HTML 3.2 |
| 1908 | ("pre" \n) | 1949 | ("pre" \n) |
| 1909 | ("q") | 1950 | ("q" nil ("cite")) |
| 1910 | ("rev") | 1951 | ("rev") |
| 1911 | ("s") | 1952 | ("s") |
| 1912 | ("samp") | 1953 | ("samp") |
| 1954 | ("script" nil ("charset") ("type") ("src") ("defer" "defer")) | ||
| 1913 | ("section" \n) | 1955 | ("section" \n) |
| 1914 | ("small") | 1956 | ("small") |
| 1915 | ("span" nil | 1957 | ("span" nil |
| @@ -1924,6 +1966,7 @@ This takes effect when first loading the library.") | |||
| 1924 | ("variable-name") | 1966 | ("variable-name") |
| 1925 | ("warning"))) | 1967 | ("warning"))) |
| 1926 | ("strong") | 1968 | ("strong") |
| 1969 | ("style" \n ("type") ("media") ("title")) | ||
| 1927 | ("sub") | 1970 | ("sub") |
| 1928 | ("sup") | 1971 | ("sup") |
| 1929 | ("title") | 1972 | ("title") |
| @@ -1937,26 +1980,31 @@ This takes effect when first loading the library.") | |||
| 1937 | (defvar html-tag-help | 1980 | (defvar html-tag-help |
| 1938 | `(,@sgml-tag-help | 1981 | `(,@sgml-tag-help |
| 1939 | ("a" . "Anchor of point or link elsewhere") | 1982 | ("a" . "Anchor of point or link elsewhere") |
| 1940 | ("abbrev" . "Abbreviation") | 1983 | ("abbr" . "Abbreviation") |
| 1941 | ("acronym" . "Acronym") | 1984 | ("acronym" . "Acronym") |
| 1942 | ("address" . "Formatted mail address") | 1985 | ("address" . "Formatted mail address") |
| 1986 | ("area" . "Region of an image map") | ||
| 1943 | ("array" . "Math array") | 1987 | ("array" . "Math array") |
| 1944 | ("article" . "An independent part of document or site") | 1988 | ("article" . "An independent part of document or site") |
| 1945 | ("aside" . "Secondary content related to surrounding content (e.g. page or article)") | 1989 | ("aside" . "Secondary content related to surrounding content (e.g. page or article)") |
| 1946 | ("au" . "Author") | 1990 | ("au" . "Author") |
| 1947 | ("b" . "Bold face") | 1991 | ("b" . "Bold face") |
| 1948 | ("base" . "Base address for URLs") | 1992 | ("base" . "Base address for URLs") |
| 1993 | ("bdo" . "Override text directionality") | ||
| 1949 | ("big" . "Font size") | 1994 | ("big" . "Font size") |
| 1950 | ("blink" . "Blinking text") | 1995 | ("blink" . "Blinking text") |
| 1951 | ("blockquote" . "Indented quotation") | 1996 | ("blockquote" . "Indented quotation") |
| 1952 | ("body" . "Document body") | 1997 | ("body" . "Document body") |
| 1953 | ("box" . "Math fraction") | 1998 | ("box" . "Math fraction") |
| 1954 | ("br" . "Line break") | 1999 | ("br" . "Line break") |
| 2000 | ("button" . "Clickable button") | ||
| 1955 | ("caption" . "Table caption") | 2001 | ("caption" . "Table caption") |
| 1956 | ("center" . "Centered text") | 2002 | ("center" . "Centered text") |
| 1957 | ("changed" . "Change bars") | 2003 | ("changed" . "Change bars") |
| 1958 | ("cite" . "Citation of a document") | 2004 | ("cite" . "Citation of a document") |
| 1959 | ("code" . "Formatted source code") | 2005 | ("code" . "Formatted source code") |
| 2006 | ("col" . "Group of attribute specifications for table columns") | ||
| 2007 | ("colgroup" . "Group of columns") | ||
| 1960 | ("dd" . "Definition of term") | 2008 | ("dd" . "Definition of term") |
| 1961 | ("del" . "Deleted text") | 2009 | ("del" . "Deleted text") |
| 1962 | ("dfn" . "Defining instance of a term") | 2010 | ("dfn" . "Defining instance of a term") |
| @@ -1966,6 +2014,7 @@ This takes effect when first loading the library.") | |||
| 1966 | ("dt" . "Term to be defined") | 2014 | ("dt" . "Term to be defined") |
| 1967 | ("em" . "Emphasized") | 2015 | ("em" . "Emphasized") |
| 1968 | ("embed" . "Embedded data in foreign format") | 2016 | ("embed" . "Embedded data in foreign format") |
| 2017 | ("fieldset" . "Group of related controls and labels") | ||
| 1969 | ("fig" . "Figure") | 2018 | ("fig" . "Figure") |
| 1970 | ("figa" . "Figure anchor") | 2019 | ("figa" . "Figure anchor") |
| 1971 | ("figd" . "Figure description") | 2020 | ("figd" . "Figure description") |
| @@ -1974,6 +2023,8 @@ This takes effect when first loading the library.") | |||
| 1974 | ("font" . "Font size") | 2023 | ("font" . "Font size") |
| 1975 | ("footer" . "Footer of a section") | 2024 | ("footer" . "Footer of a section") |
| 1976 | ("form" . "Form with input fields") | 2025 | ("form" . "Form with input fields") |
| 2026 | ("frame" . "Frame in which another HTML document can be displayed") | ||
| 2027 | ("frameset" . "Container for frames") | ||
| 1977 | ("group" . "Document grouping") | 2028 | ("group" . "Document grouping") |
| 1978 | ("h1" . "Most important section headline") | 2029 | ("h1" . "Most important section headline") |
| 1979 | ("h2" . "Important section headline") | 2030 | ("h2" . "Important section headline") |
| @@ -1987,44 +2038,59 @@ This takes effect when first loading the library.") | |||
| 1987 | ("hr" . "Horizontal rule") | 2038 | ("hr" . "Horizontal rule") |
| 1988 | ("html" . "HTML Document") | 2039 | ("html" . "HTML Document") |
| 1989 | ("i" . "Italic face") | 2040 | ("i" . "Italic face") |
| 2041 | ("iframe" . "Inline frame with a nested browsing context") | ||
| 1990 | ("img" . "Graphic image") | 2042 | ("img" . "Graphic image") |
| 1991 | ("input" . "Form input field") | 2043 | ("input" . "Form input field") |
| 1992 | ("ins" . "Inserted text") | 2044 | ("ins" . "Inserted text") |
| 1993 | ("isindex" . "Input field for index search") | 2045 | ("isindex" . "Input field for index search") |
| 1994 | ("kbd" . "Keyboard example face") | 2046 | ("kbd" . "Keyboard example face") |
| 2047 | ("label" . "Caption for a user interface item") | ||
| 1995 | ("lang" . "Natural language") | 2048 | ("lang" . "Natural language") |
| 2049 | ("legend" . "Caption for a fieldset") | ||
| 1996 | ("li" . "List item") | 2050 | ("li" . "List item") |
| 1997 | ("link" . "Link relationship") | 2051 | ("link" . "Link relationship") |
| 2052 | ("map" . "Image map (a clickable link area") | ||
| 1998 | ("math" . "Math formula") | 2053 | ("math" . "Math formula") |
| 1999 | ("menu" . "List of commands") | 2054 | ("menu" . "List of commands") |
| 2055 | ("meta" . "Document properties") | ||
| 2000 | ("mh" . "Form mail header") | 2056 | ("mh" . "Form mail header") |
| 2001 | ("nav" . "Group of navigational links") | 2057 | ("nav" . "Group of navigational links") |
| 2002 | ("nextid" . "Allocate new id") | 2058 | ("nextid" . "Allocate new id") |
| 2003 | ("nobr" . "Text without line break") | 2059 | ("nobr" . "Text without line break") |
| 2060 | ("noframes" . "Content for user agents that don't support frames") | ||
| 2061 | ("noscript" . "Alternate content for when a script isn't executed") | ||
| 2062 | ("object" . "External resource") | ||
| 2004 | ("ol" . "Ordered list") | 2063 | ("ol" . "Ordered list") |
| 2064 | ("optgroup" . "Group of options") | ||
| 2005 | ("option" . "Selection list item") | 2065 | ("option" . "Selection list item") |
| 2006 | ("over" . "Math fraction rule") | 2066 | ("over" . "Math fraction rule") |
| 2007 | ("p" . "Paragraph start") | 2067 | ("p" . "Paragraph start") |
| 2008 | ("panel" . "Floating panel") | 2068 | ("panel" . "Floating panel") |
| 2069 | ("param" . "Parameters for an object") | ||
| 2009 | ("person" . "Person's name") | 2070 | ("person" . "Person's name") |
| 2010 | ("pre" . "Preformatted fixed width text") | 2071 | ("pre" . "Preformatted fixed width text") |
| 2011 | ("q" . "Quotation") | 2072 | ("q" . "Quotation") |
| 2012 | ("rev" . "Reverse video") | 2073 | ("rev" . "Reverse video") |
| 2013 | ("s" . "Strikeout") | 2074 | ("s" . "Strikeout") |
| 2014 | ("samp" . "Sample text") | 2075 | ("samp" . "Sample text") |
| 2076 | ("script" . "Executable script within a document") | ||
| 2015 | ("section" . "Section of a document") | 2077 | ("section" . "Section of a document") |
| 2016 | ("select" . "Selection list") | 2078 | ("select" . "Selection list") |
| 2017 | ("small" . "Font size") | 2079 | ("small" . "Font size") |
| 2018 | ("sp" . "Nobreak space") | 2080 | ("sp" . "Nobreak space") |
| 2019 | ("span" . "Generic inline container") | 2081 | ("span" . "Generic inline container") |
| 2020 | ("strong" . "Standout text") | 2082 | ("strong" . "Standout text") |
| 2083 | ("style" . "Style information") | ||
| 2021 | ("sub" . "Subscript") | 2084 | ("sub" . "Subscript") |
| 2022 | ("sup" . "Superscript") | 2085 | ("sup" . "Superscript") |
| 2023 | ("table" . "Table with rows and columns") | 2086 | ("table" . "Table with rows and columns") |
| 2024 | ("tb" . "Table vertical break") | 2087 | ("tb" . "Table vertical break") |
| 2088 | ("tbody" . "Table body") | ||
| 2025 | ("td" . "Table data cell") | 2089 | ("td" . "Table data cell") |
| 2026 | ("textarea" . "Form multiline edit area") | 2090 | ("textarea" . "Form multiline edit area") |
| 2091 | ("tfoot" . "Table foot") | ||
| 2027 | ("th" . "Table header cell") | 2092 | ("th" . "Table header cell") |
| 2093 | ("thead" . "Table head") | ||
| 2028 | ("title" . "Document title") | 2094 | ("title" . "Document title") |
| 2029 | ("tr" . "Table row separator") | 2095 | ("tr" . "Table row separator") |
| 2030 | ("tt" . "Typewriter face") | 2096 | ("tt" . "Typewriter face") |