[kde-guidelines] Styleguide: Unconstrained input

Aurélien Gâteau agateau at kde.org
Tue Jun 25 13:00:40 UTC 2013


On Tuesday 25 June 2013 10:05:51 Heiko Tietze wrote:
> Am 24.06.2013 17:27:05, schrieb Aurélien Gâteau:
> > From a developer point of view, there are two ways to define formatted
> > input, both use KLineEdit...
> 
> Thanks
>  a lot. Should we separate the masking and formatting stuff from
> unconstrained input to an additional section at constrained input with
> the name "formatted text input"?

I think so, masking and formatting (assuming you mean "rich text") are quite 
different beasts.

Note that KLineEdit does not support rich-text, only KTextEdit (the multi-line 
widget) does.

> If I understand
> the docu right there is a QTextDocument that can be used for rich text/html.
> I'd treat it as unconstrained because I'm pretty free with my input. Do we
> need to add a section?

Not exactly: QTextDocument is not a visual element. QTextDocument stores the 
data about a rich text document. Widgets can use this class to render a 
document on the screen. KTextEdit uses it to draw its text, other widgets can 
use it as well.

Aurélien


More information about the kde-guidelines mailing list