RFE: Let XXE react to width of <col> elements
Leif Halvard Silli <[email protected]> Thu, 23 Jul 2026 20:00:41 +0200
| Newsgroups | gmane.editors.xxe.general |
|---|---|
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format.
--===============2227501378048397460==
Content-Type: multipart/alternative;
boundary="------------Beac79hp1DQG1ciDNi0zdutK"
Content-Language: nn-NO
This is a multi-part message in MIME format.
--------------Beac79hp1DQG1ciDNi0zdutK
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
For HTML documents, currently, if one manually tries to make a column of
a table wider (by dragging one side of a cell in the column), XXE
performs a «trick»: It adds a <colgroup> element to each column, and
also applies a width to each <colgroup> by way of adding a style
attribute with property "width:foo;" set to some percentage value.
Per HTML, each <colgroup> may contain zero or more <col> elements.
My main request is that instead of adding a <colgroup> to each column,
XXE should add a single <colgroup> plus one <col> for each column, with
the width set on each <col> element.
My secondary backup request is that, at the very least, if a table
contains a <colgroup> with <col> children, then XXE should not (at least
not without warning) destroy that element, if you try to regulate the
width of a column by way of the dragging method describe above. (See
point 3 below.)
Why? For several reasons:
1. Semantically, the <colgroup> is meant to group columns. Hence there
should usually be no reason to add a <colgroup> for each column –
doing so, amounts to say that each column should not be grouped with
any other column.
2. If one converts all the <colgroup> elements that XXE automatically
adds (when regulating a column’s width) to a single <colgroup> with
multiple <col> elements inside, then (as told above), XXE fails to
notice the width applied to the <col> elements - which is backwards.
XXE shoudl react to the width regardless of whether it is applied to
<colgroup> or <col>.
3. In addition, if you have added <colgrup><col> etc </colgroup>, but
still try to regulate the width of a column by way of dragging one
side of a cell in acolumn, XXE will currently replace your entire
<colgroup><col>etc </colgroup> with multiple <colgroup> elements –
something which borders on being destructive behavior! (E.g. imagine
that you added styling to all the col elements.)
4. Practically: A <colgroup> element is a very long element - in the
sense that its name contains 8 letters. When XXE auto adds 10 such
elements in a table consisting of 10 columns, the <colgroup> elemnts
will probably look as if they are wider than the table itself. It
all ends up looking very «funny». (I am talking about how it looks
inside XXE.)
It would be much more sane if XXE behave roughly as today, but would add
a single <colgroup> with multiple <col> inside, and where the width is
applied to each <col>, and where this width is visually respected by XXE.
Leif Halvard Silli
--------------Beac79hp1DQG1ciDNi0zdutK
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 8bit
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p>For HTML documents, currently, if one manually tries to make a
column of a table wider (by dragging one side of a cell in the
column), XXE performs a «trick»: It adds a <colgroup>
element to each column, and also applies a width to each
<colgroup> by way of adding a style attribute with property
"width:foo;" set to some percentage value.</p>
<p>Per HTML, each <colgroup> may contain zero or more
<col> elements. </p>
<p>My main request is that instead of adding a <colgroup> to
each column, XXE should add a single <colgroup> plus one
<col> for each column, with the width set on each
<col> element.</p>
<p>My secondary backup request is that, at the very least, if a
table contains a <colgroup> with <col> children, then
XXE should not (at least not without warning) destroy that
element, if you try to regulate the width of a column by way of
the dragging method describe above. (See point 3 below.)</p>
<p>Why? For several reasons:</p>
<ol>
<li>Semantically, the <colgroup> is meant to group columns.
Hence there should usually be no reason to add a
<colgroup> for each column – doing so, amounts to say that
each column should not be grouped with any other column. </li>
<li>If one converts all the <colgroup> elements that XXE
automatically adds (when regulating a column’s width) to a
single <colgroup> with multiple <col> elements
inside, then (as told above), XXE fails to notice the width
applied to the <col> elements - which is backwards. XXE
shoudl react to the width regardless of whether it is applied to
<colgroup> or <col>.</li>
<li> In addition, if you have added <colgrup><col> etc
</colgroup>, but still try to regulate the width of a
column by way of dragging one side of a cell in acolumn, XXE
will currently replace your entire
<colgroup><col>etc </colgroup> with multiple
<colgroup> elements – something which borders on being
destructive behavior! (E.g. imagine that you added styling to
all the col elements.)</li>
<li>Practically: A <colgroup> element is a very long element
- in the sense that its name contains 8 letters. When XXE auto
adds 10 such elements in a table consisting of 10 columns, the
<colgroup> elemnts will probably look as if they are wider
than the table itself. It all ends up looking very «funny». (I
am talking about how it looks inside XXE.)</li>
</ol>
<p>It would be much more sane if XXE behave roughly as today, but
would add a single <colgroup> with multiple <col>
inside, and where the width is applied to each <col>, and
where this width is visually respected by XXE. </p>
<p>Leif Halvard Silli</p>
</body>
</html>
--------------Beac79hp1DQG1ciDNi0zdutK--
--===============2227501378048397460==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
--
XMLmind XML Editor Support List
[email protected]
http://www.xmlmind.com/mailman/listinfo/xmleditor-support
--===============2227501378048397460==--