Add max_width to Column in iced_pure

This commit is contained in:
Héctor Ramón Jiménez 2022-02-12 18:02:29 +07:00
parent 4c61601aa3
commit 09c96a6d81
No known key found for this signature in database
GPG key ID: 140CC052C94F138E
2 changed files with 23 additions and 2 deletions

View file

@ -3,11 +3,18 @@ use iced::pure::widget::{
button, checkbox, column, container, row, scrollable, text, text_input,
};
use iced::pure::{Application, Element, Text};
use iced::window;
use iced::{Command, Font, Length, Settings};
use serde::{Deserialize, Serialize};
pub fn main() -> iced::Result {
Todos::run(Settings::default())
Todos::run(Settings {
window: window::Settings {
size: (500, 800),
..window::Settings::default()
},
..Settings::default()
})
}
#[derive(Debug)]
@ -184,6 +191,7 @@ impl Application for Todos {
let content = column()
.spacing(20)
.max_width(800)
.push(title)
.push(input)
.push(controls)