This commit is contained in:
Valeria Fadeeva 2025-02-03 11:36:23 +05:00
parent 66f58a3cae
commit 343e5c27ec
1 changed files with 14 additions and 3 deletions

View File

@ -3,12 +3,21 @@
extern crate dotenv;
use fltk::{
app, app::Screen, enums::Color, frame, /*button,*/ image, prelude::*, terminal::Terminal,
app,
app::Screen,
enums::Color,
frame, /*button,*/
image,
prelude::*,
terminal::{/*RedrawStyle,*/ Terminal},
window,
};
use fltk_theme::{
SchemeType, ThemeType, WidgetScheme,
/*ColorTheme, color_themes, widget_themes, */ WidgetTheme,
/*ColorTheme,
color_themes,
widget_themes,*/
WidgetTheme,
};
use tokio::io::{self, AsyncBufReadExt, BufReader};
@ -80,7 +89,7 @@ async fn get_line(
async fn gui() -> io::Result<()> {
// let padding: i32 = 10;
let title_and_panel_h: i32 = 68;
let title_and_panel_h: i32 = 36 * 2;
// let (w, h) = app::screen_size();
// println!("{} {}", w, h);
@ -101,6 +110,7 @@ async fn gui() -> io::Result<()> {
}
}
width = width / 3 * 2 as i32;
height = height - title_and_panel_h;
let app = app::App::default();
@ -127,6 +137,7 @@ async fn gui() -> io::Result<()> {
term.set_color(Color::Background2);
term.set_text_color(Color::Light2);
term.set_history_rows(5000);
// term.set_redraw_style(RedrawStyle::PerWrite);
win.make_resizable(true);
win.end();