diff --git a/.gitignore b/.gitignore index 8f4dc499..d9ddf04e 100644 --- a/.gitignore +++ b/.gitignore @@ -21,6 +21,8 @@ clients/sfzprint /vst/download/ +/editor/external/fluentui-system-icons/ + # gh-pages unstaged files: _api/ _site/ diff --git a/editor/CMakeLists.txt b/editor/CMakeLists.txt index 33f99afe..952a0e98 100644 --- a/editor/CMakeLists.txt +++ b/editor/CMakeLists.txt @@ -13,7 +13,7 @@ set(EDITOR_RESOURCES icon_white@2x.png knob48.png knob48@2x.png - Fonts/fluentui-system-regular-20.ttf + Fonts/sfizz-fluentui-system-r20.ttf Fonts/Roboto-Regular.ttf PARENT_SCOPE) diff --git a/editor/resources/Fonts/fluentui-system-regular-20.ttf b/editor/resources/Fonts/sfizz-fluentui-system-r20.ttf similarity index 77% rename from editor/resources/Fonts/fluentui-system-regular-20.ttf rename to editor/resources/Fonts/sfizz-fluentui-system-r20.ttf index 4e838582..dc27711e 100644 Binary files a/editor/resources/Fonts/fluentui-system-regular-20.ttf and b/editor/resources/Fonts/sfizz-fluentui-system-r20.ttf differ diff --git a/editor/src/editor/Editor.cpp b/editor/src/editor/Editor.cpp index 43b012bb..b936065f 100644 --- a/editor/src/editor/Editor.cpp +++ b/editor/src/editor/Editor.cpp @@ -497,7 +497,7 @@ void Editor::Impl::createFrameContents() }; auto createGlyphButton = [this, &theme](UTF8StringPtr glyph, const CRect& bounds, int tag, int fontsize) { STextButton* btn = new STextButton(bounds, this, tag, glyph); - btn->setFont(new CFontDesc("Fluent System Regular W20", fontsize)); + btn->setFont(new CFontDesc("Sfizz Fluent System R20", fontsize)); btn->setTextColor(theme->icon); btn->setHoverColor(theme->iconHighlight); btn->setFrameColor(CColor(0x00, 0x00, 0x00, 0x00)); diff --git a/scripts/generate_ui_fonts.sh b/scripts/generate_ui_fonts.sh new file mode 100755 index 00000000..8b0f48f2 --- /dev/null +++ b/scripts/generate_ui_fonts.sh @@ -0,0 +1,23 @@ +#!/bin/sh +set -e + +if ! test -d "src"; then + echo "Please run this in the project root directory." + exit 1 +fi + +root="`pwd`" +fonts="$root/editor/resources/Fonts" + +if test ! -d editor/external/fluentui-system-icons; then + cd editor/external + git clone https://github.com/sfztools/fluentui-system-icons.git + cd fluentui-system-icons +else + cd editor/external/fluentui-system-icons + git checkout master + git pull origin master +fi + +./generate_icons_font.py -s regular -w 20 -n 'Sfizz Fluent System R20' \ + -o "$fonts/sfizz-fluentui-system-r20.ttf"