Pasting into verbatim blocks

Are you missing a feature? Request its implementation here.
dnedrow
Posts: 60
Joined: Wed Jan 28, 2004 10:51 pm

Pasting into verbatim blocks

Post by dnedrow »

Currently, when I paste text into a verbatim block (e.g. programlisting), oXygen re-aligns everything in the pasted block.

I'd like to see the whitespace preserved only when pasting into verbatim areas.

-David
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Post by sorin_ristache »

Hello,

You can control this with the option "Indent on paste" in Preferences - Editor - Format. If this option is set to false the pasted block will not be realigned but the exact copied content will be preserved.

Regards,
Sorin
dnedrow
Posts: 60
Joined: Wed Jan 28, 2004 10:51 pm

Post by dnedrow »

The drawback to using "Indent on paste" is that it disables all indenting for pasted text, both for <programlisting/> and regular text that I would like to have indented.

-David
george
Site Admin
Posts: 2095
Joined: Thu Jan 09, 2003 2:58 pm

Post by george »

Hi David,

The next release of oXygen will provide an action for intenting the current element that will take into account the xml:space attribute and the list of elements for which spaces should be preserved. You should be able then to paste then call the format element action on the parent elemnent to format and indent the pasted content. Otherwise it is hard to implement the paste action itself to be aware of xml:space and of the spaces preserve elements list as the pasted content is any text in the document and can span multiple elements.

Best Regards,
George
Post Reply