Vendor things
This commit is contained in:
parent
5deceec006
commit
977e3c17e5
19434 changed files with 10682014 additions and 0 deletions
24
third-party/vendor/smithay-client-toolkit/update_keysyms.sh
vendored
Executable file
24
third-party/vendor/smithay-client-toolkit/update_keysyms.sh
vendored
Executable file
|
|
@ -0,0 +1,24 @@
|
|||
#!/bin/bash
|
||||
|
||||
X11_INCLUDEDIR="/usr/include/X11"
|
||||
KEYSYMDEFS="${X11_INCLUDEDIR}/keysymdef.h
|
||||
${X11_INCLUDEDIR}/XF86keysym.h
|
||||
${X11_INCLUDEDIR}/Sunkeysym.h
|
||||
${X11_INCLUDEDIR}/DECkeysym.h
|
||||
${X11_INCLUDEDIR}/HPkeysym.h"
|
||||
TARGET_FILE=src/seat/keyboard/keysyms.rs
|
||||
|
||||
echo "//" > $TARGET_FILE
|
||||
echo "// This file was auto-generated using the update-keysyms.sh script." >> $TARGET_FILE
|
||||
echo "//" >> $TARGET_FILE
|
||||
echo "" >> $TARGET_FILE
|
||||
echo "#![allow(missing_docs, non_upper_case_globals, unused_parens, clippy::all)]" >> $TARGET_FILE
|
||||
echo "#![cfg_attr(rustfmt, rustfmt_skip)]" >> $TARGET_FILE
|
||||
echo "" >> $TARGET_FILE
|
||||
|
||||
cat $KEYSYMDEFS | sed -e '/XK_Ydiaeresis\s*0x100000ee/d' \
|
||||
-e '/#define _/d' \
|
||||
-e 's/#define\s*\(\w*\)XK_/#define XKB_KEY_\1/' \
|
||||
-e '/\(#ifdef\|#ifndef\|#endif\)/d' \
|
||||
-e 's/#define/pub const/g' \
|
||||
-e 's/0x\([0-9a-fA-F]*\)/:u32 = 0x\1;/g' >> $TARGET_FILE
|
||||
Loading…
Add table
Add a link
Reference in a new issue