diff options
author | Ismaël Bouya <ismael.bouya@fretlink.com> | 2018-11-21 21:28:09 +0100 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@fretlink.com> | 2018-11-21 21:28:09 +0100 |
commit | c32343b4e0a4066527d60ec4e51eefb6cd4eab67 (patch) | |
tree | 6579f2549791bb3331b23cf9522935a7821d6602 | |
parent | ba49638af92aaa5349c5476db8136caec4b0166d (diff) | |
download | Ansible-c32343b4e0a4066527d60ec4e51eefb6cd4eab67.tar.gz Ansible-c32343b4e0a4066527d60ec4e51eefb6cd4eab67.tar.zst Ansible-c32343b4e0a4066527d60ec4e51eefb6cd4eab67.zip |
Add fcitx configuration
12 files changed, 344 insertions, 0 deletions
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-autoeng.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-autoeng.config new file mode 100644 index 0000000..7dfc7f4 --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-autoeng.config | |||
@@ -0,0 +1,21 @@ | |||
1 | [Auto English] | ||
2 | # Choose key modifier | ||
3 | # Available Value: | ||
4 | # None | ||
5 | # Alt | ||
6 | # Ctrl | ||
7 | # Shift | ||
8 | #ChooseModifier=Alt | ||
9 | # Do not show spell hint | ||
10 | # Available Value: | ||
11 | # True False | ||
12 | #DisableSpell=False | ||
13 | # Maximum hint length | ||
14 | #MaximumHintLength=2 | ||
15 | # Maximum words number kept in preedit | ||
16 | #MaximumKeep=3 | ||
17 | # Add Extra space when selecting a candidate word | ||
18 | # Available Value: | ||
19 | # True False | ||
20 | #SelectAddSpace=True | ||
21 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-classic-ui.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-classic-ui.config new file mode 100644 index 0000000..0ac6805 --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-classic-ui.config | |||
@@ -0,0 +1,31 @@ | |||
1 | [ClassicUI] | ||
2 | # Status Panel Position X | ||
3 | #MainWindowOffsetX=500 | ||
4 | # Status Panel Position Y | ||
5 | #MainWindowOffsetY=40 | ||
6 | # Font Size | ||
7 | #FontSize=0 | ||
8 | # Font | ||
9 | #Font=Sans | ||
10 | # Menu Font | ||
11 | #MenuFont=Sans | ||
12 | # Font Locale to display | ||
13 | #FontLocale=zh_CN.UTF-8 | ||
14 | # Use System Tray Icon | ||
15 | # Available Value: | ||
16 | # True False | ||
17 | #UseTray=True | ||
18 | # Status Panel Hide Mode | ||
19 | # Available Value: | ||
20 | # Show | ||
21 | # Auto | ||
22 | # Hide when tray icon is available | ||
23 | # Hide | ||
24 | #MainWindowHideMode=Hide when tray icon is available | ||
25 | # Vertical Candidate Word List | ||
26 | # Available Value: | ||
27 | # True False | ||
28 | VerticalList=True | ||
29 | # Skin Name | ||
30 | #SkinType=default | ||
31 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-keyboard.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-keyboard.config new file mode 100644 index 0000000..f4c53fb --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-keyboard.config | |||
@@ -0,0 +1,25 @@ | |||
1 | [Keyboard] | ||
2 | # Commit with extra space when choose candidate word | ||
3 | # Available Value: | ||
4 | # True False | ||
5 | #CommitWithExtraSpace=False | ||
6 | # Choose key modifier | ||
7 | # Available Value: | ||
8 | # None | ||
9 | # Alt | ||
10 | # Ctrl | ||
11 | # Shift | ||
12 | #ChooseModifier=Alt | ||
13 | # Toggle the word hint | ||
14 | #HotkeyToggleWordHint=CTRL_ALT_H | ||
15 | # Minimum length to trigger word hint | ||
16 | #MinimumHintLength=1 | ||
17 | # Maximum length of spell hint list | ||
18 | #MaximumHintLength=5 | ||
19 | # Use enter to commit the existing string | ||
20 | # Available Value: | ||
21 | # True False | ||
22 | #UseEnterToCommit=False | ||
23 | # Add current input buffer to user dictionary | ||
24 | #HotkeyAddToUserDict=CTRL_ALT_N | ||
25 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-m17n.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-m17n.config new file mode 100644 index 0000000..e0a9fc9 --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-m17n.config | |||
@@ -0,0 +1,10 @@ | |||
1 | [M17N] | ||
2 | # Prev Page | ||
3 | #PrevPage=UP CTRL_P | ||
4 | # Next Page | ||
5 | #NextPage=DOWN CTRL_N | ||
6 | # Enable deprecated Input method | ||
7 | # Available Value: | ||
8 | # True False | ||
9 | #EnableDeprecated=False | ||
10 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-notify.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-notify.config new file mode 100644 index 0000000..67bbb8b --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-notify.config | |||
@@ -0,0 +1,2 @@ | |||
1 | [Notify/Notify] | ||
2 | HiddenNotify= | ||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-spell.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-spell.config new file mode 100644 index 0000000..4b4c989 --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-spell.config | |||
@@ -0,0 +1,10 @@ | |||
1 | [Spell Hint] | ||
2 | # Preferred Enchant provider | ||
3 | # Available Value: | ||
4 | # Default | ||
5 | # Aspell | ||
6 | # Myspell | ||
7 | #PreferredEnchantProvider=Myspell | ||
8 | # Default Spell Hint Backends Order | ||
9 | #HintProvidersOrder=presage,custom,enchant | ||
10 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-table.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-table.config new file mode 100644 index 0000000..ac1b6a0 --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-table.config | |||
@@ -0,0 +1,12 @@ | |||
1 | [Key] | ||
2 | # Add Phrase | ||
3 | AddPhrase= | ||
4 | # Delete Phrase | ||
5 | DeletePhrase= | ||
6 | # Adjust Order | ||
7 | AdjustOrder= | ||
8 | # Clear Frequency | ||
9 | #ClearFreq= | ||
10 | # Lookup Pinyin | ||
11 | LookupPinyin= | ||
12 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-unicode.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-unicode.config new file mode 100644 index 0000000..f2a0dbc --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-unicode.config | |||
@@ -0,0 +1,4 @@ | |||
1 | [Unicode] | ||
2 | # Key | ||
3 | #Key=CTRL_ALT_SHIFT_U | ||
4 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-xim.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-xim.config new file mode 100644 index 0000000..40021fb --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-xim.config | |||
@@ -0,0 +1,6 @@ | |||
1 | [Xim] | ||
2 | # Use On The Spot Style for XIM (Cannot change during running) | ||
3 | # Available Value: | ||
4 | # True False | ||
5 | #UseOnTheSpotStyle=False | ||
6 | |||
diff --git a/roles/graphical/files/config_files/fcitx/conf/fcitx-xkb.config b/roles/graphical/files/config_files/fcitx/conf/fcitx-xkb.config new file mode 100644 index 0000000..4ae4a5f --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/conf/fcitx-xkb.config | |||
@@ -0,0 +1,14 @@ | |||
1 | [X Keyboard] | ||
2 | # Allow to Override System XKB Settings | ||
3 | # Available Value: | ||
4 | # True False | ||
5 | #OverrideSystemXKBSettings=True | ||
6 | # Use the layout of first keyboard input method in list as default layout | ||
7 | # Available Value: | ||
8 | # True False | ||
9 | #UseFirstKeyboardIMAsDefaultLayout=True | ||
10 | # xmodmap command | ||
11 | #XModmapCommand=xmodmap | ||
12 | # Apply this custom xmodmap script after layout change | ||
13 | #CustomXModmapScript= | ||
14 | |||
diff --git a/roles/graphical/files/config_files/fcitx/config b/roles/graphical/files/config_files/fcitx/config new file mode 100644 index 0000000..468578b --- /dev/null +++ b/roles/graphical/files/config_files/fcitx/config | |||
@@ -0,0 +1,147 @@ | |||
1 | [Hotkey] | ||
2 | # Trigger Input Method | ||
3 | TriggerKey= | ||
4 | # Use extra trigger key only after using it to inactivate | ||
5 | # Available Value: | ||
6 | # True False | ||
7 | #UseExtraTriggerKeyOnlyWhenUseItToInactivate=True | ||
8 | # Extra key for trigger input method | ||
9 | # Available Value: | ||
10 | # R_CTRL | ||
11 | # R_SHIFT | ||
12 | # L_SHIFT | ||
13 | # L_CTRL | ||
14 | # ALT_L_SHIFT | ||
15 | # ALT_R_SHIFT | ||
16 | # CTRL Both | ||
17 | # SHIFT Both | ||
18 | # L_ALT | ||
19 | # R_ALT | ||
20 | # ALT Both | ||
21 | # Left Super | ||
22 | # Right Super | ||
23 | # Super Both | ||
24 | # Ctrl+Left Super | ||
25 | # Ctrl+Right Super | ||
26 | # Super+Left Ctrl | ||
27 | # Super+Right Ctrl | ||
28 | # Disabled | ||
29 | # Custom | ||
30 | SwitchKey=Disabled | ||
31 | # Custom switch key | ||
32 | #CustomSwitchKey= | ||
33 | # Activate input method | ||
34 | #ActivateKey= | ||
35 | # Inactivate Input Method | ||
36 | #InactivateKey= | ||
37 | # Enable Hotkey to scroll Between Input Method | ||
38 | # Available Value: | ||
39 | # True False | ||
40 | IMSwitchKey=False | ||
41 | # Include Inactivate when scrolling between Input Method | ||
42 | # Available Value: | ||
43 | # True False | ||
44 | #IMSwitchIncludeInactive=False | ||
45 | # Scroll between Input Method | ||
46 | # Available Value: | ||
47 | # CTRL_SHIFT | ||
48 | # ALT_SHIFT | ||
49 | # CTRL_SUPER | ||
50 | # ALT_SUPER | ||
51 | #IMSwitchHotkey=CTRL_SHIFT | ||
52 | # Reload configuration | ||
53 | #ReloadConfig=CTRL_5 | ||
54 | # Interval of Two Key Input | ||
55 | #TimeInterval=250 | ||
56 | # Switching Virtual Keyboard | ||
57 | #VKSwitchKey=CTRL_ALT_B | ||
58 | # Switching Remind Mode | ||
59 | #RemindSwitchKey= | ||
60 | # Switching Full Width Character Mode | ||
61 | #FullWidthSwitchKey= | ||
62 | # Switch Full Width Punc Mode | ||
63 | #PuncSwitchKey=CTRL_. | ||
64 | # Prev Page | ||
65 | #PrevPageKey=- UP | ||
66 | # Next Page | ||
67 | #NextPageKey== DOWN | ||
68 | # Choose Second and Third Candidate Word | ||
69 | #SecondThirdCandWordKey= | ||
70 | # Saving All Config and Input History | ||
71 | #SaveAllKey=CTRL_ALT_S | ||
72 | # Switch Embedded Preedit | ||
73 | #SwitchPreedit=CTRL_ALT_P | ||
74 | # Previous Candidate Word | ||
75 | #PrevWord=SHIFT_TAB | ||
76 | # Next Candidate Word | ||
77 | #NextWord=TAB | ||
78 | |||
79 | [Program] | ||
80 | # Seconds sleep before fcitx really start | ||
81 | #DelayStart=0 | ||
82 | # Share State Among Window | ||
83 | # Available Value: | ||
84 | # No | ||
85 | # All | ||
86 | # PerProgram | ||
87 | #ShareStateAmongWindow=No | ||
88 | # Default Input Method State | ||
89 | # Available Value: | ||
90 | # Inactive | ||
91 | # Active | ||
92 | #DefaultInputMethodState=Inactive | ||
93 | |||
94 | [Output] | ||
95 | # Type half width Punc After a Number | ||
96 | # Available Value: | ||
97 | # True False | ||
98 | #HalfPuncAfterNumber=True | ||
99 | # Disable Paging in Remind Mode | ||
100 | # Available Value: | ||
101 | # True False | ||
102 | #RemindModeDisablePaging=True | ||
103 | # Commit when toggle state | ||
104 | # Available Value: | ||
105 | # True False | ||
106 | #SendTextWhenSwitchEng=True | ||
107 | # Candidate Word Number | ||
108 | CandidateWordNumber=10 | ||
109 | # Give the tips of Phrase | ||
110 | # Available Value: | ||
111 | # True False | ||
112 | #PhraseTips=True | ||
113 | # Do not commit preedit text when unfocus a window | ||
114 | # Available Value: | ||
115 | # True False | ||
116 | #DontCommitPreeditWhenUnfocus=False | ||
117 | |||
118 | [Appearance] | ||
119 | # Show Input Method Hint After Input method changed | ||
120 | # Available Value: | ||
121 | # True False | ||
122 | ShowInputWindowAfterTriggering=False | ||
123 | # Show Input Method Hint After Input method changed and Focus in | ||
124 | # Available Value: | ||
125 | # True False | ||
126 | #ShowInputWindowWhenFocusIn=False | ||
127 | # Input Method Hint will be only shown when state is active | ||
128 | # Available Value: | ||
129 | # True False | ||
130 | #ShowInputWindowOnlyWhenActive=True | ||
131 | # Show Input Speed | ||
132 | # Available Value: | ||
133 | # True False | ||
134 | #ShowInputSpeed=False | ||
135 | # Show Version | ||
136 | # Available Value: | ||
137 | # True False | ||
138 | #ShowVersion=False | ||
139 | # Do not show input window if there is only preedit string | ||
140 | # Available Value: | ||
141 | # True False | ||
142 | #HideInputWindowWhenOnlyPreeditString=False | ||
143 | # Do not show input window if there is only one candidate and preedit | ||
144 | # Available Value: | ||
145 | # True False | ||
146 | #HideInputWindowWhenOnlyOneCandidate=False | ||
147 | |||
diff --git a/roles/graphical/tasks/main.yml b/roles/graphical/tasks/main.yml index f73623e..f79f1c4 100644 --- a/roles/graphical/tasks/main.yml +++ b/roles/graphical/tasks/main.yml | |||
@@ -27,3 +27,65 @@ | |||
27 | path: "$XDG_DATA_HOME/xorg" | 27 | path: "$XDG_DATA_HOME/xorg" |
28 | src: "$XDG_STATE_HOME/xorg" | 28 | src: "$XDG_STATE_HOME/xorg" |
29 | state: link | 29 | state: link |
30 | - name: fcitx configuration dir | ||
31 | file: | ||
32 | path: "$XDG_CONFIG_HOME/{{ item }}" | ||
33 | state: directory | ||
34 | loop: | ||
35 | - fcitx | ||
36 | - fcitx/addon | ||
37 | - fcitx/conf | ||
38 | - name: fcitx configuration | ||
39 | copy: | ||
40 | src: "config_files/fcitx/{{ item }}" | ||
41 | dest: "$XDG_CONFIG_HOME/fcitx/{{ item }}" | ||
42 | loop: | ||
43 | - config | ||
44 | - conf/fcitx-autoeng.config | ||
45 | - conf/fcitx-classic-ui.config | ||
46 | - conf/fcitx-keyboard.config | ||
47 | - conf/fcitx-m17n.config | ||
48 | - conf/fcitx-notify.config | ||
49 | - conf/fcitx-spell.config | ||
50 | - conf/fcitx-table.config | ||
51 | - conf/fcitx-unicode.config | ||
52 | - conf/fcitx-xim.config | ||
53 | - conf/fcitx-xkb.config | ||
54 | - name: fcitx disabled addons | ||
55 | ini_file: | ||
56 | path: "$XDG_CONFIG_HOME/fcitx/addon/fcitx-{{ item.0 }}.conf" | ||
57 | no_extra_spaces: true | ||
58 | section: "Addon" | ||
59 | option: "Enabled" | ||
60 | value: "{{ item.1 }}" | ||
61 | # cf /usr/share/fcitx/addon/ | ||
62 | loop: | ||
63 | - [ "chttrans", "False" ] | ||
64 | - [ "clipboard", "False" ] | ||
65 | - [ "imselector", "False" ] | ||
66 | - [ "kimpanel-ui", "False" ] | ||
67 | - [ "pinyin", "False" ] | ||
68 | - [ "pinyin-enhance", "False" ] | ||
69 | - [ "quickphrase", "False" ] | ||
70 | - [ "qw", "False" ] | ||
71 | |||
72 | - [ "autoeng", "True" ] | ||
73 | - [ "classic-ui", "True" ] | ||
74 | - [ "dbus", "True" ] | ||
75 | - [ "freedesktop-notify", "True" ] | ||
76 | - [ "fullwidth-char", "True" ] | ||
77 | - [ "ipc", "True" ] | ||
78 | - [ "ipcportal", "True" ] | ||
79 | - [ "keyboard", "True" ] | ||
80 | - [ "m17n", "True" ] | ||
81 | - [ "notificationitem", "True" ] | ||
82 | - [ "punc", "True" ] | ||
83 | - [ "remote-module", "True" ] | ||
84 | - [ "spell", "True" ] | ||
85 | - [ "table", "True" ] | ||
86 | - [ "unicode", "True" ] | ||
87 | - [ "vk", "True" ] | ||
88 | - [ "x11", "True" ] | ||
89 | - [ "xim", "True" ] | ||
90 | - [ "xkb", "True" ] | ||
91 | - [ "xkbdbus", "True" ] | ||