Hi Marco, this line is inserted for creating the same behaviour for all browsers. If this behaviour doesn't meet your requirements you can open a enhancement issue for it. The best would be if you can attach your patch to it so we can integrate it into the component.
Regards, Alex On Monday 03 October 2011 15:58:06 Marco Pompili wrote: > Hi qooxdooers, > > I'm playing around with the HtmlArea widget, and I've found out that some > properties prevent me to have a total control on the html generated by this > widget. I've found out that the editor always adds a standard html string > that messes up my formatting. > > This line from the method : *__generateDefaultContent* > > > > This code line always adds that html formatting that i hate. > > So I've modified the class /qx.bom.htmlarea.HtmlArea/ because > *__generateDefaultContent* is a private method and I guess that it's not > overridable. > > I've modified the last 2 properties and added a new one (the lines on > italic are the modifications that I've applied) *both on > qx.bom.htmlarea.HtmlArea and qx.ui.embed.HtmlArea* where I've also added > the apply method for the new property paragraphization > (_applyParagraphization): > > /** > * Default font family to use when e.g. user removes all content > */ > defaultFontFamily : > { > check : "String", > /nullable : true,/ > init : 4 > }, > > > /** > * Default font size to use when e.g. user removes all content > */ > defaultFontSize : > { > check : "Integer", > /nullable : true,/ > init : "Verdana" > }, > > /** > * If the content should be wrapped in paragraphs tags or not. (The > property i've added) > */ > /paragraphization: > { > check : "Boolean", > init : true > }/ > > And then I've modified the *last part of the :private method > __generateDefaultContent* of /qx.bom.htmlarea.HtmlArea/ > > Like this: > > > I've modified the classes *qx.bom.htmlarea.HtmlArea* and > *qx.ui.embed.HtmlArea* but I've leaved the actual behaviour that inserts a > default Html string. Anyway I think that should be nice to leave the > possibility to choose to use or not a default html string unless doing so > can cause some problems of crossbrowsing incompatibility. > > In some rare cases i got this error when i erase the content of the > HtmlArea: > Uncaught TypeError: Cannot call method 'removeAttribute' of null > > ----- > La coincidenza non ha madre. ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense. http://p.sf.net/sfu/splunk-d2dcopy1 _______________________________________________ qooxdoo-devel mailing list qooxdoo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel