emacs 在 KDE 中的初始位置
我使用 emacs 23.1.1 和 KDE 4.3.1。我已经设置了 (initial-frame-alist) 和 (default-frame-alist) 以使我的窗口出现在我想要的位置。但我的初始窗口没有出现在我想要的地方。
我的初始窗口出现一种字体,更改字体,更改大小,移动(到我想要的位置),然后最终重新定位到其他地方。这是我要阻止的最后一步。
我还需要检查或关闭什么?
初始框架列表的值是
((left . -1)
(vertical-scroll-bars . right)
(menu-bar-lines . 0)
(tool-bar-lines . 0))
默认框架列表的值是
((cursor-color . "yellow")
(foreground-color . "#E0F0FF")
(background-color . "#000000")
(width . 80)
(height . 78)
(top . 0)
(left . 432)
(vertical-scroll-bars . right)
(menu-bar-lines . 0)
(tool-bar-lines . 0))
嗯重复滚动条放置并关闭菜单和工具栏。我可以把它清理掉。无论如何,有什么想法吗?
I use emacs 23.1.1 with KDE 4.3.1. I have set (initial-frame-alist) and (default-frame-alist) to make my windows come up where I want. But my initial window does not come up where I want.
My initial window comes up with one font, changes font, changes size, moves (to where I want) and then finally repositions to somewhere else. It's this last move I want to prevent.
What else do I need to check or turn off?
initial-frame-alist's value is
((left . -1)
(vertical-scroll-bars . right)
(menu-bar-lines . 0)
(tool-bar-lines . 0))
default-frame-alist's value is
((cursor-color . "yellow")
(foreground-color . "#E0F0FF")
(background-color . "#000000")
(width . 80)
(height . 78)
(top . 0)
(left . 432)
(vertical-scroll-bars . right)
(menu-bar-lines . 0)
(tool-bar-lines . 0))
Hmm repeated scroll bar placement and turning off of menu and tool bars. I could clean that up. Anyway, any thoughts?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
听起来 emacs 在读取配置文件之前创建初始框架,然后按照指示移动框架。 (这也是文档声明 .)您需要在创建框架之前更改此设置。这就是 X Windows 资源的用途。
(这涉及到 X 配置的细节,我永远记不起其中的细微差别,但我是这样做的。)
在我的主目录中,我有一个名为 .Xresources 的文件。我在其中设置了 emacs 字体。您需要设置您的 emacs 位置。假设您的字体为 7x12 像素并忽略菜单和滚动条。
现在更新您的 X 设置以反映新设置。在命令提示符下运行
并启动 emacs,希望它位于正确的位置。您需要调整大小以适应菜单和滚动条。该位置可能会稍微偏离,因为它可能应用于未修饰的窗口(即没有标题栏的窗口)。
在我的系统上,登录时会自动读取 ~/.Xresources。如果不适合您,请将命令添加到适当的配置文件(可能是 ~/.profile)。
以下是有关几何规范的 X Windows 文档的链接。这里有emacs 知道的资源的完整列表< /a>.
It sounds like emacs is creating the initial frame before reading your configuration file, then moving the frame as directed. (This is also what the documentation claims.) You need to change this setting before the frame is even created. That's what X Windows resources are for.
(This gets into the details of X configuration, and I can never remember the nuances, but here's how I do it.)
In my home directory, I have a file called .Xresources. In it I set my emacs font. You'll want to set your emacs position. Assuming your fonts are 7x12 pixels and ignoring menus and scroll bars.
Now to update your X settings to reflect the new settings. At the command prompt run
And launch emacs, and hopefully it will be in the correct place. You'll want to play with the size to fit in the menus and scroll bars. The position might be off slightly because it may be applied to the undecorated window (i.e. the window without the title bar).
On my system, the ~/.Xresources is read automatically on log in. If not for you, add the command to the appropriate configuration file (probably ~/.profile).
Here's a link to the X Windows docs on Geometry Specification. And here's a full list of resources that emacs knows about.