Add a bunch of TODOs
This commit is contained in:
parent
4c79064760
commit
bf59455097
6 changed files with 12 additions and 4 deletions
|
@ -16,7 +16,7 @@ pub struct State {
|
|||
pub size: Vec2,
|
||||
}
|
||||
|
||||
// TODO: rename Floating to something else.
|
||||
// TODO: rename Floating to something else. Area?
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
pub struct Floating {
|
||||
id: Id,
|
||||
|
|
|
@ -6,6 +6,7 @@ pub struct State {
|
|||
pub size: Vec2,
|
||||
}
|
||||
|
||||
// TODO: auto-shink/grow should be part of another container!
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
pub struct Resize {
|
||||
/// If false, we are no enabled
|
||||
|
|
|
@ -159,6 +159,7 @@ impl Font {
|
|||
}
|
||||
|
||||
/// Height of one line of text. In points
|
||||
/// TODO: rename height ?
|
||||
pub fn line_spacing(&self) -> f32 {
|
||||
self.scale_in_pixels / self.pixels_per_point
|
||||
}
|
||||
|
|
|
@ -83,10 +83,12 @@ impl Fonts {
|
|||
|
||||
// TODO: figure out a way to make the wasm smaller despite including a font. Zip it?
|
||||
let monospae_typeface_data = include_bytes!("../fonts/ProggyClean.ttf"); // Use 13 for this. NOTHING ELSE.
|
||||
// let monospae_typeface_data = include_bytes!("../fonts/Roboto-Regular.ttf");
|
||||
|
||||
// let variable_typeface_data = include_bytes!("../fonts/Comfortaa-Regular.ttf"); // Funny, hard to read
|
||||
let variable_typeface_data = include_bytes!("../fonts/DejaVuSans.ttf"); // Basic, boring
|
||||
// let monospae_typeface_data = include_bytes!("../fonts/Roboto-Regular.ttf");
|
||||
|
||||
let variable_typeface_data = include_bytes!("../fonts/Comfortaa-Regular.ttf"); // Funny, hard to read
|
||||
|
||||
// let variable_typeface_data = include_bytes!("../fonts/DejaVuSans.ttf"); // Basic, boring, takes up more space
|
||||
|
||||
self.definitions = definitions.clone();
|
||||
self.fonts = definitions
|
||||
|
|
|
@ -43,6 +43,8 @@ pub struct RawInput {
|
|||
/// What emigui maintains
|
||||
#[derive(Clone, Debug, Default)]
|
||||
pub struct GuiInput {
|
||||
// TODO: mouse: Mouse as separate
|
||||
//
|
||||
/// Is the button currently down?
|
||||
/// true the frame when it is pressed,
|
||||
/// false the frame it is released.
|
||||
|
|
|
@ -14,6 +14,7 @@ pub use text_edit::*;
|
|||
|
||||
/// Anything implementing Widget can be added to a Region with Region::add
|
||||
pub trait Widget {
|
||||
// TODO: rename .ui(
|
||||
fn add_to(self, region: &mut Region) -> GuiResponse;
|
||||
}
|
||||
|
||||
|
@ -316,6 +317,7 @@ type SliderGetSet<'a> = Box<dyn 'a + FnMut(Option<f32>) -> f32>;
|
|||
pub struct Slider<'a> {
|
||||
get_set_value: SliderGetSet<'a>,
|
||||
range: RangeInclusive<f32>,
|
||||
// TODO: label: Option<Label>
|
||||
text: Option<String>,
|
||||
precision: usize,
|
||||
text_color: Option<Color>,
|
||||
|
|
Loading…
Reference in a new issue