1
0
mirror of https://github.com/lxsang/meta-rpi-diya.git synced 2024-07-26 01:33:50 +02:00

add and use wtype

This commit is contained in:
DanyLE 2023-07-27 20:41:44 +02:00
parent 9565699a58
commit f84ca2b690
5 changed files with 76 additions and 38 deletions

View File

@ -33,7 +33,7 @@ IMAGE_INSTALL:append = "libcurl \
glew \ glew \
freetype \ freetype \
fontconfig \ fontconfig \
librsvg librsvg-gtk rsvg \ librsvg librsvg-gtk \
gdk-pixbuf \ gdk-pixbuf \
gtk-layer-shell \ gtk-layer-shell \
mesa \ mesa \
@ -51,7 +51,7 @@ IMAGE_INSTALL:append = "libcurl \
rsync \ rsync \
coreutils \ coreutils \
wayland wayland-protocols \ wayland wayland-protocols \
labwc foot swaybg swayidle swaylock wlr-randr wlopm sfwbar tofi \ labwc foot swaybg swayidle swaylock wlr-randr wlopm sfwbar tofi wtype \
gdbserver \ gdbserver \
" "

View File

@ -10,7 +10,7 @@ switcher {
function("SfwbarInit") { function("SfwbarInit") {
SetBarId "bar-0" SetBarId "bar-0"
SetLayer "top" SetLayer "bottom"
} }
function("ToggleMinimize") { function("ToggleMinimize") {
@ -72,10 +72,10 @@ function("ShowDesktop") {
} }
menu("winops") { menu("winops") {
item("focus", Focus ); item("Focus", Focus );
item("close", Close ); item("Close", Close );
item("(un)minimize", Function "ToggleMinimize" ); item("Toggle minimize", Function "ToggleMinimize" );
item("(un)maximize", Function "ToggleMaximize" ); item("Toggle maximize", Function "ToggleMaximize" );
} }
# Panel layout # Panel layout
@ -84,7 +84,12 @@ layout {
button { button {
style = "launcher" style = "launcher"
value = "/usr/share/icons/Adwaita/scalable/actions/view-app-grid-symbolic.svg" value = "/usr/share/icons/Adwaita/scalable/actions/view-app-grid-symbolic.svg"
tooltip = "Quick menu" action = Exec "wtype -M alt ' ' -m alt"
}
button {
style = "launcher"
value = "/usr/share/icons/Adwaita/scalable/actions/system-run-symbolic.svg"
tooltip = "Quick run"
action = Exec "bash -c \"`tofi-drun`\"" action = Exec "bash -c \"`tofi-drun`\""
} }
button { button {

View File

@ -0,0 +1,17 @@
DESCRIPTION = "virtual key event for wayland"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
DEPENDS = "wayland wayland-native wayland-protocols-native wayland-protocols libxkbcommon"
SRCREV = "${AUTOREV}"
SRC_URI = "git://github.com/atx/wtype.git;protocol=https;branch=master"
S="${WORKDIR}/git"
inherit meson pkgconfig
EXTRA_OEMESON += "--buildtype release"

View File

@ -3,44 +3,47 @@
<openbox_menu> <openbox_menu>
<menu id="client-menu"> <menu id="client-menu">
<item label="Minimize"> <item label="Minimize">
<action name="Iconify" /> <action name="Iconify" />
</item> </item>
<item label="Maximize"> <item label="Maximize">
<action name="ToggleMaximize" /> <action name="ToggleMaximize" />
</item> </item>
<item label="Fullscreen"> <item label="Fullscreen">
<action name="ToggleFullscreen" /> <action name="ToggleFullscreen" />
</item> </item>
<item label="AlwaysOnTop"> <item label="Always on top">
<action name="ToggleAlwaysOnTop" /> <action name="ToggleAlwaysOnTop" />
</item> </item>
<item label="Close"> <item label="Close">
<action name="Close"/> <action name="Close"/>
</item> </item>
</menu> </menu>
<menu id="root-menu"> <menu id="root-menu">
<item label="Terminal"> <item label="Terminal">
<action name="Execute" command="foot -t xterm-256color" /> <action name="Execute" command="foot -t xterm-256color" />
</item> </item>
<item label="Reconfigure"> <item label="Reconfigure">
<action name="Reconfigure" /> <action name="Reconfigure" />
</item> </item>
<item label="Exit"> <item label="Exit">
<action name="Exit" /> <action name="Exit" />
</item> </item>
<item label="Poweroff"> <item label="Reboot">
<action name="Execute" command="sudo /sbin/halt" /> <action name="Execute" command="sudo /sbin/reboot" />
</item> </item>
<item label="Power off">
<action name="Execute" command="sudo /sbin/halt" />
</item>
</menu> </menu>
<menu id="some-custom-menu"> <menu id="some-custom-menu">
<item label="Reconfigure"> <item label="Reconfigure">
<action name="Reconfigure" /> <action name="Reconfigure" />
</item> </item>
<item label="Exit"> <item label="Exit">
<action name="Exit" /> <action name="Exit" />
</item> </item>
</menu> </menu>
</openbox_menu> </openbox_menu>

View File

@ -19,6 +19,14 @@
<keyboard> <keyboard>
<default /> <default />
<keybind key="A-Tab">
<action name="NextWindow" />
</keybind>
<keybind key="A-Space">
<action name="ShowMenu">
<menu>root-menu</menu>
</action>
</keybind>
<!-- Use a different terminal emulator --> <!-- Use a different terminal emulator -->
<keybind key="W-Return"> <keybind key="W-Return">
<action name="Execute" command="foot" /> <action name="Execute" command="foot" />
@ -42,4 +50,9 @@
</context> </context>
</mouse> </mouse>
<windowRules>
<windowRule identifier="*">
<action name="Maximize"/>
</windowRule>
</windowRules>
</labwc_config> </labwc_config>