[Home]Adaptive Formatting - First Field Width - Program Options Suggestion

BOOST WIKI | RecentChanges | Preferences | Page List | Links List

Difference (from prior major revision) (no other diffs)

Changed: 1,20c1,59
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-37a2b734f1e6cbf2daa28725d5c71bb0.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-37ac82e56fc021268c5860f8cb66e992.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-3fb2b80bcf1761fffb5202cd6fb11c62.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-3fbff49bd074838123112edbd336c810.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-4027d3e6b9a59fb838bd79a2062e4473.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-407c1d1d202686cb75e4eccd461a3062.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-41c85a2d4b5db2fad8826c4c0eb7630f.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-42e869881730408dc319becdf0230637.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-468af9f0ddca5b75ed0f81b254b0c1fb.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-47dfb4c59f1d70a13988e3a1eabc319e.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-47e51e4adfa706e7a37fcea0a57933ad.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-5299ffd1c7861cc5dc295b8d730d124b.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-54a325530bddf9149b38d9d9bfdbe955.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-553d70b8b2597cd38842daae307cacf8.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-55ffcf3ce44db50124a6db48d4d1297e.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-5677775ad21e8ca2d2d4da52285f80ac.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-580382def3597adf96ad7904fc061b69.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-593ae9e70b13f463851ba1c18be4d27e.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-5f257cb7334faa56c090edf1cea1870d.html
http://www2.cleanadulthost.com/hardcore/eriolt/matchmaking-dati-5fe5ee1797351af54c57c82a14b0bf00.html

Adaptive formatting (first field width)




Back to Suggestions - program options library




The usage message formatting should be adaptive to the width of the first field of the message. For example, currently, we might get:


Allowed options:
-v val : some value
-w word : some other vlue


This should look like:


Allowed options:
-v val : some value
-w word : some other vlue


Also, when a field is too wide, we get:


Allowed options:
-v some-excessively-long-string : some value
-w word : some other vlue


which should look like:


Allowed options:
-v some-excessively-long-string : some value
-w word : some other vlue


There ought to be a maximum width for the first field.


- People/Chuck Messenger




What worries me is that with adaptive formatting if you add a new option, the ":" line will move -- and the help
message look, which is probably familiar to user already, will change. The current behaviour is that there's
maximum width for the first field, and ":" is placed at the end of that width.

- People/Vladimir Prus





But the problem is that, very often, the width is so wide that it looks strange. If the usage message looks strange, people won't like the library. People take great pride in superficial things like that. And for good reason, too, since people also judge on those superficial things. (and I count myself among those people) A program with a clunky usage message gives the impression of a sloppy program. Stupid, perhaps, but that's human nature. For that reason, it's fairly important, I think, for program_options to at least not make really strange-looking usage messages. At least not by default.

- People/Chuck Messenger




Adaptive formatting (first field width)

Back to Suggestions - program options library


The usage message formatting should be adaptive to the width of the first field of the message. For example, currently, we might get:

    Allowed options:
      -v val                 : some value 
      -w word                : some other vlue

This should look like:

    Allowed options:
      -v val  : some value 
      -w word : some other vlue

Also, when a field is too wide, we get:

    Allowed options:
      -v some-excessively-long-string : some value 
      -w word                : some other vlue

which should look like:

    Allowed options:
      -v some-excessively-long-string : some value 
      -w word                         : some other vlue

There ought to be a maximum width for the first field.

    - People/Chuck Messenger


What worries me is that with adaptive formatting if you add a new option, the ":" line will move -- and the help message look, which is probably familiar to user already, will change. The current behaviour is that there's maximum width for the first field, and ":" is placed at the end of that width.

    - People/Vladimir Prus


But the problem is that, very often, the width is so wide that it looks strange. If the usage message looks strange, people won't like the library. People take great pride in superficial things like that. And for good reason, too, since people also judge on those superficial things. (and I count myself among those people) A program with a clunky usage message gives the impression of a sloppy program. Stupid, perhaps, but that's human nature. For that reason, it's fairly important, I think, for program_options to at least not make really strange-looking usage messages. At least not by default.

    - People/Chuck Messenger



BOOST WIKI | RecentChanges | Preferences | Page List | Links List
Edit text of this page | View other revisions
Last edited December 18, 2004 12:47 pm (diff)
Search:
Disclaimer: This site not officially maintained by Boost Developers