Allow configuration of default font

This commit is contained in:
Héctor Ramón Jiménez 2020-01-01 17:49:48 +01:00
parent e1062a02d1
commit d96ced8e2d
8 changed files with 39 additions and 14 deletions

View file

@ -81,8 +81,10 @@ pub trait Application: Sized {
/// It should probably be that last thing you call in your `main` function.
///
/// [`Application`]: trait.Application.html
fn run(settings: Settings)
where
fn run(
settings: Settings,
renderer_settings: <Self::Renderer as Windowed>::Settings,
) where
Self: 'static,
{
use winit::{
@ -140,7 +142,7 @@ pub trait Application: Sized {
let mut resized = false;
let clipboard = Clipboard::new(&window);
let mut renderer = Self::Renderer::new();
let mut renderer = Self::Renderer::new(renderer_settings);
let mut target = {
let (width, height) = to_physical(size, dpi);