[EMAIL PROTECTED] wrote:
> On Mar 6, 5:53 am, Laurent Jouanneau <[EMAIL PROTECTED]> wrote:
>> Boris Zbarsky wrote:
>>> Laurent Jouanneau wrote:
>>>> - spaces at the end of a content are ignored by the layout
>>> This is required for HTML, so if you're aiming at a wysiwyg editor.....  
>>> Note that the built-in editor in Gecko handles this by converting spaces
>>> to &nbsp;.
>> I saw it, but i would like to avoid doing this sort of convertion. (note
>> : my xml editor is a component based on nsEditor, so it is also a
>> "built-in" editor in gecko, and i will propose patches later ;-) )
> 
> Can you give a specific example of the problem and explain what you
> want to happen instead?

I've got an xml element. Example : <foo>absdefg</foo>. My caret is after 
the "g" letter" : <foo>absdefg|</foo>
if I type on the space bar, it inserts a space :
<foo>absdefg |</foo>. From the DOM point of view, it is ok.

But the space isn't rendered, because it is at the end of the content. 
And so, the caret doesn't move. From the user point of view, it is 
inconsistent. The user can think that the editor didn't inserted a space.

> 
> You might be able to fix some of your issues by styling your content
> with -moz-pre-wrap.

Yes i could use this style. But after thought, i will use the same 
method of the HTML editor, by using insecable space. In a wysiwyg 
context, if the user types two spaces between two word or at the end of 
a content, two spaces should be displayed, whether the style is pre-wrap 
or not.

So, forget this issue :-)


Laurent
_______________________________________________
dev-tech-layout mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-layout

Reply via email to