Eclipse代码抄袭 [英] Eclipse code fomatting
本文介绍了Eclipse代码抄袭的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
谢谢,
Scott
解决方案
这是可能的。如果您有HTML / JS编辑器可用(默认情况下是eclipse classic)。
- 转到首选项:常规>编辑器>文件关联,然后添加
*。twig
作为新文件类型,然后添加HTML编辑器(在底部面板中)。 - 然后转到:常规>内容类型,单击文本/ HTML节点(内容类型框),并在底部面板中添加
*。twig
文件关联。
我已经检查过,它的工作原理。
I have some twig files that are a mixture of JavaScript, HTML, and twig markup. Is there a way with Eclipse to hi-lite a section of code and format it as, say JavaScript, then hi-lite another section and format it as HTML? I tried association the file type *.twig with the JavaScript editor, but, I do not seem to get any formatting. Syntax highlighting and code completion would be good too.
Thanks, Scott
解决方案
It is possible. If you have HTML/JS editors available (eclipse classic has them by default).
- Go to preferences and: General > Editors > File Associations and add
*.twig
as a new file type and then add HTML editor (in the bottom panel) to it. - Then go to: General > Content Types, click on Text/HTML node (in Content Types box) and add
*.twig
file association in the bottom panel.
I've checked this and it works.
这篇关于Eclipse代码抄袭的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文