问题标签 [emacs-faces]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
regex - 找出哪个正则表达式导致 Emacs 中的特定面孔
我试图找出哪个正则表达式导致在此缓冲区connect
中突出显示。告诉我这是一个. 看了之后,我看不出这个亮点可能来自哪里。五颜六色的花环是由.cperl-mode
describe-face
font-lock-type-face
font-lock-keywords-alist
font-lock-keywords
rainbow-delimiters-mode
是否有检查哪个正则表达式匹配的功能,以便用这张脸突出显示连接?
emacs - EMACS,函数调用高亮
(EMACS 24.2) 我需要突出显示函数调用。我在网上找到了这个
它有效,但它也突出显示以下左括号。我对正则表达式没有信心,请问如何修改匹配字符串以避免括号突出显示?
emacs - 在新的 Emacs 24.3 中调整术语面
如何term
在新的 Emacs 中调整面以获得与ansi-term-color-vector
.
Emacs 24.3中的新特性之一似乎是它改进了控制term
缓冲区面的机制,即:
变量
term-default-fg-color
和term-default-bg-color
现在已弃用,取而代之的是可定制的 faceterm
。
term-color-COLOR
您可以通过自定义相应的,term-color-underline
和term-color-bold
面来自定义如何显示 ANSI 终端颜色和样式。
来自 Mastering Emacs 的 Mickey评论如下:
如果像我一样,您自定义
ansi-color-names-vector
更改默认术语颜色,我建议您现在切换到使用面孔。这里的好消息是,您可以(应该希望)更改的不仅仅是每种 ANSI 颜色的颜色:没有什么能阻止您为某些颜色强制使用不同的字体
像 Mickey 一样,我也ansi-color-names-vector
用来确保term
缓冲区的颜色在深色主题上看起来很好(例如tango-dark
)
但这现在会导致错误:
为了尝试使用新面孔term
,当我转到 时M-x describe-face term
,我看到以下内容:
但是如何调整这些设置以获得与使用相同的效果ansi-term-color-vector
?
更新
我仍然无法修复颜色。这是我得到的菜单M-x customize-theme tango-dark
:
这是终端中难以看到的颜色/面之一的示例:
emacs - 自定义 HTML 标头的面(h1、h2 等)
我对 emacs 很陌生,尽管有很棒的在线文档,但我不知道如何自定义应用于 HTML 标头标记(例如<h1>Content here</h1>
)之间的内容的面部,以便在 emacs 中内容不会显示为带下划线或粗体。换句话说,我希望这样的内容完全没有装饰,作为纯默认文本显示。
一般来说,如何定制基于句法(不是基于关键字)的突出显示?
有谁知道如何进行?
emacs - 如何重构这个 Emacs lisp?
我对动态符号等的语法不太满意。我想我可能可以dolist
在这里做一些颜色列表,但不确定是什么:
emacs - 在 Emacs 中自定义突出显示面:仅更改背景颜色
hl-line
有没有办法在Emacs中定义一个面(例如突出显示,如
更具体地说,我在tango-dark
主题上尝试了以下内容
并且,如下所示,区域突出显示确实尊重前景字体(即它只改变背景颜色):
但当前行的突出显示不会:
为什么?我怎样才能得到同样的效果hl-line
?
更新:
这似乎是主题中的一个错误tango-dark
(Emacs 的内置主题)。该代码适用于默认主题(使用 加载emacs -Q
)。我在官方错误邮件列表上发布了这个。
emacs - .emacs 中的多个自定义设置面和自定义设置变量?
当我通过菜单自定义面部M-x customize-face
并将更改保存到磁盘时,Emacs 将自动生成的代码添加到我的.emacs
文件中,如下所示:
SOME CODE
类似的东西在哪里:
现在,假设我想手动更改SOME CODE
,并且可能添加更多代码来修改其他面孔。将这些更改保留在custom-set-faces
块下是否明智?或者我应该把它移到另一个块(以避免 Emacs 混淆)
另外,Emacs 会因为我有多个 (custom-set-faces ... )
块而感到困惑吗?(同样的问题(custom-set-variables ...)
emacs - 如何为 gnus-group-topic emacs24 自定义人脸?
我正在尝试在 gnus-group-mode 中设置主题名称的颜色。我尝试查找人脸名称,以便设置颜色属性,但根据我正在查找的主题的字母,我将默认或 ascii 字符作为人脸名称。
查找 gnus 的源代码,我想出了这个函数。但是,在阅读文档的面部部分后,我不确定如何将面部分配给函数(如果这是正确的做事方式)。
emacs - 根据主要模式更改 Emacs Mode-Line 颜色
我想看看是否有办法根据主模式更改模式链接前景色和背景色,
我正在考虑在
但是,我没有进行这种改变的所有 emacs lisp 经验。这是逻辑:
提前谢谢了!。
regex - Match one backlash; match two backslashes; match tilde + two backslashes
I'm interested in seeing if it is possible to match just 1 backslash, and just 2 backslashes, and a tilde plus two backslashes. I'm using Emacs in latex-mode and am setting up keywords for font-lock. Defining a single backslash as a keyword wreaks havoc on a variety of other definitions. I'd like one backslash to be red; two backslashes to be blue; and a tilde+two-back-slashes to be green. I don't think the tilde will pose a problem, but I'd like that to be red all by itself. I've got the font-lock-add-keywords format, but not the special regex for this type of a situation. This is similar to the situation that we would use \b for before and after, but that won't work with backslashes as far as I know.
~
-- red
\
-- red, except
when touching alphanumeric characters.
\\
-- blue
~\\
-- green
In the context of the example mentioned above, defining a single backslash nullifies the predefined warnings of font-latex.el
within auctex-11.86
at lines 280-285. Removing the "\\"
from the fourth line of code doesn't remedy the situation. Typing \newpage
, for example, no longer is associated with font-latex-warning-face
-- instead, it comes up as undefined, which is assigned to font-latex-sedate-face
.
BUFFER EXAMPLE -- latex-mode:
\newpage
-- font face should be font-latex-warning-face
\newpage
-- font face erroneously appears as font-latex-sedate-face
when defining a single backslash as noted hereinabove.
EDIT -- troubleshooting -- testing -- screenshots of re-builder
and a LaTeX document:
(source: lawlist.com)
(source: lawlist.com)
(source: lawlist.com)