mirror of
https://github.com/damus-io/notecrumbs.git
synced 2024-09-20 21:56:33 +00:00
fonts: move font logic elsewhere for now
We will get back to this, can't get it working atm
This commit is contained in:
parent
cf6724bc57
commit
85ce25f48d
23
src/fonts.rs
Normal file
23
src/fonts.rs
Normal file
@ -0,0 +1,23 @@
|
||||
// TODO: figure out the custom font situation
|
||||
|
||||
/*
|
||||
fn setup_fonts(font_data: &egui::FontData, ctx: &egui::Context) {
|
||||
let mut fonts = egui::FontDefinitions::default();
|
||||
|
||||
// Install my own font (maybe supporting non-latin characters).
|
||||
// .ttf and .otf files supported.
|
||||
fonts
|
||||
.font_data
|
||||
.insert("my_font".to_owned(), font_data.clone());
|
||||
|
||||
// Put my font first (highest priority) for proportional text:
|
||||
fonts
|
||||
.families
|
||||
.entry(egui::FontFamily::Proportional)
|
||||
.or_default()
|
||||
.insert(0, "my_font".to_owned());
|
||||
|
||||
// Tell egui to use these fonts:
|
||||
ctx.set_fonts(fonts);
|
||||
}
|
||||
*/
|
21
src/main.rs
21
src/main.rs
@ -31,27 +31,6 @@ fn nip19_evid(nip19: &Nip19) -> Option<EventId> {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
fn setup_fonts(font_data: &egui::FontData, ctx: &egui::Context) {
|
||||
let mut fonts = egui::FontDefinitions::default();
|
||||
|
||||
// Install my own font (maybe supporting non-latin characters).
|
||||
// .ttf and .otf files supported.
|
||||
fonts
|
||||
.font_data
|
||||
.insert("my_font".to_owned(), font_data.clone());
|
||||
|
||||
// Put my font first (highest priority) for proportional text:
|
||||
fonts
|
||||
.families
|
||||
.entry(egui::FontFamily::Proportional)
|
||||
.or_default()
|
||||
.insert(0, "my_font".to_owned());
|
||||
|
||||
// Tell egui to use these fonts:
|
||||
ctx.set_fonts(fonts);
|
||||
}
|
||||
*/
|
||||
|
||||
fn render_note<'a>(_app_ctx: &Context, note: &'a Note) -> Vec<u8> {
|
||||
use egui::{FontId, RichText};
|
||||
|
Loading…
Reference in New Issue
Block a user