mirror of
https://github.com/hyprwm/hyprland-wiki.git
synced 2024-11-05 13:05:59 +01:00
105 lines
3.8 KiB
Markdown
105 lines
3.8 KiB
Markdown
|
|
||
|
After you've installed Hyprland, you can either launch it from a TTY with
|
||
|
`Hyprland` or from a login manager. Although login managers aren't officially
|
||
|
supported, I recommend `SDDM`, as it's been working flawlessly with wayland
|
||
|
compositors.
|
||
|
|
||
|
It is recommended you have `kitty` for terminal access, (example and autogenerated configs have it bound to SUPER+Q) or for you to manually change it in the config before launching hyprland.
|
||
|
|
||
|
If you have an Nvidia card, please also take a look at [The nvidia page](https://github.com/hyprwm/Hyprland/wiki/Nvidia) before launching. You should **first** make a wrapper, as described in the section below, then follow the instructions from the Nvidia page, and then continue on with sections below.
|
||
|
|
||
|
## Wrapping the launcher (recommended)
|
||
|
With Xorg, you get the `.xinitrc`. With Hyprland, you can create your own... kind of.
|
||
|
|
||
|
Make an executable file somewhere in your `PATH`, for example `~/.local/bin/`, called (for example) `wrappedHl`
|
||
|
|
||
|
In it, put:
|
||
|
```
|
||
|
#!/bin/bash
|
||
|
|
||
|
cd ~
|
||
|
|
||
|
export _JAVA_AWT_WM_NONREPARENTING=1
|
||
|
export XCURSOR_SIZE=24
|
||
|
|
||
|
exec Hyprland
|
||
|
```
|
||
|
|
||
|
you can add as many exported envvars as you need (nvidia users might need a lot), but I recommend to have *at least* the shown two. You can also change the shell you launch this with, although it shouldn't matter.
|
||
|
|
||
|
You should now launch Hyprland with `wrappedHl` instead of `Hyprland`. Make sure to edit your .desktop file in `/usr/share/wayland-sessions/` if you use a login manager! (You might need to put the full path in it, as login managers are usually not ran through the user account)
|
||
|
|
||
|
## Immediate
|
||
|
|
||
|
**OMG MY SCREEN IS BROKEN, FLASHY TEARY!** -> see the bottom of this page
|
||
|
|
||
|
Once you log in, you'll be greeted with a yellow warning that will give you some
|
||
|
basic keybind info of your pregenerated config.
|
||
|
|
||
|
I recommend you use the config provided in `examples/hyprland.conf` though.
|
||
|
|
||
|
Paste it into `~/.config/hypr/hyprland.conf`
|
||
|
|
||
|
You can, of course, start from the pregenerated config if you wish to. If you
|
||
|
want the warning to go away, remove the `autogenerated=1` line.
|
||
|
|
||
|
## Monitors
|
||
|
|
||
|
Use `hyprctl monitors` to list available outputs.
|
||
|
|
||
|
Then, you can configure your outputs with
|
||
|
|
||
|
```
|
||
|
hyprctl keyword monitor NAME,RES@HZ,OFFSET,SCALE
|
||
|
```
|
||
|
|
||
|
`NAME` is the name of the display, e.g. `DP-1`, can be empty for a global rule.
|
||
|
|
||
|
`RES@HZ` is the resolution and refresh rate, e.g. `1920x1080@144`
|
||
|
|
||
|
`OFFSET` is the position of the monitor, e.g. `0x0`
|
||
|
|
||
|
`SCALE` is the display scale, e.g. `1`
|
||
|
|
||
|
example command:
|
||
|
|
||
|
```
|
||
|
hyprctl keyword monitor DP-3,1920x1080@240,1920x0,1
|
||
|
```
|
||
|
|
||
|
**Warning!** These changes are **not** permanent! If you want to make those
|
||
|
changes persist, configure your outputs in the config!
|
||
|
|
||
|
# Proper configuring
|
||
|
|
||
|
Head onto the
|
||
|
[Master Configuring Wiki Page](https://github.com/hyprwm/Hyprland/wiki/Configuring-Hyprland)
|
||
|
to learn all about configuring Hyprland to your likings.
|
||
|
|
||
|
# Apps / X11 replacements
|
||
|
|
||
|
See the [Useful Utilities Page](https://github.com/hyprwm/Hyprland/wiki/Useful-utilities) and the
|
||
|
[Sway wiki page](https://github.com/swaywm/sway/wiki/Useful-add-ons-for-sway)
|
||
|
just about that.
|
||
|
|
||
|
# Screen broken on launch
|
||
|
|
||
|
This usually happens due to your monitor not being very happy about the default
|
||
|
settings.
|
||
|
|
||
|
You can get your monitor's name(s) from the TTY.
|
||
|
|
||
|
Exit hyprland, and then:
|
||
|
|
||
|
- `cat /tmp/hypr/$(ls -t /tmp/hypr | head -n 1)/hyprland.log | grep monitor`
|
||
|
will give you a bunch of logs about the connected monitors. Names like `DP-x`
|
||
|
or `HDMI-x` etc are your monitor names.
|
||
|
- edit (with your favorite text editor) `~/.config/hypr/hyprland.conf`
|
||
|
- replace the `monitor=` line with `monitor=NAME,RES@Hz,OFFSET,SCALE`, for
|
||
|
example `monitor=DP-1,1920x1080@60,0x0,1` (See the above section titled
|
||
|
Monitors for more info about the values) You can also add multiple of those
|
||
|
for multi-mon setups.
|
||
|
|
||
|
After this, upon launching Hyprland again, provided you set an appropriate mode
|
||
|
for your monitors, everything should be fine.
|