Skip to content

Commit

Permalink
linux: Remove Bitstream Vera dependency and mentioning
Browse files Browse the repository at this point in the history
Bitstream Vera is not used/needed anymore, so readme,
tests and configs were adjusted accordingly.
  • Loading branch information
nazar-pc committed Mar 5, 2018
1 parent 294db3b commit 1cbcec0
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 49 deletions.
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,7 @@ SVGinOT Font demos (Firefox only):
The font can be installed for a user or system-wide. Get the latest version
from releases: https://github.com/eosrei/twemoji-color-font/releases

*Note: This requires `Bitstream Vera` is installed and will change your
systems default serif, sans-serif and monospace fonts.*
*Note: This will change your default serif, sans-serif and monospace fonts to `DejaVu`.*

### Change default font on Linux
The default serif, sans-serif and monospace font for most Linux distributions is
Expand Down
3 changes: 1 addition & 2 deletions linux/debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ Architecture: all
Multi-Arch: foreign
Depends:
${misc:Depends},
fontconfig,
ttf-bitstream-vera
fontconfig
Enhances:
firefox
Description: Twitter Emoji color emoji SVGinOT font
Expand Down
13 changes: 4 additions & 9 deletions linux/fontconfig/56-twemoji-color.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,18 @@
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<!--
Twitter Color Emoji SVGinOT Font
Fontconfig fonts.conf for a Bitstream Vera default
Fontconfig fonts.conf for a DejaVu default
https://github.com/eosrei/twemoji-color-font
The DejaVu font family is based on the Bitstream Vera font family to provide
The DejaVu font family is based on the DejaVu font family to provide
greater unicode coverage. The only way to override the emoji it includes is
to make the emoji font the primary system font. This shouldn't be a problem,
but a number of programs do not correctly use font fallback resulting in font
rendering errors everywhere.
This font.conf makes Bitstream Vera the default font for Serif, Sans-Serif,
and Monospace font requests since it does not contain any Unicode Emoji
characters. Twitter Color Emoji font is the first fallback, followed by DejaVu
(or whatever the existing default is) to provide everything else.
Install required fonts with:
sudo apt-get install ttf-bitstream-vera
This font.conf makes DejaVu the default font for Serif, Sans-Serif,
and Monospace font requests.
Test with:
fc-match -s serif
Expand Down
10 changes: 1 addition & 9 deletions linux/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,7 @@
#https://github.com/eosrei/twemoji-color-font
echo "Twitter Color Emoji font installer for Linux\n"

# Check for Bitstream Vera
fc-list | grep "Bitstream Vera" > /dev/null
RETURN=$?
if [ $RETURN -ne 0 ];then
echo "Bitstream Vera font family not found. Please install it:"
echo "sudo apt-get install ttf-bitstream-vera"
exit 1
fi
echo "NOTE: Changing default font family to Bitstream Vera"
echo "NOTE: Changing default font family to DejaVu"

# Stop on errors
set -e
Expand Down
32 changes: 10 additions & 22 deletions linux/tests/expected-results.test
Original file line number Diff line number Diff line change
@@ -1,52 +1,40 @@
Font: sans
Vera.ttf: "Bitstream Vera Sans" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
DejaVuSans.ttf: "DejaVu Sans" "Book"

Font: sans-serif
Vera.ttf: "Bitstream Vera Sans" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
DejaVuSans.ttf: "DejaVu Sans" "Book"

Font: serif
VeraSe.ttf: "Bitstream Vera Serif" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
DejaVuSerif.ttf: "DejaVu Serif" "Book"

Font: mono
VeraMono.ttf: "Bitstream Vera Sans Mono" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
DejaVuSansMono.ttf: "DejaVu Sans Mono" "Book"

Font: monospace
VeraMono.ttf: "Bitstream Vera Sans Mono" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"

Font: Bitstream Vera Sans
Vera.ttf: "Bitstream Vera Sans" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"

Font: Bitstream Vera Serif
VeraSe.ttf: "Bitstream Vera Serif" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"

Font: Bitstream Vera Sans Mono
VeraMono.ttf: "Bitstream Vera Sans Mono" "Roman"
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
DejaVuSansMono.ttf: "DejaVu Sans Mono" "Book"

Font: emoji
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
Vera.ttf: "Bitstream Vera Sans" "Roman"
DejaVuSans.ttf: "DejaVu Sans" "Book"

Font: Twitter Color Emoji
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
Vera.ttf: "Bitstream Vera Sans" "Roman"
DejaVuSans.ttf: "DejaVu Sans" "Book"

Font: Apple Color Emoji
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
Vera.ttf: "Bitstream Vera Sans" "Roman"
DejaVuSans.ttf: "DejaVu Sans" "Book"

Font: Segoe UI Emoji
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
Vera.ttf: "Bitstream Vera Sans" "Roman"
DejaVuSans.ttf: "DejaVu Sans" "Book"

Font: Noto Color Emoji
TwitterColorEmoji-SVGinOT.ttf: "Twitter Color Emoji" "Regular"
Vera.ttf: "Bitstream Vera Sans" "Roman"
DejaVuSans.ttf: "DejaVu Sans" "Book"

3 changes: 0 additions & 3 deletions linux/tests/tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ FONTS[1]="sans-serif"
FONTS[2]="serif"
FONTS[3]="mono"
FONTS[4]="monospace"
FONTS[5]="Bitstream Vera Sans"
FONTS[6]="Bitstream Vera Serif"
FONTS[7]="Bitstream Vera Sans Mono"
FONTS[8]="emoji"
FONTS[9]="Twitter Color Emoji"
FONTS[10]="Apple Color Emoji"
Expand Down
2 changes: 1 addition & 1 deletion scfbuild-osx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ glyph_translate_y: 150
# Glyphs height is 2048, SVGs height is 45 x 2.048.
# color_transform(y) = - 150/2048*45*2.048
color_transform: translate(0 -6.75)
# Space width matching DejaVu Sans and Bitstream Vera Sans.
# Space width matching DejaVu Sans.
width_space: 561
table_name:
copyright: >
Expand Down
2 changes: 1 addition & 1 deletion scfbuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ glyph_translate_y: 150
# Glyphs height is 2048, SVGs height is 45 x 2.048.
# color_transform(y) = - 150/2048*45*2.048
color_transform: translate(0 -6.75)
# Space width matching DejaVu Sans and Bitstream Vera Sans.
# Space width matching DejaVu Sans.
width_space: 561
table_name:
copyright: >
Expand Down

0 comments on commit 1cbcec0

Please sign in to comment.