parent
c9223dcad6
commit
f051d23a30
3 changed files with 2 additions and 10 deletions
|
@ -248,9 +248,6 @@ pub struct Config {
|
||||||
#[clap(short = 'O', long = "sort-order")] // todo support this
|
#[clap(short = 'O', long = "sort-order")] // todo support this
|
||||||
sort_order: Option<String>,
|
sort_order: Option<String>,
|
||||||
|
|
||||||
#[clap(short = 'G', long = "gtk-dark")]
|
|
||||||
gtk_dark: Option<bool>, // todo support this
|
|
||||||
|
|
||||||
#[clap(short = 'Q', long = "search")]
|
#[clap(short = 'Q', long = "search")]
|
||||||
search: Option<String>, // todo support this
|
search: Option<String>, // todo support this
|
||||||
|
|
||||||
|
|
|
@ -19,11 +19,7 @@ use gtk4::prelude::{
|
||||||
ApplicationExt, ApplicationExtManual, BoxExt, EditableExt, FlowBoxChildExt, GestureSingleExt,
|
ApplicationExt, ApplicationExtManual, BoxExt, EditableExt, FlowBoxChildExt, GestureSingleExt,
|
||||||
GtkWindowExt, ListBoxRowExt, NativeExt, OrientableExt, WidgetExt,
|
GtkWindowExt, ListBoxRowExt, NativeExt, OrientableExt, WidgetExt,
|
||||||
};
|
};
|
||||||
use gtk4::{
|
use gtk4::{Align, EventControllerKey, Expander, FlowBox, FlowBoxChild, GestureClick, Image, Label, ListBox, ListBoxRow, NaturalWrapMode, Ordering, PolicyType, ScrolledWindow, SearchEntry, Widget, gdk};
|
||||||
Align, EventControllerKey, Expander, FlowBox, FlowBoxChild, GestureClick, Image, Label,
|
|
||||||
ListBox, ListBoxRow, NaturalWrapMode, Ordering, PolicyType, ScrolledWindow, SearchEntry,
|
|
||||||
Widget, gdk,
|
|
||||||
};
|
|
||||||
use gtk4::{Application, ApplicationWindow, CssProvider, Orientation};
|
use gtk4::{Application, ApplicationWindow, CssProvider, Orientation};
|
||||||
use gtk4_layer_shell::{Edge, KeyboardMode, LayerShell};
|
use gtk4_layer_shell::{Edge, KeyboardMode, LayerShell};
|
||||||
use log;
|
use log;
|
||||||
|
@ -163,6 +159,7 @@ where
|
||||||
T: Clone + 'static + Send,
|
T: Clone + 'static + Send,
|
||||||
P: ItemProvider<T> + 'static + Clone + Send,
|
P: ItemProvider<T> + 'static + Clone + Send,
|
||||||
{
|
{
|
||||||
|
gtk4::init()?;
|
||||||
log::debug!("Starting GUI");
|
log::debug!("Starting GUI");
|
||||||
if let Some(ref css) = config.style() {
|
if let Some(ref css) = config.style() {
|
||||||
let provider = CssProvider::new();
|
let provider = CssProvider::new();
|
||||||
|
|
|
@ -4,8 +4,6 @@ use anyhow::anyhow;
|
||||||
use worf_lib::config::Mode;
|
use worf_lib::config::Mode;
|
||||||
use worf_lib::{config, mode};
|
use worf_lib::{config, mode};
|
||||||
fn main() -> anyhow::Result<()> {
|
fn main() -> anyhow::Result<()> {
|
||||||
gtk4::init()?;
|
|
||||||
|
|
||||||
env_logger::Builder::new()
|
env_logger::Builder::new()
|
||||||
.parse_filters(&env::var("RUST_LOG").unwrap_or_else(|_| "error".to_owned()))
|
.parse_filters(&env::var("RUST_LOG").unwrap_or_else(|_| "error".to_owned()))
|
||||||
.format_timestamp_micros()
|
.format_timestamp_micros()
|
||||||
|
|
Loading…
Add table
Reference in a new issue