Skip to content

XDesk v0.6.6

Choose a tag to compare

@github-actions github-actions released this 19 Nov 17:05
· 190 commits to xdesk since this release

XDesk 0.6.6

中文说明见下方

To your Linux environment XDesk is now a monitor plus its peripherals and nothing more: a screen with the resolution and DPI from XDesk's settings, a sound output, keyboard and mouse, and the phone's input method and clipboard. Your themes, fonts, language, X input method, session scripts and PulseAudio defaults stay yours, also after a crash. It installs over 0.6.5.

A display, not a desktop setup

  • XDesk's X server moved to display :9 (XDESK_DISPLAY=:N changes it). The official Termux:X11 and your own startx.sh use :1: both can run at the same time now, and XDesk never touches an X it did not start (keyboard layout, DPI and resources go only to its own). An XDesk X from 0.6.5 still on :1 is stopped on the next start.
  • No X input method from XDesk. XDesk no longer starts fcitx5, sets XMODIFIERS and the other input method variables, or writes fcitx5's configuration; xdesk ime setup is gone. Start your input method in your session if you use one (see Upgrading). The phone's input method types into X through XDesk as before, with or without one.
  • The keyboard layout chosen in XDesk is set on XDesk's X only and no longer rewrites your fcitx5 profile (xdesk keyboard layout; xdesk ime layout still works).
  • Sound: XDesk no longer makes its output PulseAudio's default or moves other programs' sound to it. Only what XDesk starts plays there (PULSE_SINK=xdesk), so a crash leaves your default as it was. A TCP module you loaded yourself (a startx.sh often does) is used as it is and never unloaded; the copy of the PulseAudio cookie is deleted when XDesk stops.
  • No language and no cursor size in the environment. XDesk no longer sets LANGUAGE; the DPI and cursor size it gives X are a starting value, and a value you set in XFCE wins, also when the screen changes.
  • Only the X server runs at a higher priority; your desktop and programs run at the normal one.
  • XDesk's own D-Bus for switching sessions ends once no desktop and no program uses it. A container's apps-only session gets the window manager alone, without Termux's XFCE look.
  • Closing a Linux program no longer starts a whole desktop that was not running: the home comes instead.

Your start script

  • ~/.config/xdesk/sessions/NAME.sh is XDesk's start script for that desktop: XDesk runs it on the external screen, nothing else reads it, and xdesk never rewrites it. A new one starts with comments on what XDesk sets before it runs (DISPLAY and the sound variables: leave those alone) and what you may add (language, your input method, anything to run first). Your session files are no longer edited in place; an old proot one naming :1 runs on XDesk's display.
  • Settings › Devices › your Linux device › Linux desktops: tap a desktop to edit its start script in Termux ($EDITOR, else nano).
  • Removing a Linux device that is running stops it first.

Install and update

  • install.sh asks before pkg upgrade and before installing Turnip (both change more than XDesk), says which packages it installs, keeps the desktops you removed with xdesk rm, and says the APK in Download may be deleted.

Upgrading

  • Install the APK over 0.6.5, and run xdesk update in Termux. XDesk Receiver and the Mac app are unchanged apart from the version number.
  • If you typed with fcitx5 on XDesk's desktop, it is yours to start now: add to your start script (~/.config/xdesk/sessions/termux-xfce.sh, before the last line) export XMODIFIERS=@im=fcitx GTK_IM_MODULE=fcitx QT_IM_MODULE=fcitx SDL_IM_MODULE=fcitx and start fcitx5 -d, or enable fcitx5 in your XFCE autostart. Termux's fcitx5 shows its candidate window only with dbus-test-tool echo --session --name=org.fcitx.Fcitx5.VirtualKeyboard & started before it, in the same session (XDesk did this for you before; INPUT.md explains why).
  • A shell script or alias of yours that runs programs on XDesk's X with DISPLAY=:1 needs DISPLAY=:9.

XDesk 0.6.6

对你的 Linux 环境来说,XDesk 现在就是一台显示器加一套外设:屏幕(分辨率和 DPI 按 XDesk 的设置)、声卡、键盘鼠标,加上手机输入法和剪贴板,别的都不管。主题、字体、语言、X 里的输入法、会话脚本、PulseAudio 的默认设置都归你自己,XDesk 崩溃后也不会留下改动。可直接覆盖安装 0.6.5。

是显示器,不是桌面配置

  • XDesk 的 X 服务器改用显示号 :9(XDESK_DISPLAY=:N 可改)。官方 Termux:X11 和你自己的 startx.sh 用 :1,现在两边可以同时运行;XDesk 也不会再动不是它启动的 X(键盘布局、DPI、资源只设到自己的 X 上)。0.6.5 留在 :1 上的 XDesk X,下次启动时会被关掉。
  • XDesk 不再管 X 里的输入法。 不再替你启动 fcitx5、不再设 XMODIFIERS 等输入法变量、不再写 fcitx5 的配置,xdesk ime setup 去掉了。用输入法的话,在你自己的会话里启动(见“升级”)。手机输入法照旧经 XDesk 打字进 X,和 X 里有没有输入法无关。
  • 键盘布局:在 XDesk 里选的布局只设到 XDesk 的 X 上,不再改写你的 fcitx5 profile(xdesk keyboard layout,xdesk ime layout 仍可用)。
  • 声音:XDesk 不再把自己的输出设成 PulseAudio 的默认输出,也不再把别的程序的声音拉过去。只有 XDesk 启动的程序在它那里播放(PULSE_SINK=xdesk),崩溃后你的默认输出也不变。你自己加载的 TCP 模块(startx.sh 常这么做)直接沿用,不会被卸载;PulseAudio cookie 的副本在 XDesk 停止时删掉。
  • 不再往环境里塞语言和光标大小。 XDesk 不再设 LANGUAGE;给 X 的 DPI 和光标大小只是初始值,你在 XFCE 里设了就以你的为准,换屏幕时也一样。
  • 只有 X 服务器以较高优先级运行,桌面和程序都是普通优先级。
  • XDesk 为切换会话保留的 D-Bus,在没有桌面、也没有程序用它时就关掉。容器的“只开应用”只起窗口管理器,不再套上 Termux 的 XFCE 外观。
  • 关掉一个 Linux 程序后,不会再启动原本没在运行的整个桌面,而是回到主屏。

你的启动脚本

  • ~/.config/xdesk/sessions/名字.sh 是 XDesk 启动这个桌面用的脚本:XDesk 在外屏上运行它,别的都不读它,xdesk 也不会改写它。新生成的文件开头带注释,写明 XDesk 运行前已经设好的(DISPLAY 和声音那几个变量,别动)和可以加的(语言、你自己的输入法、启动前要跑的命令)。你的会话文件不再被原地修改;老的 proot 会话文件里写的 :1,运行时会换成 XDesk 的显示号。
  • 设置 › 设备 › 你的 Linux 设备 › Linux 桌面:点一个桌面,就在 Termux 里编辑它的启动脚本(用 $EDITOR,没有就用 nano)。
  • 移除一个正在运行的 Linux 设备时,会先停止它。

安装和更新

  • install.sh 在 pkg upgrade 和安装 Turnip 之前会先问你(这两样改动的不只是 XDesk),会说明要装哪些包,不再把你用 xdesk rm 删掉的桌面加回来,最后提示“下载”里的 APK 可以删掉。

升级

  • 覆盖安装 APK,并在 Termux 里运行 xdesk update。XDesk 接收器和 Mac 应用除了版本号没有变化。
  • 如果你在 XDesk 的桌面里用 fcitx5 打字,现在要自己启动它:在启动脚本(~/.config/xdesk/sessions/termux-xfce.sh,最后一行之前)加上 export XMODIFIERS=@im=fcitx GTK_IM_MODULE=fcitx QT_IM_MODULE=fcitx SDL_IM_MODULE=fcitx 并启动 fcitx5 -d,或者在 XFCE 的自启动里打开 fcitx5。Termux 的 fcitx5 要在同一个会话里先运行 dbus-test-tool echo --session --name=org.fcitx.Fcitx5.VirtualKeyboard &,才会显示候选框(以前是 XDesk 替你做的,原因见 INPUT.md)。
  • 你自己的脚本或别名如果用 DISPLAY=:1 往 XDesk 的 X 上开程序,要改成 DISPLAY=:9。