Refactoring minwidth to additionally accept a percentage of total time instead of a pixel value. The disadvantage here is that GetOptions has to accept minwidth as a string, and we have to do the string->float conversion ourselves; in this case, I chose to use a regex to find digits and periods, and print the usage string if it couldn't be persuaded to be a float.
Refactoring minwidth to additionally accept a percentage of total time instead of a pixel value. The disadvantage here is that
GetOptions
has to accept minwidth as a string, and we have to do the string->float conversion ourselves; in this case, I chose to use a regex to find digits and periods, and print the usage string if it couldn't be persuaded to be a float.