Comments (11)
I hope this is what you want:
The code can be found in test/font-test.tex
.
from firamath.
Still I need to point out that, the tabular numbers in Fira Sans do look like that in Fira Mono, but they are actually not exactly identical (you may check the paths and points' position). Whether 1
has serif or not and whether 4
is closed or open, are both determined by the original design of Fira Sans.
You may try the following code, and I never use Fira Mono here:
\documentclass{article}
\usepackage{fontspec}
\setsansfont{FiraSans-Regular.otf}
\begin{document}
\sffamily
\verb|default | 0123456789 \par
\verb|lnum | {\addfontfeature{Numbers=Lining} 0123456789} \par
\verb|onum | {\addfontfeature{Numbers=OldStyle} 0123456789} \par
\verb|pnum | {\addfontfeature{Numbers=Proportional} 0123456789} \par
\verb|tnum | {\addfontfeature{Numbers=Monospaced} 0123456789} \par
\verb|lnum+pnum | {\addfontfeature{Numbers=Lining,Numbers=Proportional} 0123456789} \par
\verb|onum+pnum | {\addfontfeature{Numbers=OldStyle,Numbers=Proportional} 0123456789} \par
\verb|lnum+tnum | {\addfontfeature{Numbers=Lining,Numbers=Monospaced} 0123456789} \par
\verb|onum+tnum | {\addfontfeature{Numbers=OldStyle,Numbers=Monospaced} 0123456789}
\end{document}
Anyway, I can add both serif/sans serif 1
and closed/open 4
as different stylistic sets.
from firamath.
I don't think that using mono-spaced (or tabular) numbers in math mode is a good choice. But I can still add this feature, as well as the old style and tabular old style numbers.
By the way, FiraSans already has tabular numbers, and it looks like FiraMono (e.g. 1
has a serif), but not Fira Mono.
from firamath.
As far as I notice, in MS Word, other math fonts like Latin Modern Math, Libertinus Math and Cambria Math all use monospaced numbers by default (in and out of math mode), and for LM Math the width is of exactly 1 \ensp, which makes them easy to be aligned in column. I do not know the details of the mapping, or whether it has something to do with the serif font style, but it seems not a bad idea to have monospaced numbers in math font by default?
from firamath.
from firamath.
Have checked several fonts. I will make the numbers to be mono-spaced by default then.
from firamath.
Thank you for all the positive comments!
To clarify my original post, I was suggesting adjusting the bounding width (not the font). Right now, text tabular figures (old style and lining) are Fira Mono, while text proportional figures (old style and lining) are Fira Sans. IMHO, making mono-spaced math figures by changing figures to Fira Mono look-alike is a bad idea (e.g., the serif 1
in a sans font). The glyphs should stay the same except for their widths.
from firamath.
This is more than perfect! I noticed the extra effort made to guarantee that bold figures share the same width with the regular ones.
Is the decimal point .
(or ,
in some other countries) in regular and bold weights of the same width too?
from firamath.
In Fira Math, period and .
comma ,
have the same width (240/1000 em), but not the same as digits (560/1000 em). They do not have bold version (I mean in fira-math-regular
).
In XITS Math and Latin Modern Math, the width of .
and ,
is exactly one half of the digits, but I think it's more likely to be a design, rather than a convention or a standard.
from firamath.
Thank you for the detailed explanation. I absolutely agree that it’s a matter of design. It doesn’t matter if .
and ,
are of the same width with the digits, as long as they are consistent. You may want to make bold .
and bold ,
to be 240/1000 em wide (in future releases like FiraMath-Bold
).
from firamath.
I did not check the widths, but it would also be nice if mid space (U+2005) [or thin space (U+2009)] and narrow no-break space (U+202F) were also the same width and .
and ,
to ensure consistency if the SI-standard space is used as a digit-group separator rather than .
or ,
.
from firamath.
Related Issues (20)
- List of supported glyphs? HOT 1
- Can't build on `glyphs3` branch HOT 1
- How to get firamath used with \boldsymbol and/or \bm HOT 3
- Other weights of Fira Math(like Light or Bold) are lack of some characters HOT 1
- Add support for \mathcal and \mathscr fonts? HOT 1
- Could not build wheels for openstep-plist which use PEP 517 and cannot be installed directly HOT 2
- Fix combining lines
- The thin/regular/medium/bold/extrabold etc. are marked as thin HOT 6
- Incorrect integrals on the master version. HOT 4
- All build artifacts are expired HOT 4
- Sync with glyphsLib v6.0.0
- encoding of phi and varphi HOT 1
- U+2218 Ring operator (\circ) is very small HOT 1
- Document use with LibreOffice Math
- \wideoverbar not working fine
- 'Build from source' instructions not working HOT 1
- \overrightarrow as same as \vec, and can not adjust length.
- \vdots and \ddots are missing HOT 1
- Incorrect Radical/Square Root containing Fractions HOT 7
- \setminus glyph missing HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from firamath.