|
This editor is modified from the original by Josh Dura. Thanks for posting the source Josh! A special thanks to Jonathan Coe and Thomas Schemmer. I'm fairly new with Flash and they helped point me in the right direction a few times.
A button and dialog to enter a URL has been added, CSS style importing, font importing, import and export routines to convert between the internal HTML format and CSS styled XHTML, as well as a function to refresh the text field variable after any formatting changes. Flash doesn't refresh the variable unless data within the text field has been changed and it must be done explicitly if only applying formatting changes. I have also had to explicitly set the formatting of a link to be blue and underlined as Textformat doesn't allow you to specify an alternate style for URLs.
I've used a Javascript timer to set the field contents and variables once the Flash movie has been loaded. In my own projects I use this to import and export data to and from the editor with the appropriate content when editing postings. In this example I am merely printing the results in a Javascript alert and replace all &'s with & to be used in an XML document.
Known Bugs
- Internet Explorer on the Macintosh will not support Javascript communication to and from Flash. I was going to work on an XML routine but Anthony Hunt has implemented a method with loadVariables and a PHP script backend as a workaround. I will be implementing it soon.
- There are probably others, please let me know.
Revisions - 2002/11/07
- Conversion from internal font representation to CSS pt representation
- Scrollbar appears on large text import
- CSS style importing with Javascript function including inline style WYSIWYG
- Font importing instead of system fonts with Javascript function
- Color picker
- URL Link Text
Revisions - 2002/09/22
- URLs longer than 127 characters now supported
- Removed <textformat> tags in export
- Export returns <href> tags without <font> and <u> tags
- URLs now appear in external windows when clicked in editor
- URL dialog has white background to block out text in editor
- Import variable and routine to be called from Javascript for import parsing
- Export variable and routine to be called from Javascript for export parsing.
- & characters are escaped to & characters.
Revisions - 2002/09/17
- Linking with URL button and dialog
- Added blue font and underline to all text field links
- Export variables for Javascript
- Explicit export variable updates after formatting changes
|
fla |
zip (fla) |
email me
|