我一直在使用gedit进行大部分C ++以及php编辑几个月,语法高亮处理工作正常。就在最近,我去查看我的一个.cpp文件,语法高亮显示失败了。我尝试了多个其他文件,现在语法高亮显示对所有文件都失败了。 gedit运行时收到以下错误:
(gedit:9833): GLib-CRITICAL **: PCRE library is compiled without UTF8 support
(gedit:9833): GLib-CRITICAL **: g_regex_match_full: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: PCRE library is compiled without UTF8 support
(gedit:9833): GLib-CRITICAL **: g_regex_replace_eval: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: g_regex_unref: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: PCRE library is compiled without UTF8 support
(gedit:9833): GLib-CRITICAL **: g_regex_match_full: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: PCRE library is compiled without UTF8 support
(gedit:9833): GLib-CRITICAL **: g_regex_replace_eval: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: g_regex_unref: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: PCRE library is compiled without UTF8 support
(gedit:9833): GLib-CRITICAL **: g_regex_match_full: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: PCRE library is compiled without UTF8 support
(gedit:9833): GLib-CRITICAL **: g_regex_replace_eval: assertion `regex != NULL' failed
(gedit:9833): GLib-CRITICAL **: g_regex_unref: assertion `regex != NULL' failed
(gedit:9833): GtkSourceView-WARNING **: in file /usr/share/gtksourceview-2.0/language-specs/cpp.lang: style 'c:keyword' not defined
(gedit:9833): GtkSourceView-WARNING **: Failed to load '/usr/share/gtksourceview-2.0/language-specs/cpp.lang': style override used with wildcard context reference in language 'cpp' in ref 'def:line-continue'
这是一个非常令人沮丧的问题,刚刚开始发生,我不知道为什么。
其他信息:
我非常感谢有关此问题的任何帮助或想法。
答案 0 :(得分:0)
在经过大量的讨论之后终于找到了我的问题。我正在处理涉及编辑我的LD_LIBRARY_PATH环境变量的程序,所以我在.cshrc中添加了几行来添加一些共享库。我确保将我新添加的库附加到变量中,但无论出于何种原因,这仍然搞砸了Gedit能够进行语法突出显示的能力。从我的.cshrc脚本中取出setenv命令后,我重启了,Gedit的语法高亮显示恢复正常。
我听说使用LD_LIBRARY_PATH被认为是不好的做法。现在我对可能出现的问题有了第一手的经验。