Repository: versotile-org/verso
File: src/config.rs (Rust)

Code before:
    let mut opts = getopts::Options::new();
    opts.optopt("", "url", "URL to load on start", "URL");
    opts.optopt(
        "",
        "ipc-channel",
        "IPC channel name to communicate and control verso",
        "",
    );
    opts.optflag("", "no-panel", "Launch Verso without control panel");

    opts.optopt(
        "w",
        "width",
        "Initial window's width in physical unit, the height command line arg much also be set",
        "",
    );
    opts.optopt(
        "h",
        "height",
        "Initial window's height in physical unit, the width command line arg much also be set",
        "",
    );
    opts.optopt(
        "",
        "x",
        "Initial window's top left x position in physical unit, the y command line arg much also be set, ignored on wayland",
        "",
    );
    opts.optopt(
        "",
        "y",
        "Initial window's top left y position in physical unit, the x command line arg much also be set, ignored on wayland",
        "",
    );

    let matches: getopts::Matches = opts.parse(&args[1..])?;
    let url = matches
        .opt_str("url")
        .and_then(|url| match url::Url::parse(&url) {
            Ok(url_parsed) => Some(url_parsed),
            Err(e) => {
                if e == url::ParseError::RelativeUrlWithoutBase {
                    if let Ok(url_parsed) = url::Url::parse(&format!("https://{url}")) {
                        return Some(url_parsed);
                    }
                }
                log::error!("Invalid initial url: {url}");
                None
            }
        });
    let ipc_channel = matches.opt_str("ipc-channel");

Review comment (suggestion):
```suggestion
        "Initial window's top left x position in physical unit, the y command line arg must also be set. Wayland isn't supported.",
```

Code after:
    let mut opts = getopts::Options::new();
    opts.optopt("", "url", "URL to load on start", "URL");
    opts.optopt(
        "",
        "ipc-channel",
        "IPC channel name to communicate and control verso",
        "",
    );
    opts.optflag("", "no-panel", "Launch Verso without control panel");

    opts.optopt(
        "w",
        "width",
        "Initial window's width in physical unit, the height command line arg must also be set",
        "",
    );
    opts.optopt(
        "h",
        "height",
        "Initial window's height in physical unit, the width command line arg must also be set",
        "",
    );
    opts.optopt(
        "",
        "x",
        "Initial window's top left x position in physical unit, the y command line arg must also be set. Wayland isn't supported.",
        "",
    );
    opts.optopt(
        "",
        "y",
        "Initial window's top left y position in physical unit, the x command line arg must also be set. Wayland isn't supported.",
        "",
    );

    let matches: getopts::Matches = opts.parse(&args[1..])?;
    let url = matches
        .opt_str("url")
        .and_then(|url| match url::Url::parse(&url) {
            Ok(url_parsed) => Some(url_parsed),
            Err(e) => {
                if e == url::ParseError::RelativeUrlWithoutBase {
                    if let Ok(url_parsed) = url::Url::parse(&format!("https://{url}")) {
                        return Some(url_parsed);
                    }
                }
                log::error!("Invalid initial url: {url}");
                None
            }
        });
    let ipc_channel = matches.opt_str("ipc-channel");