On Dec 24, 2012, at 8:34 PM, zzs <zzs...@126.com> wrote:

> Auto document in popt is very good.
> But when I want the document of a option have serval paragraphs
> It output bad things.
> My option define like this:
>       {
>       .longName   = "fre",
>       .shortName  = '\0',
>       .descrip    = " RF output fre in Hz e.g. \n"
>                     " (1) 1000100000 1000.1M 1000100K. \n"
>                     " (2) ++ plus a PhaseFrequencyDetect fre. \n"
>                     " (3) +  plus a step. \n"
>                     " (4) -- minus a PhaseFrequencyDetect fre. \n"
>                     " (5) -  minus a step",
>       .argDescrip = "fre",
>       .argInfo    = POPT_ARG_STRING,
>       .arg        = &fre,
>       .val        = 0
>       },
> I want popt output the help string like it defined. e.g.
> When a newline char appears, It should start a new paragraph.
> But Popt looks like dosn't get special process for new line char.

What version of popt?

You are likely correct that popt doesn't deal with
'\n' characters correctly (i.e by appending blanks to
space out to what you wish as a "paragraph", i.e. an
aligned text block).

The killer issue is wide characters, which popt nearly
-- but not quite -- handles correctly.

No reliable spacing is possible until wide characters
(and i18n) are handled correctly.

There are serious portability issues -- both platform
and legacy compatibility -- issues involved with handling
wide characters and i18n.

Sadly, I permitted a GNOME patch 5+ years ago from a JA
developer that has made a huge mess in popt. The patch
tries to do iconv(3) conversions "the hard way" (i.e.
without using the GNU specific iconv library).

Again: without solid/reliable spacing, "paragraph" (or
block of text indentation) simply isn't feasible.

And unless someone assists with the character encoding
testing positively (not just complaining because text
doesn't align), well … what you are asking for simply
isn't ever going to happen (because the patch would
have been sent years ago) in FL/OSS development.

73 de Jeff

POPT Library                                           http://rpm5.org
Developer Communication List                       popt-devel@rpm5.org

Reply via email to