Improved battery widget to allow for both percentage and time remaining to be displayed.

Ideally this would be done in a similar way to Data.Time.Format,
but for now this works.
Switch from replace in MissingH to HStringTemplate

There is already another use of HStringTemplate in this program, so
reduce dependencies.  The only change in functionality from the original
is using $$ as delimiters for replacement instead of <>