最近几天Deepin团队的动作不小,出了deepinscreenshot3.0,我看介绍里面画面细腻了很多,功能也多了许多,2.0的时候需要deepinui,依赖太多,一直坚持在deepin-scort1.1的版本,正常使用没问题,不过窗口识别和标注不是很准确方便。
3.0的版本好像不需要那么多的deepin依赖,qt5-multimedia和python-pyqt5,python2-pyqt5,依赖环境装完后用python2运行直接没有以后了,python3提示app_controller导入错误...
而linux版的有道词典也有问题,README.MD中指明了依赖关系,有tesseract tesseract-data-chi_sim tesseract-data-chi_tra tesseract-data-chi_eng,python是3.x的版本,这里提示import dae错误,dae是什么鬼? Deepin app engine.但是src里面有dae的类。。。
=======================================================
现在deepin-screenshot和youdao-dict都已经上架yaourt,也均可正常使用,youdao在xfce下没有托盘图标,屏幕取词正常;deepin-screenshot没有社交分享(很少需要)
有道词典linux版
https://aur.archlinux.org/packages/youdao-dict
深度截图3.0
https://aur.archlinux.org/packages/deepin-screenshot/
这里需要xpybutil包,我对PKGBUILD不熟悉,然后就用了下面的笨方法:
1、安装xpyb
yaourt -S xpyb
2、克隆xpybutil到本地
git clone https://github.com/BurntSushi/xpybutil
3、安装xpybutil
sudo python2 ./setup.py install
(在python中导入模块正常了)
4、去掉deepin-screenshot的PKGBUILD中xpybutil的依赖。
最后感谢Deepin团队和有道词典给我们带来这么好的工具。
最近编辑记录 bubbles (2015-04-27 00:59:11)
离线
linux有道词典还需要aur中的python-xlib 和python-lxml
'python' 'python-pyqt5' 'python-request' 'python-xlib'(aur) 'python-pillow' 'tesseract' 'tesseract-data-chi_sim' 'tesseract-data-chi_tra' 'tesseract-data-chi_eng'
离线
linux有道词典还需要aur中的python-xlib 和python-lxml
'python' 'python-pyqt5' 'python-request' 'python-xlib'(aur) 'python-pillow' 'tesseract' 'tesseract-data-chi_sim' 'tesseract-data-chi_tra' 'tesseract-data-chi_eng'
还需要另外两个依赖,
'qt5-quickcontrols' 'qt5-graphicaleffects'
现在效果还不错,就是屏幕取词有问题,最小化道托盘无法显示 xfce4...
PKGBUILD这个怎么写?没写过。。。希望放到AUR中。
离线
离线
有道词典确实比较好用.
离线
从AUR安装后不能运行
[xx@arch ~]$ youdao-dict
Load "youdao" plugin error: No module named 'requests'
Traceback (most recent call last):
File "/usr/share/youdao-dict/dae/plugins.py", line 81, in load
assets.pluginobjects += self.get_plugin_object(plugin_name)
File "/usr/share/youdao-dict/dae/plugins.py", line 70, in get_plugin_object
plugin = self.load_plugin(plugin_name)
File "/usr/share/youdao-dict/dae/plugins.py", line 53, in load_plugin
plugin = imp.load_source(plugin_name, os.path.join(path, '__init__.py'))
File "/usr/lib/python3.4/imp.py", line 171, in load_source
module = methods.load()
File "<frozen importlib._bootstrap>", line 1220, in load
File "<frozen importlib._bootstrap>", line 1200, in _load_unlocked
File "<frozen importlib._bootstrap>", line 1129, in _exec
File "<frozen importlib._bootstrap>", line 1471, in exec_module
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "/usr/share/youdao-dict/app/plugins/youdao/__init__.py", line 35, in <module>
from window import SplashWindow
File "/usr/share/youdao-dict/app/plugins/youdao/window.py", line 29, in <module>
from models import suggestModel, historyModel
File "/usr/share/youdao-dict/app/plugins/youdao/models.py", line 31, in <module>
import requests
ImportError: No module named 'requests'
ATTENTION: default value of option bo_reuse overridden by environment.
[img]http://i.wotula.com/wp.png[/img]
离线
从AUR安装后不能运行
[xx@arch ~]$ youdao-dict Load "youdao" plugin error: No module named 'requests' Traceback (most recent call last): File "/usr/share/youdao-dict/dae/plugins.py", line 81, in load assets.pluginobjects += self.get_plugin_object(plugin_name) File "/usr/share/youdao-dict/dae/plugins.py", line 70, in get_plugin_object plugin = self.load_plugin(plugin_name) File "/usr/share/youdao-dict/dae/plugins.py", line 53, in load_plugin plugin = imp.load_source(plugin_name, os.path.join(path, '__init__.py')) File "/usr/lib/python3.4/imp.py", line 171, in load_source module = methods.load() File "<frozen importlib._bootstrap>", line 1220, in load File "<frozen importlib._bootstrap>", line 1200, in _load_unlocked File "<frozen importlib._bootstrap>", line 1129, in _exec File "<frozen importlib._bootstrap>", line 1471, in exec_module File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed File "/usr/share/youdao-dict/app/plugins/youdao/__init__.py", line 35, in <module> from window import SplashWindow File "/usr/share/youdao-dict/app/plugins/youdao/window.py", line 29, in <module> from models import suggestModel, historyModel File "/usr/share/youdao-dict/app/plugins/youdao/models.py", line 31, in <module> import requests ImportError: No module named 'requests' ATTENTION: default value of option bo_reuse overridden by environment.
缺少依赖 python-requests
离线
wsgdlhy 说:从AUR安装后不能运行
[xx@arch ~]$ youdao-dict Load "youdao" plugin error: No module named 'requests' Traceback (most recent call last): File "/usr/share/youdao-dict/dae/plugins.py", line 81, in load assets.pluginobjects += self.get_plugin_object(plugin_name) File "/usr/share/youdao-dict/dae/plugins.py", line 70, in get_plugin_object plugin = self.load_plugin(plugin_name) File "/usr/share/youdao-dict/dae/plugins.py", line 53, in load_plugin plugin = imp.load_source(plugin_name, os.path.join(path, '__init__.py')) File "/usr/lib/python3.4/imp.py", line 171, in load_source module = methods.load() File "<frozen importlib._bootstrap>", line 1220, in load File "<frozen importlib._bootstrap>", line 1200, in _load_unlocked File "<frozen importlib._bootstrap>", line 1129, in _exec File "<frozen importlib._bootstrap>", line 1471, in exec_module File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed File "/usr/share/youdao-dict/app/plugins/youdao/__init__.py", line 35, in <module> from window import SplashWindow File "/usr/share/youdao-dict/app/plugins/youdao/window.py", line 29, in <module> from models import suggestModel, historyModel File "/usr/share/youdao-dict/app/plugins/youdao/models.py", line 31, in <module> import requests ImportError: No module named 'requests' ATTENTION: default value of option bo_reuse overridden by environment.
缺少依赖 python-requests
谢谢!已经可以运行了,好像就是可以复制粘贴翻译一下,屏幕取词什么的都没用,语种也就那么几个?
[img]http://i.wotula.com/wp.png[/img]
离线
要用屏幕取詞需要安裝
python-pillow (optional) – (unknown)
tesseract (optional) – (unknown)
tesseract-data-chi_sim (optional) – (unknown)
tesseract-data-chi_tra (optional) – (unknown)
這幾個 optdepends 的包
computerは神様だと信じていて
だからVIMの上でずっと指が舞って
自ら恋愛相手を作り出して
离线
有道词典启动的时候会首先启动一个后台服务backend.py,
但是首次启动会提示,所以有道词典打开的话要运行两次,第一次是把backend服务启动,然后再打开。今天上午就有一次xfce4竟然显示了托盘图标,然后就没有然后了。。。
youdao-dict
Youdao Dict Unique Service is started...
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
在Archlinux的wiki中有对这个错误的解释,意思是png图片中的特有profile信息无法识别
Libpng errors
像这样的信息
但是我现在无法定位程序启动的过程中是那个图片资源profile信息无法识别,大部分都有profile信息,有inkscape也有Photoshop CC。
我用上面wiki链接中的办法用 ImageMagick来处理,不过我用的不是convert,而是mogrifty,这个是直接修改文件,不另存。
mogrify -strip logo.png
这个是修改后的文件
我最后把包里面所有的png都做了操作,还是有这样的错误,怎么解决?
离线
XFCE4 安装了所有依赖,包括
tesseract
tesseract-data-eng
tesseract-data-chi-tra
tesseract-data-chi-sim
但是还是没有屏幕取词。
离线
我这里状态栏图标和划词取词都是正常的。你在终端下运行,看看有什么报错
离线
python main.py
Load "youdao" plugin error: /home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/deepin_dict.so: 错误 ELF 类: ELFCLASS32
Traceback (most recent call last):
File "/home/nat/.wine/drive_c/prog/youdao/src/dae/plugins.py", line 81, in load
assets.pluginobjects += self.get_plugin_object(plugin_name)
File "/home/nat/.wine/drive_c/prog/youdao/src/dae/plugins.py", line 70, in get_plugin_object
plugin = self.load_plugin(plugin_name)
File "/home/nat/.wine/drive_c/prog/youdao/src/dae/plugins.py", line 53, in load_plugin
plugin = imp.load_source(plugin_name, os.path.join(path, '__init__.py'))
File "/usr/lib/python3.5/imp.py", line 172, in load_source
module = _load(spec)
File "<frozen importlib._bootstrap>", line 693, in _load
File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 662, in exec_module
File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
File "/home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/__init__.py", line 35, in <module>
from window import SplashWindow
File "/home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/window.py", line 28, in <module>
from utils import get_parent_dir
File "/home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/utils.py", line 35, in <module>
import deepin_dict
ImportError: /home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/deepin_dict.so: 错误 ELF 类: ELFCLASS32
ATTENTION: default value of option bo_reuse overridden by environment.
QXcbWindow: Unhandled client message: "_GTK_LOAD_ICONTHEMES"
怎么解决这错误
离线
python main.py
Load "youdao" plugin error: /home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/deepin_dict.so: 错误 ELF 类: ELFCLASS32
Traceback (most recent call last):
File "/home/nat/.wine/drive_c/prog/youdao/src/dae/plugins.py", line 81, in load
assets.pluginobjects += self.get_plugin_object(plugin_name)
File "/home/nat/.wine/drive_c/prog/youdao/src/dae/plugins.py", line 70, in get_plugin_object
plugin = self.load_plugin(plugin_name)
File "/home/nat/.wine/drive_c/prog/youdao/src/dae/plugins.py", line 53, in load_plugin
plugin = imp.load_source(plugin_name, os.path.join(path, '__init__.py'))
File "/usr/lib/python3.5/imp.py", line 172, in load_source
module = _load(spec)
File "<frozen importlib._bootstrap>", line 693, in _load
File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 662, in exec_module
File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
File "/home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/__init__.py", line 35, in <module>
from window import SplashWindow
File "/home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/window.py", line 28, in <module>
from utils import get_parent_dir
File "/home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/utils.py", line 35, in <module>
import deepin_dict
ImportError: /home/nat/.wine/drive_c/prog/youdao/src/app/plugins/youdao/deepin_dict.so: 错误 ELF 类: ELFCLASS32
ATTENTION: default value of option bo_reuse overridden by environment.
QXcbWindow: Unhandled client message: "_GTK_LOAD_ICONTHEMES"
怎么解决这错误
你从哪里下载的?下错了。你的系统是 64 位的吧?
另外,深度那个有道词典和 Wine 没关系的。
离线