Color picker for RichTextEditor
<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
height="420">
<mx:RichTextEditor id="rte1" backgroundColor="#ccffcc"
title="Rich Text Editor"
creationComplete="rte1.textArea.setStyle('backgroundColor','0xeeffee')"
text="Simple sample text" />
<mx:Button label="Change appearance"
click="rte1.textArea.setStyle('backgroundColor','0xffffff');rte1.colorPicker.selectedIndex=27;" />
<mx:Button label="Reset Appearance" click="rte1.textArea.setStyle('backgroundColor','0xeeffee');rte1.colorPicker.selectedIndex=0;" />
</mx:Application>
Related examples in the same category