-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convenience macro for hour-minute-second quantities #684
Comments
#70? |
Not quite, though they are related. I am asking for a clone of \NewDocumentCommand\hms{ O{} m }{%
\ang[%
angle-symbol-degree = \hour,
angle-symbol-minute = \minute,
angle-symbol-second = \second,
number-angle-product = \,,
angle-separator = ~, % Not sure about this setting.
#1,
]{#2}%
} though I would expect it to use the value of This would almost give what #70 is asking for by way of (the analog of) One could of course go even further and consider an interface for generating arbitrary commands that generate cascading quantities like this, with arbitrary factors between them. This would enable users to create e.g. a command like above but including days as an additional level ( |
I think this would be a separate sub-module from angles, or perhaps done the same way as products, etc. (core code the same, different interfaces). I guess the main question for me is the document command: I will look to see what |
I don't see |
OK, I'm looking at this - suggested name is |
'Sexagesimal' perhaps? |
|
One problem with https://www.w3.org/TR/xmlschema-2/#duration https://en.wikipedia.org/wiki/ISO_8601#Durations On the other hand `duration is the only one of the types that isn't anchored at a specific actual time. |
I'm not sure there's a lot of overlap with XML here :) For a duration of longer than hours, there's really no need to have special formatting as there's very unlikely to be a desire to convert units - this is I imagine something almost exclusively wanted for hours/minutes/seconds. But I'm not overall keen on |
Better name suggestion: |
A convenience macro for typesetting time quantities consisting of hours minutes and seconds would be nice, analogous to the
\ang
macro. For example\hms{3;22;15.3}
could output 3 h 22 min 15.3 s,\hms{1.5}
1.5 h and\hms{;15;}
15 min.The text was updated successfully, but these errors were encountered: