Unitful.jl icon indicating copy to clipboard operation
Unitful.jl copied to clipboard

Option to Output Lowercase `l` Symbol for Liters

Open pyramids opened this issue 6 years ago • 1 comments
trafficstars

I would like to be able to switch the output of units to use a lowercase l for Liters.

The lowercase l is already supported for input (but I cannot seem to find the code for it, only a comment). I suppose I only need to define a new unit, but I would like to know the recommended way and how it would interplay with existing code for accepting l so that a) I don't break anything and b) my "implementation" reflects a recommended way to handle this with a view to potentially publishing my code some day.

Hence my questions:

  1. Where in the code are l handled as input units?
  2. What is the recommended way to change output units for u"l" from L to l?
  3. Wouldn't this presumeably frequent desire make for a good example for the documentation?

#18 may be related, but that may also be in the eye of the beholder.

Thank you for your help and the very useful package.

pyramids avatar Apr 07 '19 09:04 pyramids

I believe https://github.com/ajkeller34/Unitful.jl/commit/f2470e48018a67687c5295e855bfed6ffba18342 introduced liters, both using the (nput) symbols L and l according to the change to NEWS.md.

pyramids avatar Apr 07 '19 09:04 pyramids