Replies: 3 comments 1 reply
-
@Batalex thanks for this suggestion. How do you see this interfacing with the existing My feeling is that the But I think that your suggested lazy formatting strategy would basically have us remove the How do you imagine users using the Also, I'm not sure the easiest way to implement the |
Beta Was this translation helpful? Give feedback.
-
@Batalex I changed my mind on discussions/issues and I've moved this discussion to an issue here: #114 |
Beta Was this translation helpful? Give feedback.
-
As a matter of separation of responsibilities I think it would be better if the Maybe I could restrict the prefixes/parts-per-forms to be alphabetic and use the presence of alphabetic characters and the end of the string as a signal that a prefix mode has been used. |
Beta Was this translation helpful? Give feedback.
-
The current
sciform
implementation eagerly formats values as soon asFormatter.__call__
is called.This discussion is about making
sciform
implementation lazy so the actual format would happen when the value is printed.Here is a quick look at what it could look like
The example above would be similar to the current implementation, but you could then add
_repr_html_
or_repr_latex_
methods so that your displayed value uses\textsuperscript
in a LaTeX document or<sup></sup>
in a notebook.Beta Was this translation helpful? Give feedback.
All reactions