CalHTMLPane v2.0 Guide Example Tag Usage


5: Misc

Attr: align (floating)

Use With:
Tables, Images, form components, inline frames, <OBJECT> tag
Arguments: left | right
Synopsis:

left will float the object on the left margin

right will float the object on the right margin

Multiple objects may be floated left and right.

  • Note that you need to be sure when using right-aligned floats that there is sufficient space between the left and right margins. If horizontal space becomes too narrow you may see rendering problems as text or other objects begin to overlap the right hand float. You should be able to see this happen in the example below if you gradually reduce the width of the display frame. This is an effect of asynchronous parsing/loading, and you will experience the same rendering effect on a Web browser such as Internet Explorer 4.
Example:

This is a start of the text and you can
<IMG src="images/orchid.gif" width=100 height=94 align=left>
<IMG src="images/orchid.gif" width=100 height=94 align=right>
see that even though we inserted two images between the words 'can' and 'see', the text
<TABLE border align=left cellpadding=3>
  <TR><TD>Floating table</TD></TR>
</TABLE>
<INPUT align=right type=button value="Floating button">
will continue on the same line as if the images have been ignored. Only when a new line occurs will the images be inserted against the right and left margins. We've also floated a table and a form component to demonstrate that multiple objects can be floated. You need to be careful when using right margin floats if you are authoring documents for small displays. Rendering errors can occur if the display width becomes too narrow.

Rendering:

This is a start of the text and you can see that even though we inserted two images between the words 'can' and 'see', the text
Floating table
will continue on the same line as if the images have been ignored. Only when a new line occurs will the images be inserted against the right and left margins. We've also floated a table and a form component to demonstrate that multiple objects can be floated. You need to be careful when using right margin floats if you are authoring documents for small displays. Rendering errors can occur if the display width becomes too narrow.

Guide Index  |  JavaDoc  |  Previous  |  Next