X11原子XA_WM_NAME和"_NET_WM_NAME"有什么区别吗? [英] Is there any difference with the X11 atoms XA_WM_NAME and "_NET_WM_NAME"?

查看:189
本文介绍了X11原子XA_WM_NAME和"_NET_WM_NAME"有什么区别吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Xatom.h中定义的XA_WM_NAME中定义的原子和使用XInternAtom(display, "_NET_WM_NAME", False)获得的原子有什么区别吗?

Is there any difference with the atom defined in XA_WM_NAME defined in Xatom.h and the one got using XInternAtom(display, "_NET_WM_NAME", False)?

我做了一个小程序,打印了两者的整数值,我得到了:_NET_WM_NAME: 312, XA_WM_NAME: 39,所以它们代表了不同的原子.有什么区别?

I made a little program which prints the integer value of both and I got: _NET_WM_NAME: 312, XA_WM_NAME: 39, so, they represent different atoms. What are the differences?

谢谢.

推荐答案

它们是不同的原子,但是它们都代表窗口的标题.

They are different atoms, but they both represent the title of the window.

_NET_WM_NAME 是新版 XDG/freedesktop.org窗口管理器规范. 与其他XDG字符串属性一样,它定义为UTF-8编码的字符串,而旧版" WM_NAME使用X复合文本"编码.

_NET_WM_NAME is part of the newer XDG/freedesktop.org window manager spec. Like other XDG string properties, it's defined as a UTF-8 encoded string, whereas the "legacy" WM_NAME uses the X "compound text" encoding.

遵守XDG规范的窗口管理器将使用_NET_WM_NAME属性而不是WM_NAME(如果同时设置了这两个属性).

Window managers that respect the XDG spec will use the _NET_WM_NAME property instead of WM_NAME if both are set.

这篇关于X11原子XA_WM_NAME和"_NET_WM_NAME"有什么区别吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆