AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / ubuntu / 问题 / 1266451
Accepted
user1046658
user1046658
Asked: 2020-08-12 17:15:14 +0800 CST2020-08-12 17:15:14 +0800 CST 2020-08-12 17:15:14 +0800 CST

无法在 gedit 中单击首选项中的复选框

  • 772

当我使用geditinUbuntu 20.04时,每当我单击 中的任何复选框时Preferences,都不会发生任何事情。

喜好

例如,当我单击 时Display line numbers,该复选框仍标记为已选中。出于某种原因,点击Display grid pattern、Enable text wrapping、 和Do not split words over two lines可以,但是当我退出Preferences并重新进入时,它们会回到原来的状态,如图所示。

其他选项卡中的所有其他选项都无法更改。

编辑:作为普通用户使用时显然Preferences有效,而不是root用户。gedit以前,我试图更改Preferences为 root

现在,我想知道为什么 Preferences 不能以 root 身份更改。我注意到,当我gedit以普通用户身份使用时,终端上没有弹出任何内容,但是当我gedit以 root 身份打开时,终端中会显示以下消息:

(gedit:2024): dconf-WARNING **: 21:01:08.260: failed to commit changes to dconf: The connection is closed

(gedit:2024): dconf-WARNING **: 21:01:08.270: failed to commit changes to dconf: The connection is closed
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)

(gedit:2024): dconf-WARNING **: 21:01:08.509: failed to commit changes to dconf: The connection is closed

(gedit:2024): dconf-WARNING **: 21:01:08.509: failed to commit changes to dconf: The connection is closed

(gedit:2024): dconf-WARNING **: 21:01:08.510: failed to commit changes to dconf: The connection is closed
XDG_RUNTIME_DIR (/run/user/1000) is not owned by us (uid 0), but by uid 1000! (This could e.g. happen if you try to connect to a non-root PulseAudio as a root user, over the native protocol. Don't do that.)
XDG_RUNTIME_DIR (/run/user/1000) is not owned by us (uid 0), but by uid 1000! (This could e.g. happen if you try to connect to a non-root PulseAudio as a root user, over the native protocol. Don't do that.)

(gedit:2024): dconf-WARNING **: 21:04:00.840: failed to commit changes to dconf: The connection is closed
XDG_RUNTIME_DIR (/run/user/1000) is not owned by us (uid 0), but by uid 1000! (This could e.g. happen if you try to connect to a non-root PulseAudio as a root user, over the native protocol. Don't do that.)
XDG_RUNTIME_DIR (/run/user/1000) is not owned by us (uid 0), but by uid 1000! (This could e.g. happen if you try to connect to a non-root PulseAudio as a root user, over the native protocol. Don't do that.)
gedit preferences 20.04
  • 1 1 个回答
  • 261 Views

1 个回答

  • Voted
  1. Best Answer
    heynnema
    2020-08-13T09:18:15+08:002020-08-13T09:18:15+08:00

    启动 GUI 应用程序时,如gedit,使用sudo,您必须使用sudo -H,如下所示:

    sudo -H gedit /path_to/filename
    
    • 1

相关问题

  • 键入 C++ 时在 Gedit 中更改“字符串”的颜色

  • 真正的列模式(块选择和编辑)文本编辑器解决方案?

  • 更改默认 BitTorrent 程序

  • 支持 gedit 中的各种功能

  • Gedit 中是否支持拆分窗格?

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve