Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Formatting DTD document is broken #268

Closed
fbricon opened this issue Dec 19, 2018 · 0 comments
Closed

Formatting DTD document is broken #268

fbricon opened this issue Dec 19, 2018 · 0 comments
Assignees
Labels
bug Something isn't working DTD formatting This issue or enhancement is related to formatting support in progress
Milestone

Comments

@fbricon
Copy link
Contributor

fbricon commented Dec 19, 2018

Try formatting https://tecfa.unige.ch/guides/xml/examples/dtd-examples/ePBL11/ibtwsh6_ePBL.dtd, you end up with:

<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
        WARNING: SLIGHTLY MODIFIED FOR USE AT TECFA ! GET THE ORIGINAL
        from http://www.ccil.org/%7Ecowan/XML/ibtwsh6.dtd

	ibtwsh.dtd
	This is the Itsy Bitsy Teeny Weeny Simple Hypertext DTD.
	Its public identifier is -//XML-DEV List//DTD IBTWSH 6.0//EN
	The contents are dedicated to the public domain by
		the author, John Cowan <cowan@ccil.org>, except that
		John Cowan retains the moral right to be known as the author.
	This is draft 6.0
	03/04/2001 Changed by Vivian Synteta 
	Changes: 
	- Correct a mistake (LI)
	- Add IDREF to element "A"
        - Take out id from entity all and IDREFS headers from tables and 
          IDREF from element a 
-->
<!-- 
======================================================================
This is an XML DTD which describes a subset of XHTML Basic for embedded
use within other XML DTDs.  It is by intention equivalent
(within its scope) to -//W3C//DTD XHTML 1.1//EN, but is
not a derived work in the copyright sense.  (Brief excerpts from
HTML 4.0 Transitional appear here and there.)

It is often convenient for XML documents to have a bit of
documentation somewhere in them.  In the absence of a DTD like
this one, that documentation winds up being #PCDATA only, which is
a pity, because rich text adds measurably to the readability of
documents.  By incorporating this DTD by reference (as an
external parameter entity) into another DTD, that DTD inherits
the capabilities of this one.  Using HTML-compatible elements
and attributes allows the documentation to be passed straight
through to HTML renderers.

Current HTML renderers can cope with most XML tags, but empty
tags require special treatment.  Inserting a space before the
terminating "/>" usually makes the "/" (which is not HTML)
invisible.  Using "<tag></tag>" is not as effective, as the
latter is often misinterpreted as a second "<tag>".

Note that since the elements of this DTD are intended to be
used within domain-specific elements of the surrounding DTD,
it is not necessary that every fragment begin with an "html"
element, as in HTML.  Recommended content models for elements
containing documentation are "%horiz.model;" for simple
text fragments and "%struct.model;" for documents in extenso.

Draft 6.0 is seriously incompatible with drafts 5.0 and earlier,
but *is* a subset of XHTML Basic.  I will keep draft 5.0 around;
note that I have changed the FPI.
======================================================================
-->
<!-- =========== Common attributes =========== -->
<!-- All elements (except full-document elements) have these attributes -->
<null>
    <!-- All non-empty elements have these attributes -->
    <null>
        <!-- =========== Models =========== -->
        <null>
            <null>
                <null>
                    <null>
                        <null>
                            <!-- =========== Horizontal formatting elements =========== -->
                            <!-- Abbreviations (normal) -->
                            <null>
                                <null>
                                    <!-- Acronyms (normal) -->
                                    <null>
                                        <null>
                                            <!-- Citation (italics) -->
                                            <null>
                                                <null>
                                                    <!-- Source code (monowidth) -->
                                                    <null>
                                                        <null>
                                                            <!--Terms being defined (normal) -->
                                                            <null>
                                                                <null>
                                                                    <!--Emphasis (italics) -->
                                                                    <null>
                                                                        <null>
                                                                            <!--Keyboard input -->
                                                                            <null>
                                                                                <null>
                                                                                    <!-- Quotation (appropriate quotation marks) -->
                                                                                    <null>
                                                                                        <null>
                                                                                            <!-- Sample output text (monowidth) -->
                                                                                            <null>
                                                                                                <null>
                                                                                                    <!-- Arbitrary span of text -->
                                                                                                    <null>
                                                                                                        <null>
                                                                                                            <!-- Strong emphasis (boldface) -->
                                                                                                            <null>
                                                                                                                <null>
                                                                                                                    <!-- Variable names (italics) -->
                                                                                                                    <null>
                                                                                                                        <null>
                                                                                                                            <!-- IMGs added DKS -->
                                                                                                                            <null>
                                                                                                                                <null>
                                                                                                                                    <!-- Hypertext anchors.
	CONSTRAINT: A elements are not allowed inside
	other A elements, a fact that XML cannot express. -->
                                                                                                                                    <null>
                                                                                                                                        <null>
                                                                                                                                            <!-- Mandatory line breaks -->
                                                                                                                                            <null>
                                                                                                                                                <null>
                                                                                                                                                    <!-- =========== Headers =========== -->
                                                                                                                                                    <null>
                                                                                                                                                        <null>
                                                                                                                                                            <null>
                                                                                                                                                                <null>
                                                                                                                                                                    <null>
                                                                                                                                                                        <null>
                                                                                                                                                                            <!-- =========== Lists =========== -->
                                                                                                                                                                            <!-- Definition list -->
                                                                                                                                                                            <null>
                                                                                                                                                                                <null>
                                                                                                                                                                                    <!-- Defined term -->
                                                                                                                                                                                    <null>
                                                                                                                                                                                        <null>
                                                                                                                                                                                            <!-- Definition -->
                                                                                                                                                                                            <null>
                                                                                                                                                                                                <null>
                                                                                                                                                                                                    <!-- Ordered list -->
                                                                                                                                                                                                    <null>
                                                                                                                                                                                                        <null>
                                                                                                                                                                                                            <!-- Unordered list -->
                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                <null>
                                                                                                                                                                                                                    <!-- List element -->
                                                                                                                                                                                                                    <null>
                                                                                                                                                                                                                        <null>
                                                                                                                                                                                                                            <!-- =========== Basic table support =========== -->
                                                                                                                                                                                                                            <!-- Shared attributes -->
                                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                                <!-- Table -->
                                                                                                                                                                                                                                <null>
                                                                                                                                                                                                                                    <null>
                                                                                                                                                                                                                                        <!-- Table caption -->
                                                                                                                                                                                                                                        <null>
                                                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                                                <!-- Table row -->
                                                                                                                                                                                                                                                <null>
                                                                                                                                                                                                                                                    <null>
                                                                                                                                                                                                                                                        <!-- Table header -->
                                                                                                                                                                                                                                                        <null>
                                                                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                                                                <!-- Table data -->
                                                                                                                                                                                                                                                                <null>
                                                                                                                                                                                                                                                                    <null>
                                                                                                                                                                                                                                                                        <!-- =========== Other vertical elements =========== -->
                                                                                                                                                                                                                                                                        <!-- Address block -->
                                                                                                                                                                                                                                                                        <null>
                                                                                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                                                                                <!-- Block quotation -->
                                                                                                                                                                                                                                                                                <null>
                                                                                                                                                                                                                                                                                    <null>
                                                                                                                                                                                                                                                                                        <!-- General text division -->
                                                                                                                                                                                                                                                                                        <null>
                                                                                                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                                                                                                <!-- Paragraph -->
                                                                                                                                                                                                                                                                                                <null>
                                                                                                                                                                                                                                                                                                    <null>
                                                                                                                                                                                                                                                                                                        <!-- Preformatted text -->
                                                                                                                                                                                                                                                                                                        <null>
                                                                                                                                                                                                                                                                                                            <null>
                                                                                                                                                                                                                                                                                                                <!-- =========== END OF ibtwsh.dtd =========== -->
@fbricon fbricon added bug Something isn't working formatting This issue or enhancement is related to formatting support DTD labels Dec 19, 2018
@fbricon fbricon added this to the v0.0.3 milestone Dec 19, 2018
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Dec 21, 2018
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Dec 21, 2018
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 2, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 3, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 3, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 3, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 3, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 7, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 7, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 8, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 8, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 8, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 9, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 9, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 9, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
fbricon pushed a commit that referenced this issue Jan 9, 2019
Fixes #221 and #268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
NikolasKomonen added a commit to NikolasKomonen/lsp4xml that referenced this issue Jan 11, 2019
Fixes eclipse#221 and eclipse#268

Signed-off-by: Nikolas Komonen <nikolaskomonen@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working DTD formatting This issue or enhancement is related to formatting support in progress
Projects
None yet
Development

No branches or pull requests

2 participants