This branch is 23 commits behind wathiede/i3xs:master
Glenn Griffin de6bef6e36 More datetime changes
* Accept the format string as Into<String> rather than String to allow
  &str to be provided.
* set_colors accepts Into<Vec<TimeColor>> rather than &[TimeColor]. The
  function needs a Vec<TimeColor>. Previously it would unconditionally
  clone the slice into a Vec, now it can accept a Vec if the user provides
  one and avoid an allocation in those cases (while still cloning a slice
  if that's what the user provides).
* DateTime::colors was an Option<Vec<TimeColor>> it's now simply a
  Vec<TimeColor>. There was no difference in logic between a None and an
  empty Vec so the code could be simplified by removing the Option.
* No longer allocate a String when formatting the time.
* Collapse the logic setting color. Calculating whether to set a color
  and storing the result in Option<ColorRGB> only to then set data.color
  if the Option is Some, can be collapsed to simply set data.color if the
  configuration dictates.
2019-10-01 11:27:06 -07:00
2019-10-01 11:27:06 -07:00
2019-09-21 11:03:46 -07:00
2019-09-22 09:57:32 -07:00
2019-09-22 09:57:32 -07:00
Description
No description provided
832 KiB
Languages
Rust 100%