Page 1 of 1

space key when space insignificant

Posted: Thu Dec 08, 2016 1:54 am
by steve.cuzner
Given this example from https://www.oxygenxml.com/doc/versions/ ... ?hl=spaces

Code: Select all

<p>The file is located in <i>HOME</i>/<i>USER</i>/hello. 
This is a <strong>big</strong>

<emphasis>deal</emphasis>.
</p>
In this example, whitespace should not be introduced around the i tags as it would introduce extra significant whitespace into the document. The space between the end </strong> tag and the beginning <emphasis> tag should be normalized to a single space, not zero spaces.
As the documentation says, the multiple space characters following </strong> > 1 are insignificant. In the author view, is it possible to know that an additional space would be insignificant and disable the space key to prevent the introduction of insignificant space?

Re: space key when space insignificant

Posted: Thu Dec 08, 2016 11:09 am
by Radu
Hi Steve,

I understand, this makes sense, we already have an internal issue for it and I added your feedback to it.
Actually at some point we tried to implement this behavior of disallowing entering consecutive white spaces in elements which are not space-preserve and one situation where this would be annoying would be when you have two words like this {code}word1| word3{code} with the caret placed after the "word1" and you want to insert a space and then insert "word2". But the application would prohibit inserting a space because you would have two consecutive spaces between the words, but that would be a temporary step until the tech writer inserts the text. How would you see this issue handled by the application?

Regards,
Radu

Re: space key when space insignificant

Posted: Thu Dec 08, 2016 5:18 pm
by steve.cuzner
I would expect that if you are after word1 and before the space, if you type the space bar the cursor would advance to between the space and word3 which would allow you to start typing word2. This would require you to add a new space between word2 and word3, but that would be a natural action for a writer in my opinion.

Re: space key when space insignificant

Posted: Fri Dec 09, 2016 10:53 am
by Radu
Hi Steve,

About this remark:
if you type the space bar the cursor would advance to between the space and word3
So the cursor would be moved right to the beginning of word3? As a writer I would be inclined to add one more space and then move the cursor to the left before typing because I would not want the word I'm typing to be joined with word3.

Regards,
Radu