bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Ncurses: Alignment for dynamic Fields


From: Leon Winter
Subject: Ncurses: Alignment for dynamic Fields
Date: Wed, 10 Apr 2013 12:08:33 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

Hi,

I am using Ncurses/Forms to provide an UI and came across some usability
issues. If a field is supposed to hold more content than its window
width one can unset the O_STATIC options and thus the field will be
dynamic. However when using the dynamic field feature, the content of
the field will not be aligned anymore (as also described in the
documentation). While this make perfect sense for fields with actual
content bigger than its window size, it is unfortunate for fields that
are dynamic but do not contain actual overflowing (or so called
'hidden') content. Thus simply unsetting O_STATIC disabled alignment of
the content although the content at this point in time might be able to
be displayed aligned.
Therefore I wrote a patch which enables justification for fields even if
they are dynamic. If the content in the field is overflowing, no
justification will take place (which is the behaviour at the monent).
However if there is no hidden information the content will be aligned.
Since I am not an expert of the Ncurses code, I sense there could be
room for improvement. Also I am aware that the current behaviour is
documented and probably also very intended. However maybe other users
would also like to have aligntment in dynamic fields. In order to
sustain compability, a new flag for the options of fields might be
introduced which could than be enabled for the new behaviour.
I would appreciate if we could bring this feature (possibly with a new
flag) upstream.

Best regards,
Leon Winter

Attachment: ncurses-5.7-dynamic-alignment.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]