Change map font

This commit is contained in:
Liam Steckler 2025-05-03 15:33:56 -07:00
parent fe0910bd39
commit e0eff21265
4 changed files with 94 additions and 116 deletions

BIN
fonts/Cabin-Regular.ttf Normal file

Binary file not shown.

View file

@ -1,31 +1,10 @@
This repository is a fork of Libre Franklin: https://github.com/impallari/Libre-Franklin Copyright 2018 The Cabin Project Authors (https://github.com/impallari/Cabin.git)
## License for USWDSs Modified Version
This repository contains both the original font software for Libre Franklin (the “Original Version”) and font software modifications made by the General Services Administration (GSA). This repository combines the Original Version and these GSA modifications into a piece of font software called Public Sans, which is a “Modified Version” of Libre Franklin.
As a work of the United States Government, the font software modifications made by GSA are not subject to copyright within the United States. Additionally, GSA waives copyright and related rights in its font software modifications worldwide through the [CC0 1.0 Universal public domain dedication](https://creativecommons.org/publicdomain/zero/1.0/).
The Original Version (as defined in the SIL Open Font License, Version 1.1) remains subject to copyright under the SIL Open Font License, Version 1.1.
This Modified Version (Public Sans) contains both software under the SIL Open Font License, Version 1.1 and software modifications by GSA released as CC0. As a work of the United States Government, the software modifications made by GSA are not subject to copyright within the United States. Additionally, GSA waives copyright and related rights in its software modifications worldwide through the [CC0 1.0 Universal Public Domain Dedication](https://creativecommons.org/publicdomain/zero/1.0/). It is a “joint work” made of the original software and modifications combined into a single work.
**In practice, users of this Modified Version (Public Sans) should use Public Sans according to the terms of the SIL Open Font License, Version 1.1, below.** This is because this font is a combination of work subject to copyright and work not subject to copyright, so the more restrictive requirements apply to using the combined work.
## License of project USWDSs Modified Version is based on
- Libre Franklin is licensed under the SIL Open Font License, Version 1.1 (<http://scripts.sil.org/OFL>)
- To view the copyright and specific terms and conditions of Libre Franklin, please refer to [OFL.txt](https://github.com/impallari/Libre-Franklin/blob/master/OFL.txt)
## SIL Open Font License, Version 1.1
Copyright 2015 The Public Sans Project Authors (https://github.com/uswds/public-sans)
This Font Software is licensed under the SIL Open Font License, Version 1.1. This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at:
https://openfontlicense.org
This license is copied below, and is also available with a FAQ at http://scripts.sil.org/OFL
```
----------------------------------------------------------- -----------------------------------------------------------
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
----------------------------------------------------------- -----------------------------------------------------------
@ -112,4 +91,3 @@ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE. OTHER DEALINGS IN THE FONT SOFTWARE.
```

Binary file not shown.

2
scl.py
View file

@ -47,7 +47,7 @@ class AttribStaticMap(staticmap.StaticMap, object):
super(AttribStaticMap, self)._draw_features(image) super(AttribStaticMap, self)._draw_features(image)
txt = Image.new("RGBA", image.size, (255, 255, 255, 0)) txt = Image.new("RGBA", image.size, (255, 255, 255, 0))
fnt = ImageFont.truetype("fonts/PublicSans-Regular.otf", 24) fnt = ImageFont.truetype("fonts/Cabin-Regular.ttf", 24)
d = ImageDraw.Draw(txt) d = ImageDraw.Draw(txt)
textSize = fnt.getbbox(self.attribution) textSize = fnt.getbbox(self.attribution)