Skip to content

Commit

Permalink
v19: Change UI;Add Help page.
Browse files Browse the repository at this point in the history
Signed-off-by: Hollow Man <[email protected]>
  • Loading branch information
HollowMan6 committed Apr 23, 2021
1 parent f6c5f21 commit dc1f119
Show file tree
Hide file tree
Showing 12 changed files with 404 additions and 42 deletions.
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# by tuberry and based on dashtodock's makefile
# by hollowman and tuberry, based on dashtodock's makefile
# to increase version number automatically when manually installing

EXTNUM = 4112
Expand Down Expand Up @@ -35,6 +35,7 @@ endif
LANGUAGE = $(shell echo $(LANG) | sed -e 's/\..*//')
MSGPOT = locale/$(NAME).pot
MSGDIR = locale/$(LANGUAGE)/LC_MESSAGES
INSTDIR = usr/share/gnome-shell/extensions
MSGSRC = $(MSGDIR)/$(NAME).po
MSGAIM = $(MSGDIR)/$(NAME).mo

Expand All @@ -43,9 +44,15 @@ all: _build
clean:
-rm -fR _build
-rm -fR *.zip
-rm -fR *.deb
-rm -fR *.rpm
-rm -fR *.pkg.tar.zst
-rm -fR *.tar.gz
-rm -fR pkg src
-rm -fR $(SCMCPL)
-rm -fR $(MSGPOS:.po=.mo)
-rm -fR $(MSGPOS:.po=.po~)
-rm -fR deb/usr

$(SCMCPL): $(SCMXML)
glib-compile-schemas ./$(UUID)/schemas/
Expand Down
16 changes: 7 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

(English version is down below)

### 注意:如果后期无重大 BUG 的话,v17 将是支持 GNOME 3.38 的最后一个版本
### 注意:如果后期无重大 BUG 的话,v19 将是支持 GNOME 3.38 的最后一个版本

在 GNOME Shell 中更改 IBus 的候选框方向、字体、输入法默认语言,主题、背景图片跟随 GNOME 夜灯模式自动切换。

Expand All @@ -38,8 +38,6 @@ cd Customize-IBus && make install

## 功能

![image](img/preference.png)

## 使用用户主题来更改 IBus 皮肤的实现

该功能已经被拆分,生成 IBus 皮肤样式表功能迁移到了[IBus-Theme](https://github.com/HollowMan6/IBus-Theme)
Expand All @@ -59,7 +57,7 @@ IBus Tweaker 中提供的主题已经被我制作成为 IBus 主题样式表合
### _提示:_

1. 推荐使用 X11。如果你在 Wayland 中更改 IBus 主题,你的当前所有工作都将会丢失,因为 Wayland 下只支持通过重新登陆来重启 GNOME-shell。
2. 在 Fedora 33 和 Ubuntu 20.04, GNOME-shell 3.38 中(v3,v5,v9,v11,v14,v15,v17)通过了测试。
2. 在 Fedora 33 和 Ubuntu 20.04, GNOME-shell 3.38 中(v3,v5,v9,v11,v14,v15,v17,v19)通过了测试。
3. 对于那些不使用 GNOME 而是使用如 KDE,XFCE 等桌面环境的用户,更改 IBus GTK 主题也请使用我的另外一个项目[IBus-Theme](https://github.com/HollowMan6/IBus-Theme)

## 更改 IBus 背景图片的实现
Expand Down Expand Up @@ -93,6 +91,7 @@ background-size: cover;
- [x] V15: 修改主题加载逻辑,免去每次更换主题都要重启 GNOME-Shell。
- [x] V17: 增加浅色和深色背景与主题,跟随 GNOME 夜灯模式自动切换。
- [x] V17: 重构代码。
- [x] V19: 更改 UI;增加帮助页面。

## 致谢

Expand All @@ -104,7 +103,7 @@ _该项目是谷歌编程之夏 (GSoC) 2021 于[OpenSUSE](https://github.com/ope

# Customize IBus

### Note: If no severe bug was found later, v15 will be the last version that support GNOME 3.38.
### Note: If no severe bug was found later, v19 will be the last version that support GNOME 3.38.

Customize IBus for orientation, font, ascii mode auto-switch; theme and background picture follow GNOME Night Light Mode.

Expand All @@ -123,8 +122,6 @@ cd Customize-IBus && make install

## Features

![image](img/preference-en.png)

## Realization of Customizing IBus with User Theme

This function has been separated, generating IBus theme stylesheet has been moved to [IBus-Theme](https://github.com/HollowMan6/IBus-Theme).
Expand All @@ -144,7 +141,7 @@ Themes in IBus Tweaker have been converted by me as IBus theme stylesheets colle
### _NOTE:_

1. Recommend to use X11. If you change IME theme under Wayland, all your current work may be lost (Since Wayland only support relogin to restart the GNOME-shell).
2. Tested on Fedora 33 and Ubuntu 20.04, GNOME-shell 3.38(v3, v5, v9, v11, v14, v15, v17).
2. Tested on Fedora 33 and Ubuntu 20.04, GNOME-shell 3.38(v3, v5, v9, v11, v14, v15, v17, v19).
3. For users who don't use GNOME but other desktop environments like KDE, XFCE, etc., please also use another project of mine [IBus-Theme](https://github.com/HollowMan6/IBus-Theme) to use a different GTK theme for IBus.

## Realization of Modifying IBus Background Picture
Expand All @@ -165,7 +162,7 @@ When light background and dark background are turned on at the same time, the ex

When only one of the light background and dark background is turned on, the extension will always use the background that is turned on.

**Note:** If your IBus style sheet has changed after application, please close and reopen the corresponding `custom IME background` to make it effective.
**Note:** Please make sure your background picture can always be visited. If your pictures are stored in the removable device and the system doesn't mount it by default, please close and reopen the corresponding `Use custom background` to make it effective after manually mounting.

## To-do

Expand All @@ -178,6 +175,7 @@ When only one of the light background and dark background is turned on, the exte
- [x] V15: Modify theme load logic so that now we don't need to reload GNOME-Shell to change IBus themes.
- [x] V17: Add theme and background picture follow GNOME Night Light Mode.
- [x] V17: Refactor code.
- [x] V19: Change UI;Add Help page.

## Acknowledgements

Expand Down
2 changes: 2 additions & 0 deletions [email protected]/fields.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
// vim:fdm=syntax
// by:hollowman6@github tuberry@github

"use strict";

var Fields = {
ASCIIMODE: "ascii-mode",
CUSTOMFONT: "custom-font",
Expand Down
90 changes: 83 additions & 7 deletions [email protected]/locale/customize-ibus.pot
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: Customize Ibus 17\n"
"Project-Id-Version: Customize Ibus 19\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-04-21 11:51+0800\n"
"POT-Creation-Date: 2021-04-23 13:15+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"

#: extension.js:310
Expand Down Expand Up @@ -98,14 +98,90 @@ msgstr ""
msgid "Select an IBus Stylesheet"
msgstr ""

#: prefs.js:141
#: prefs.js:138
msgid "Basic"
msgstr ""

#: prefs.js:149
#: prefs.js:146 prefs.js:459
msgid "Theme"
msgstr ""

#: prefs.js:153 prefs.js:507
msgid "Background"
msgstr ""

#: prefs.js:153
msgid "Theme"
#: prefs.js:370
msgid "Help"
msgstr ""

#: prefs.js:387
msgid "unknown (self-build ?)"
msgstr ""

#: prefs.js:394
msgid "Customize IBus"
msgstr ""

#: prefs.js:402
msgid "Version: "
msgstr ""

#: prefs.js:414
msgid ""
"Customize IBus for orientation, font, ascii mode auto-switch; theme and "
"background picture follow GNOME Night Light Mode."
msgstr ""

#: prefs.js:426
msgid ""
"<span size=\"small\">Copyright © 2021 <a href=\"https://github.com/"
"HollowMan6\">Hollow Man</a> &lt;[email protected]&gt;</span>"
msgstr ""

#: prefs.js:438
msgid ""
"<span size=\"small\">Source Code: <a href=\"https://github.com/HollowMan6/"
"Customize-IBus\">https://github.com/HollowMan6/Customize-IBus</a></span>"
msgstr ""

#: prefs.js:450
msgid ""
"<span size=\"small\"><a href=\"https://www.gnu.org/licenses/gpl\">GNU "
"General Public License, version 3 or later</a></span>"
msgstr ""

#: prefs.js:470
msgid ""
"Support importing stylesheet generated by <a href=\"https://github.com/"
"HollowMan6/IBus-Theme\">IBus Theme Tool</a> or provided by <a href=\"https://"
"github.com/HollowMan6/IBus-Theme-Hub\">IBus Theme Hub</a>."
msgstr ""

#: prefs.js:483
msgid ""
"When light theme and dark theme are turned on at the same time, the IBus "
"theme will automatically follow GNOME Night Light mode, use light theme when "
"off, and use dark theme when on. When only one of the light theme and dark "
"theme is turned on, the IBus theme will always use the theme that is turned "
"on."
msgstr ""

#: prefs.js:496
msgid ""
"<span size=\"small\"><b>Note:</b> If your IBus stylesheet has changed after "
"application, please close and reopen the corresponding <b>custom IME theme</"
"b> to make it effective.</span>"
msgstr ""

#: prefs.js:518
msgid "Same changing logic as Theme"
msgstr ""

#: prefs.js:530
msgid ""
"<span size=\"small\"><b>Note:</b> Please make sure your background picture "
"can always be visited. If your pictures are stored in the removable device "
"and the system doesn't mount it by default, please close and reopen the "
"corresponding <b>Use custom background</b> to make it effective after "
"manually mounting.</span>"
msgstr ""
107 changes: 101 additions & 6 deletions [email protected]/locale/zh_CN/LC_MESSAGES/customize-ibus.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: customize-ibus 1\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-04-21 11:50+0800\n"
"POT-Creation-Date: 2021-04-23 13:13+0800\n"
"PO-Revision-Date: 2021-03-27 16:22+0800\n"
"Last-Translator: Hollow Man <[email protected]>\n"
"Language-Team: Chinese (simplified) <[email protected]>\n"
Expand Down Expand Up @@ -98,14 +98,109 @@ msgstr "(无)"
msgid "Select an IBus Stylesheet"
msgstr "选择一个IBus风格样式表"

#: prefs.js:141
#: prefs.js:138
msgid "Basic"
msgstr "基本"

#: prefs.js:149
#: prefs.js:146 prefs.js:459
msgid "Theme"
msgstr "主题"

#: prefs.js:153 prefs.js:507
msgid "Background"
msgstr "背景"

#: prefs.js:153
msgid "Theme"
msgstr "主题"
#: prefs.js:370
msgid "Help"
msgstr "帮助"

#: prefs.js:387
msgid "unknown (self-build ?)"
msgstr "未知(自编译?)"

#: prefs.js:394
msgid "Customize IBus"
msgstr "自定义 IBus"

#: prefs.js:402
msgid "Version: "
msgstr "版本:"

#: prefs.js:414
msgid ""
"Customize IBus for orientation, font, ascii mode auto-switch; theme and "
"background picture follow GNOME Night Light Mode."
msgstr ""
"在 GNOME Shell 中更改 IBus 的候选框方向、字体、输入法默认语言,主题、背景图片"
"跟随 GNOME 夜灯模式自动切换。"

#: prefs.js:426
msgid ""
"<span size=\"small\">Copyright © 2021 <a href=\"https://github.com/"
"HollowMan6\">Hollow Man</a> &lt;[email protected]&gt;</span>"
msgstr ""
"<span size=\"small\">版权所有 © 2021 <a href=\"https://github.com/"
"HollowMan6\">Hollow Man</a> &lt;[email protected]&gt;</span>"

#: prefs.js:438
msgid ""
"<span size=\"small\">Source Code: <a href=\"https://github.com/HollowMan6/"
"Customize-IBus\">https://github.com/HollowMan6/Customize-IBus</a></span>"
msgstr ""
"<span size=\"small\">源代码:<a href=\"https://github.com/HollowMan6/"
"Customize-IBus\">https://github.com/HollowMan6/Customize-IBus</a></span>"

#: prefs.js:450
msgid ""
"<span size=\"small\"><a href=\"https://www.gnu.org/licenses/gpl\">GNU "
"General Public License, version 3 or later</a></span>"
msgstr ""
"<span size=\"small\"><a href=\"https://www.gnu.org/licenses/gpl\">GNU 通用公"
"共许可证,版本 3 或者更新</a></span>"

#: prefs.js:470
msgid ""
"Support importing stylesheet generated by <a href=\"https://github.com/"
"HollowMan6/IBus-Theme\">IBus Theme Tool</a> or provided by <a href=\"https://"
"github.com/HollowMan6/IBus-Theme-Hub\">IBus Theme Hub</a>."
msgstr ""
"支持导入由 <a href=\"https://github.com/HollowMan6/IBus-Theme\">IBus 主题工具"
"</a> 生成的或者由 <a href=\"https://github.com/HollowMan6/IBus-Theme-Hub"
"\">IBus 主题集合</a> 提供的样式表。"

#: prefs.js:483
msgid ""
"When light theme and dark theme are turned on at the same time, the IBus "
"theme will automatically follow GNOME Night Light mode, use light theme when "
"off, and use dark theme when on. When only one of the light theme and dark "
"theme is turned on, the IBus theme will always use the theme that is turned "
"on."
msgstr ""
"当浅色主题和深色主题同时开启时,IBus 主题将会自动跟随 GNOME 夜灯模式,关闭时"
"使用浅色主题,开启时使用深色主题。当浅色主题和深色主题只有一个被开启时,扩展"
"将会始终使用那个开启的主题。"

#: prefs.js:496
msgid ""
"<span size=\"small\"><b>Note:</b> If your IBus stylesheet has changed after "
"application, please close and reopen the corresponding <b>custom IME theme</"
"b> to make it effective.</span>"
msgstr ""
"<span size=\"small\"><b>注:</b> 如你的 IBus 样式表在应用后作出了更改,请关闭"
"并重新开启对应 <b>自定义主题</b>来使其生效。</span>"

#: prefs.js:518
msgid "Same changing logic as Theme"
msgstr "和 主题 同样的变化逻辑"

#: prefs.js:530
msgid ""
"<span size=\"small\"><b>Note:</b> Please make sure your background picture "
"can always be visited. If your pictures are stored in the removable device "
"and the system doesn't mount it by default, please close and reopen the "
"corresponding <b>Use custom background</b> to make it effective after "
"manually mounting.</span>"
msgstr ""
"<span size=\"small\"><b>注:</b> 请确保背景图片始终可以访问,如你的图片存放在"
"可移动设备,系统默认不挂载,每次手动挂载后请关闭并重新开启对应 <b>自定义背景"
"</b> 来使其生效。</span>"
2 changes: 1 addition & 1 deletion [email protected]/metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@
"original-authors": ["[email protected]"],
"uuid": "[email protected]",
"extension-id": "customize-ibus",
"version": 17
"version": 19
}
Loading

0 comments on commit dc1f119

Please sign in to comment.