Added Chinese input

This commit is contained in:
agryphus 2023-10-16 16:25:52 -04:00
parent 97536e9679
commit 6e3378ccc3
4 changed files with 375 additions and 16 deletions

View file

@ -32,15 +32,29 @@ if [ -d /etc/X11/xinit/xinitrc.d ] ; then
unset f
fi
#NixOS does not setup the user's D-Bus Daemon, so doing it explicitly here
if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
eval $(dbus-launch --exit-with-session --sh-syntax)
fi
syustemctl --user import-environment DISPLAY XAUTHORITY
if command -v dbus-update-activation-environment >/dev/null 2>&1; then
dbus-update-activation-environment DISPLAY XAUTHORITY
fi
# Some x stuff
xrandr --setprovideroutputsource modesetting NVIDIA-0
# xrandr --setprovideroutputsource modesetting NVIDIA-0
xrandr --auto
xset r rate 300 50
feh --bg-scale --no-fehbg ~/.config/wallpaper
picom -b
fcitx -d &
sxhkd &
exec dwm
dwmblocks
# Need to source environment before starting fcitx5 so that it can
# read the *_IM_MODULE and XMODIFIER variables.
source ~/.config/zsh/.zshenv
kill $(pidof fcitx5) 2>/dev/null
fcitx5 -d
feh --bg-fill --no-fehbg ~/.config/wallpaper
picom -b
sxhkd &
dwmblocks &
exec dwm

View file

@ -0,0 +1,27 @@
# Vertical Candidate List
Vertical Candidate List=False
# Use Per Screen DPI
PerScreenDPI=True
# Use mouse wheel to go to prev or next page
WheelForPaging=True
# Font
Font="Sans 15"
# Menu Font
MenuFont="Sans 15"
# Tray Font
TrayFont="Sans Bold 15"
# Tray Label Outline Color
TrayOutlineColor=#000000
# Tray Label Text Color
TrayTextColor=#ffffff
# Prefer Text Icon
PreferTextIcon=False
# Show Layout Name In Icon
ShowLayoutNameInIcon=True
# Use input method language to display text
UseInputMethodLangaugeToDisplayText=True
# Theme
Theme=vince
# Force font DPI on Wayland
ForceWaylandDPI=0

View file

@ -50,7 +50,16 @@
i18n = {
defaultLocale = "en_US.UTF-8";
inputMethod.enabled = "fcitx5";
inputMethod = {
# Have to install fcitx5 through here so that the binary is patched to be able to see the addons.
# If also installed through system packages, the binary without addonds will take precedence.
enabled = "fcitx5";
fcitx5.addons = with pkgs; [
fcitx5-configtool
fcitx5-rime
fcitx5-chinese-addons
];
};
};
# console = {
# font = "Lat2-Terminus16";
@ -86,12 +95,25 @@
hardware.pulseaudio.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.vince = {
isNormalUser = true;
extraGroups = [ "wheel" ];
packages = with pkgs; [
];
shell = pkgs.zsh;
users = {
mutableUsers = true;
users = {
vince = {
isNormalUser = true;
extraGroups = [ "wheel" ];
packages = with pkgs; [
];
shell = pkgs.zsh;
# Set so when mutableUsers is set to "false", the user still has a way to login.
password = "";
};
root = {
# Disables root login, since nothing can hash to "!". Requires setting mutableUsers to "false",
# rebuilding, and then setting mutableUsers back to "true".
hashedPassword = "!";
};
};
};
# List packages installed in system profile. To search, run:
@ -101,8 +123,6 @@
bat # Fancy `cat` which I use for lf
devour # Opens new program on top of terminal
dunst # Notification daemon
fcitx5-configtool # GUI config tool for fcitx5
fcitx5 # Foreign keyboard switcher
feh # Image viewer I use for background setting
git # Imagine not having this
htop # Process monitor
@ -119,7 +139,9 @@
rofi-pass # Rofi frontend for password store
sxhkd # Hotkey daemon
syncthing # Syncing files between machines
texlive.combined.scheme-full # LaTeX to create documents
tmux # Terminal multiplexor
typst # Cool, minimal LaTeX alternative
ueberzugpp # Terminal image overlayer
zathura # Pdf editor
zsh # Shell
@ -173,6 +195,8 @@
];
fonts.fonts = with pkgs; [
source-han-sans
source-han-serif
(nerdfonts.override { fonts = [ "FiraCode" ]; })
];