Html-text

From Frontal Wiki

Jump to: navigation, search

Contents

Purpose

This style is exclusive to the 'text' tag and determines whether or not the text will support HTML tags.


Value

The html-text style accepts boolean values "true" or "false". The default value is "true".

html-text: true;

This style is cascading.


Remarks

In order to use HTML tags within a text tag, the "<![CDATA[ ...text text text... ]]>" must be used.


This style takes advantage of a Flash feature. See the Flash reference for TextField.htmlText for more details and a list of supported HTML tags.


Note that in the example, when html-text is false, an blank line appears at the top of the text box. This is because condense-white only has an effect on text with html-text set to true. The extra line is due to the return after <![CDATA[, before the first character of visible text.


Example

Click the checkbox to see the effect of setting this style:

<style><![CDATA[
	text, input
	{
		margin: 30px auto 0px auto;
		width: 200px;
	}
	input[type=checkbox]
	{
		custom-label-placement: left;
 
		@onClickRaw
		{
			gE("source").sS("html-text", value);
		}
	}
	text
	{
		html-text: false;
		border-width: 1px;
		condense-white: true;
		font-family: Swift LT Std;
		font-size: 14px;
		height: 250px;
	}
]]></style>
<include rel="assets" blocking="true" src="assets.swf" fontClasses="SwiftLTStd, SwiftLTStdBold, SwiftLTStdItalic" />
<text id="source"><![CDATA[
Sed ut <b>perspiciatis</b> unde omnis iste natus error sit voluptatem accusantium
doloremque laudantium, <i>totam rem aperiam</i>, eaque ipsa quae ab illo inventore
veritatis et quasi architecto beatae <font size="20">vitae dicta sunt explicabo.</font>
]]></text>
<input type="checkbox"><![CDATA[html-text:]]></input>

Can Be Applied To

This style can be applied to:

Personal tools
Get Adobe Flash player