Main Index | Element Index | Element Tree | HTML Support History |
The Mysterious Attribute |
Why It Happens Attribute Values | The Implications |
The Mysterious Attribute
Adobe corporation has two HTML editing products called 'SiteMill' and 'PageMill' (until recently only for the Macintosh platform) used to create HTML pages. In the course of creating and saving a web page that contains images (represented using the IMG tag in HTML), the editor would create an extra 'NATURALSIZEFLAG' attribute in the IMG tag. This attribute does not appear in any HTML standard, so it does not validate as legal syntax (causing many authors to wonder what was wrong with their documents.) Why It Happens When an image is inserted into a document using either of these editors, a reference for the image is created that includes the name, dimensions, and alignment of the image. This is then inserted in the document, along with the NATURALSIZEFLAG attribute, which is assigned an integer value of 0-3, such as with this example: <img SRC="test.gif" WIDTH=350 HEIGHT=100 ALIGN=bottom NATURALSIZEFLAG=3> PageMill and SiteMill use the NATURALSIZEFLAG attribute to specify an image's actual or resized dimensions within the editor when updating or replacing the image. These editors determine the display size of an updated image using either the original image's actual dimensions, or by scaling the original image's dimension based on the NATURALSIZEFLAG attribute's value. Attribute Values - What They Mean |
|
0 | Indicates a horizontally and vertically resized image. When updating or replacing the referenced image, PageMill or SiteMill scales the updated image to maintain the dimensions of the original image. |
1 | Indicates a vertically resized image. When updating or replacing the referenced image, PageMill or SiteMill scales the updated image to maintain the only the height dimension of the original image. |
2 | Indicates a horizontally resized image. When updating or replacing the referenced image, PageMill or SiteMill scales the updated image to maintain only the width dimension of the original image. |
3 | Indicates an actual size image. When updating or replacing the referenced image, PageMill or SiteMill displays the updated image using the image's PageMill dimensions, and not the original image dimensions. |
What Are the Implications? This 'editor extension' is not the only one that has ever been created - several other HTML editors have created some as well. This type of markup usually seems (hopefully) to be a sort of "crutch" used to deal with editor implementation issues which could not be easily solved when implementing seamless round-tripping of formatting between open and save. This type of markup may be left in documents 'as-is' with no ill-effects (if designed well), other than complaints from HTML validators (browsers will ignore such markup.) Nothing should be harmed by removing the NATURALSIZEFLAG attribute or any other such editor-specific markup from a document. If it is deleted, opening and saving documents in such editors will most likely re-add the markup to the document. The response received about the NATURALSIZEFLAG attribute mentions that it could possibly be dropped from future versions of the editors (it will probably depend on how vital it is to the scheme these editors use to manipulate images.) |
|