I went through the whole "WSIWYG text editor in Flash" programming thing in Flash 8 recently. I ended up figuring out that using the TextFormat class is the only really viable/sane way to go. It works pretty well, but some things like fighting with the Selection object were a royal pain. But it is do-able, I dun it.
Jason Merrill Bank of America Learning & Organization Effectiveness - Technology Solutions >>-----Original Message----- >>From: [EMAIL PROTECTED] [mailto:flashcoders- >>[EMAIL PROTECTED] On Behalf Of GregoryN >>Sent: Thursday, October 26, 2006 2:41 AM >>To: Flashcoders mailing list >>Subject: Re: [Flashcoders] advice needed: textformatting or css? >> >>Hello, >> >>I had similar problem (space below the text) in one project this year. I ended up >>with the >>following: >>1) Edges of the text field itself are NOT used to show the "space". >>You just use no borders, bg etc, so no one can say where are textfield >>edges :-) >>2) To show padding and other "space around text" additional elements >>are used, mainly mc's. Say, the screen_mc (containing just one >>rectangle) is placed below the textfield. >> >>3) When you update the textfield, measure it's size and resize the >>screen_mc accordingly. >> >>4) I've used margin/padding settings as attributes in the XML where >>the text itself is stored (or transferred). >> >>The designers are quite happy so far :-). >> >>PS. >>As to "textformat vs. css" - it's a matter of taste, IMO. I like CSS >>and try to use them whenever possible. However, there's no affordable >>(e.g., quite easy) way to build a WYSIWYG editor for css-formatted >>text... Therefore, all depends on your task. >> >> >> >>-- >>Best regards, >> GregoryN >>================================ >>http://GOusable.com >>Flash components development. >>Usability services. >> >>> =========== grimmwerks wrote: >>> >>> Ok - I've got this kiosk application I'm building - there's a playback >>> and there's a builder. The builder has a lot of textformatting going >>> on. Up to now I've been allowing the client to put in their text into >>> a textfiled, select a pulldown and it automatically inserts the >>> correct textformatting. >>> >>> However, since I'm saving all this textformatting to an xml file >>> embedded in a CDATA file, if there's a problem with the textformat, >>> then I'm screwed. >>> >>> One of the biggest problems that has been pointed out is that there is >>> no way of setting more 'space after a paragraph' that you can do in >>> photoshop. >>> >>> I'm starting to think that I should do it all as CSS, so that if i use >>> an external CSS file, and put <class> around the selected/edited text, >>> it's not saved with the xml and I can massage it afterwards. >>> >>> But is it also possible to do a 'space after paragraph' setting in css >>> for flash text? >>> >>> Thanks for any advice; it's at the tail end and this project is way behind. >> >> >>_______________________________________________ >>Flashcoders@chattyfig.figleaf.com >>To change your subscription options or search the archive: >>http://chattyfig.figleaf.com/mailman/listinfo/flashcoders >> >>Brought to you by Fig Leaf Software >>Premier Authorized Adobe Consulting and Training >>http://www.figleaf.com >>http://training.figleaf.com _______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com