@@ -313,8 +313,9 @@ impl<'a> Help<'a> {
313
313
let nlh = self . next_line_help || arg. is_set ( ArgSettings :: NextLineHelp ) ;
314
314
let width = self . term_w ;
315
315
let taken = ( longest + 12 ) + str_width ( & * spec_vals) ;
316
- let force_next_line = !nlh && width >= taken && str_width ( h) > ( width - taken) &&
317
- ( taken as f32 / width as f32 ) > 0.25 ;
316
+ let force_next_line = !nlh && width >= taken &&
317
+ ( taken as f32 / width as f32 ) > 0.35 &&
318
+ str_width ( h) > ( width - taken) ;
318
319
319
320
if arg. has_switch ( ) {
320
321
if !( nlh || force_next_line) {
@@ -402,8 +403,9 @@ impl<'a> Help<'a> {
402
403
403
404
// We calculate with longest+12 since if it's already NLH we don't care
404
405
let taken = ( longest + 12 ) + str_width ( & * spec_vals) ;
405
- let force_next_line = !nlh && width >= taken && str_width ( h) > ( width - taken) &&
406
- ( taken as f32 / width as f32 ) > 0.25 ;
406
+ let force_next_line = !nlh && width >= taken &&
407
+ ( taken as f32 / width as f32 ) > 0.35 &&
408
+ str_width ( h) > ( width - taken) ;
407
409
debugln ! ( "Force Next Line...{:?}" , force_next_line) ;
408
410
debugln ! ( "Force Next Line math (help_len > (width - flags/opts/spcs))...{} > ({} - {})" ,
409
411
str_width( h) ,
@@ -421,7 +423,7 @@ impl<'a> Help<'a> {
421
423
422
424
// Is help on next line, if so newline + 2x tab
423
425
if nlh || force_next_line {
424
- try!( write ! ( self . writer, "\n {}{}" , TAB , TAB ) ) ;
426
+ try!( write ! ( self . writer, "\n {}{}{}" , TAB , TAB , TAB ) ) ;
425
427
}
426
428
427
429
debug ! ( "Too long..." ) ;
@@ -463,7 +465,7 @@ impl<'a> Help<'a> {
463
465
for part in help. split ( "{n}" ) . skip ( 1 ) {
464
466
try!( write ! ( self . writer, "\n " ) ) ;
465
467
if nlh || force_next_line {
466
- try!( write ! ( self . writer, "{}{}" , TAB , TAB ) ) ;
468
+ try!( write ! ( self . writer, "{}{}{}" , TAB , TAB , TAB ) ) ;
467
469
} else if arg. has_switch ( ) {
468
470
write_nspaces ! ( self . writer, longest + 12 ) ;
469
471
} else {
0 commit comments