Skip to content

Commit 63828e8

Browse files
committed
Add initial support for Miriway
Miriway is a new generic compositor built on the Mir compositor library that is designed to be used as part of composable desktop environments.
1 parent cdf9368 commit 63828e8

File tree

4 files changed

+73
-0
lines changed

4 files changed

+73
-0
lines changed

configurations/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ install(FILES
1717
install(DIRECTORY
1818
labwc
1919
firstrun
20+
miriway
2021
DESTINATION "${CMAKE_INSTALL_DATADIR}/lxqt/wayland"
2122
COMPONENT Runtime
2223
)
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
#!/bin/sh
2+
3+
unset WAYLAND_DISPLAY
4+
unset DISPLAY
5+
6+
port=0
7+
while [ -e "${XDG_RUNTIME_DIR}/wayland-${port}" ]; do
8+
let port+=1
9+
done
10+
wayland_display=wayland-${port}
11+
12+
export WAYLAND_DISPLAY=${wayland_display}
13+
14+
if command -v Xwayland > /dev/null
15+
then
16+
export MIR_SERVER_ENABLE_X11=1
17+
MIR_SERVER_XWAYLAND_PATH=$(which Xwayland)
18+
export MIR_SERVER_XWAYLAND_PATH
19+
fi
20+
21+
export MIRIWAY_CONFIG_DIR="lxqt"
22+
23+
miriway-shell --display-config=static="${XDG_CONFIG_HOME}/miriway-shell.display-config" --add-wayland-extensions=all --lockscreen-app="lxqt-leave --lockscreen" &
24+
miriway_pid=$!
25+
26+
# Wait until the server starts
27+
until [ -O "${XDG_RUNTIME_DIR}/${WAYLAND_DISPLAY}" ]
28+
do
29+
if ! kill -0 ${miriway_pid} &> /dev/null
30+
then
31+
echo "ERROR: miriway-shell [pid=${miriway_pid}] is not running"
32+
exit 1
33+
fi
34+
inotifywait -qq --timeout 5 --event create "$(dirname "${XDG_RUNTIME_DIR}/${WAYLAND_DISPLAY}")"
35+
done
36+
37+
lxqt-session "$@"
38+
lxqt_session_exit_code=$?
39+
40+
kill $miriway_pid
41+
42+
exit $lxqt_session_exit_code
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
x11-window-title=LXQt (Miriway)
2+
idle-timeout=600
3+
4+
shell-component=dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY XDG_SESSION_TYPE XDG_CURRENT_DESKTOP
5+
6+
shell-alt=Space:lxqt-runner
7+
shell-alt=F2:lxqt-runner
8+
shell-meta=l:lxqt-leave --lockscreen
9+
10+
meta=p:pcmanfm-qt
11+
meta=Return:qterminal
12+
meta=f:featherpad
13+
14+
meta=Left:@dock-left
15+
meta=Right:@dock-right
16+
meta=Space:@toggle-maximized
17+
meta=Home:@workspace-begin
18+
meta=End:@workspace-end
19+
meta=Page_Up:@workspace-up
20+
meta=Page_Down:@workspace-down
21+
ctrl-alt=BackSpace:@exit

startlxqtwayland.in

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,15 @@ elif [ "$COMPOSITOR" = "kwin_wayland" ]; then
140140
# WARNING: Option '--no-kactivities' can result in crashes with animations and corner actions.
141141
exec ${COMPOSITOR}_wrapper --exit-with-session lxqt-session --xwayland
142142

143+
elif [ "$COMPOSITOR" = "miriway" ]; then
144+
export XDG_CURRENT_DESKTOP="LXQt:$COMPOSITOR:mir"
145+
if [ ! -f "$XDG_CONFIG_HOME/lxqt/miriway-shell.config" ]; then
146+
cp "$share_dir"/lxqt/wayland/miriway/miriway-shell.config "$XDG_CONFIG_HOME/lxqt/miriway-shell.config"
147+
if echo "$valid_layouts" | grep -q "$trylayout"; then
148+
echo "keymap=$trylayout" >> "$XDG_CONFIG_HOME/lxqt/miriway-shell.config"
149+
fi
150+
exec "${share_dir}/lxqt/wayland/miriway/lxqt-${COMPOSITOR}-wrapper"
151+
143152
elif [ "$COMPOSITOR" = "wayfire" ]; then
144153
if [ ! -f "$XDG_CONFIG_HOME/lxqt/wayland/lxqt-wayfire.ini" ]; then
145154
cp "$share_dir"/lxqt/wayland/lxqt-wayfire.ini "$XDG_CONFIG_HOME"/lxqt/wayland/

0 commit comments

Comments
 (0)