With this attribute, the way text wrapping is performed can be directly
controlled if Texteditor.WrapBorder was set > 0. There are two
major ways of how wrapping can be performed. 'soft wrapping' and
'hard wrapping'. Whereas soft wrapping refers to the process where lines
will just be graphically wrapped to the next line, but are still be
considered a single line. Hard wrapping in turn immediately inserts a
newline character as soon as the cursor passed the specified amount of
characters in one line and therefore separate them in a 'hard' direct
way.
The following modes are supported:
NoWrap
-
Wrapping is completely disabled, setting WrapBorder > 0 will
have no effect. That means, the window will have to be resizes
by the user to e.g. see or edit all text.
SoftWrap
-
Enables soft wrapping of lines if WrapBorder > 0. That means,
lines are being wrapped at the specified border in a way that
they are still logically one line. This allows to e.g. dynamically
reconcatenate lines. This should be considered the new preferred
setting for new/revised applications. If WrapBorder == 0, soft
wrapping will be performed at the current window limits.
HardWrap
-
Enables hard wrapping of lines if WrapBorder > 0. That means,
lines are being wrapped at the specified border by directly
inserting newline characters as soon as the cursor passes the
specified border. While this mode is the default, due to
historical reasons, it doesn't allow to directly reconcatenate
lines if the user e.g. removes characters. If WrapBorder == 0,
soft wrapping will be performed at the current window limits.
This is the default
Due to historical reasons the default is to hard wrap a line if the
WrapBorder attribute is set > 0 and WrapMode is kept untouched.
However, for new applications, soft wrapping should be considered the
preferred setting as this mode is more intuitive and allows users of
texteditor to directly concatenate lines if they e.g. remove
characters while they are writing.