简体   繁体   English

X11转发,如何改变奇怪的颜色?

[英]X11 forwarding, how to change strange colors?

I have an old SUN Solaris 2.5 box, which controls very important hardware from the 1990s. 我有一个旧的SUN Solaris 2.5盒,它可以控制1990年代起非常重要的硬件。 I need this old thing because a replacement would cost me 80 kEuros (!). 我需要这件旧东西,因为更换一块东西要花我80欧元(!)。 The OS of the SUN does not have ssh, and even not utilities like pkgadd or compilers ... ;-) SUN的操作系统没有ssh,甚至没有实用程序,例如pkgadd或编译器... ;-)

Since the GPU has become somewhat 'weak' (I already lost one GPU card) I sent the X11 graphics of the program, which controls the hardware, to a Lubuntu 14.04 (64Bit) box, via 'setenv DISPLAY IPaddress:0.0' (this is sometimes referred as to be X11 forwarding). 由于GPU变得有些“弱”(我已经丢失了一张GPU卡),因此我通过“ setenv DISPLAY IPaddress:0.0”将控制硬件的程序的X11图形发送到了Lubuntu 14.04(64位)盒中(有时称为X11转发)。 Everything works quite well, in particular the system has become very fast (!). 一切正常,特别是系统变得非常快(!)。 By the way, on the Ubuntu box, I merely had to install telnetd and to remove this '-nolisten' via a config file inside /etc/lightdm/lightdm.d.config/. 顺便说一句,在Ubuntu机器上,我只需要安装telnetd并通过/etc/lightdm/lightdm.d.config/中的配置文件删除此“ -nolisten”。

So far, so good. 到现在为止还挺好。 There is one severe problem now: the windows on the Ubuntu desktop (there are several windows) have different colors in comparison to the 'normal' case where the SUN runs the graphics (no forwarding). 现在存在一个严重的问题:与SUN运行图形(不转发)的“正常”情况相比,Ubuntu桌面上的窗口(有多个窗口)具有不同的颜色。 Some important text appears in a very dark gray color on a black background (text color rgb: 3/3/3 on 0/0/0 background). 一些重要的文本在黑色背景上以非常深的灰色显示(文本颜色rgb:0/0/0背景上为3/3/3)。 The general window color has a rgb value of 114/159/255 (medium purple1), which also is strange. 常规窗口颜色的rgb值为114/159/255(中等紫色1),这也很奇怪。 Overall, very important text cannot be read, which is bad. 总体而言,非常重要的文本无法阅读,这很糟糕。

Obviously, there is a mismatch of color understanding between the Ubuntu box from today and the SUN from the 1990s, no wonder. 显然,今天的Ubuntu盒与1990年代的SUN盒之间在颜色理解上不匹配,这也就不足为奇了。

I tried out the following things without success: 我尝试了以下方法但没有成功:

  • Playing around with the desktop themes in Lubuntu 玩弄Lubuntu中的桌面主题
  • Changing the color depth of the Ubuntu system via a xorg.conf file 通过xorg.conf文件更改Ubuntu系统的颜色深度
  • Xephyr and xnest with standard parameters Xephyr和xnest具有标准参数
  • Changing color values in this rgb.txt file in /usr/share/X11/ on the Ubuntu box 在Ubuntu盒子上的/ usr / share / X11 /中更改此rgb.txt文件中的颜色值

How can I change the colors, can somebody help me? 我该如何改变颜色,有人可以帮我吗? Note that under Windows2000 and Xming things work very well. 请注意,在Windows2000和Xming下,一切正常。 However, I don't want to use Windows. 但是,我不想使用Windows。

I have in mind to … 我要记住...

  • use an older Linux system, which still understands the SUN from the 1990s, 使用较旧的Linux系统,该系统仍然了解1990年代的SUN,
  • use a different window manager like fvwm, 使用其他窗口管理器,例如fvwm,
  • ... ...

Thanks for some comments. 感谢您的评论。

I'm proud to offer a solution myself! 我为自己提供解决方案感到自豪!

Everything makes sense, in particular when considering Linux systems of today on the one hand, and old SUN workstations from the 1990s on the other: both they do not 'understand' each other with respect to X11 colors and therefore the recent Linux system needs to combine old with the old, as follows … : 一切都说得通,尤其是一方面要考虑当今的Linux系统,另一方面要考虑1990年代的老式SUN工作站:它们在X11颜色方面彼此不“了解”,因此,最近的Linux系统需要结合旧与旧,如下:

One needs to start Xephyr in 8 bit resolution first because the SUN understands only 8 bit: 首先需要以8位分辨率启动Xephyr,因为SUN只能理解8位:

Ubuntu > Xephyr :1 -ac -br -screen 1920x1080x8 -reset -terminate &

So far, we have an X server with 8 bit colors. 到目前为止,我们有一台具有8位颜色的X服务器。 Next we need a window manager that still understands the 'old way' of X forwarding. 接下来,我们需要一个窗口管理器,它仍然了解X转发的“老方法”。 Let's use therefore fvwm and start it in the latter X server: 因此,我们使用fvwm并在后面的X服务器中启动它:

Ubuntu > DISPLAY=:1 fvwm &

Then we do telnet to the SUN. 然后,我们将telnet连接到SUN。 Before, we have to add first the IP address of the SUN to xhost on the Ubuntu box: 在此之前,我们必须先将SUN的IP地址添加到Ubuntu盒子上的xhost:

Ubuntu > xhost + IPaddress_SUN

Then ... 然后 ...

Ubuntu > telnet IPaddress_SUN

... and login on the SUN. ...然后登录SUN。

On the SUN we type: 在SUN上,我们输入:

SUN > setenv DISPLAY IPaddress_Ubuntu:1.0

Note, that one needs to choose the correct X server on the Ubuntu box by typing ...:1.0 请注意,您需要通过输入...:1.0在Ubuntu框中选择正确的X服务器。

Then one can start the application 然后可以启动该应用程序

SUN > <application_name>

That's it. 而已。 Thanks for some comments and credits. 感谢您的评论和感谢。

PS: One cannot use the window manager 'xfce4-session', it simply displays wrong colors. PS:不能使用窗口管理器“ xfce4-session”,它只会显示错误的颜色。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM