是否可以在RubyMine 3.2.4中格式化或重新加载html?我试过Code... Reformat Code
,但它似乎没有为HTML做任何事情。我需要一个插件吗?是否有可能在html中格式化/重排html?
4
A
回答
4
它确实有效。
使用生成标准404.html文件:
<!DOCTYPE html>
<html>
<head>
<title>The page you were looking for doesn't exist (404)</title>
<style type="text/css">
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
div.dialog {
width: 25em;
padding: 0 4em;
margin: 4em auto 0 auto;
border: 1px solid #ccc;
border-right-color: #999;
border-bottom-color: #999;
}
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
</style>
</head>
<body>
<!-- This file lives in public/404.html -->
<div class="dialog">
<h1>The page you were looking for doesn't exist.</h1>
<p>You may have mistyped the address or the page may have moved.</p>
</div>
</body>
</html>
我使用的代码/格式化选项,它导致了以下内容:
<!DOCTYPE html>
<html>
<head>
<title>The page you were looking for doesn't exist (404)</title>
<style type="text/css">
body {
background-color: #fff;
color: #666;
text-align: center;
font-family: arial, sans-serif;
}
div.dialog {
width: 25em;
padding: 0 4em;
margin: 4em auto 0 auto;
border: 1px solid #ccc;
border-right-color: #999;
border-bottom-color: #999;
}
h1 {
font-size: 100%;
color: #f00;
line-height: 1.5em;
}
</style>
</head>
<body>
<!-- This file lives in public/404.html -->
<div class="dialog">
<h1>The page you were looking for doesn't exist.</h1>
<p>You may have mistyped the address or the page may have moved.</p>
</div>
</body>
</html>
你可以看到它是如何重新格式化特别是样式(如果我改变换行符等,它也修复了这些问题)。
如果您转到文件/设置,IDE设置/编辑器,然后确保选中显示“重新格式化代码”对话框已选中[x],请重试。它可能被设置为仅修复选定的文本?或...
2
您可以使用⌘+⌥+ l键盘快捷键。
0
您可以更改“项目设置>代码样式> HTML”中的html格式选项。
例如:你可以改变标签的大小,缩进等
如果你是在OSX上,你可以使用快捷键⌘+,
其他建议:尝试重命名格式之前的文件(除从它的.erb)
相关问题
- 1. Visual Studio ASP.NET/HTML重新格式化功能 - 它是否存在?
- 2. WP 7.5 - 是否有可以格式化HTML的控件?
- 3. 在Adobe Brackets中重新格式化HTML
- 4. 重新格式化HTML
- 5. 是否有可能呈现HTML在Gmail
- 6. JList中的项目是否可以格式化为HTML
- 7. 在VBA中格式化HTML
- 8. 在JSP中格式化HTML
- 9. SharePoint Designer在运行中重新格式化HTML,能够禁用?
- 10. 是否有可能存储数据json到html(不是表格)
- 11. 是否有可能HTML来导入*
- 12. Visual Studio中重新格式化我的预格式化HTML
- 13. 是否有可能有一个jqgrid treegrid单元格内的html
- 14. HTML排序列表格式化
- 15. 在HTML中格式化嵌套表格
- 16. 格式化HTML表
- 17. HTML块格式化
- 18. Jlabel HTML格式化
- 19. 的Html格式化
- 20. 是否有可能为单独的href格式化单元格
- 21. AngularJS/HTML表格格式化
- 22. 是否有可能在RSpec中有参数化的规格?
- 23. 是否有可能封装JSON格式内HTML或JavaScript的多行?
- 24. 是否有可能在EMACS中用CSS编写HTML-withASP-withJavascript-withCSS?
- 25. 是否有可能在Dreamviwer中拖放html元素cs6
- 26. 是否有可能在android中使用html代码?
- 27. 是否有可能阻止在HTML中包装子元素?
- 28. 是否有可能在PHP中使用HTML?
- 29. 是否有可能在CSS中读取HTML?
- 30. 是否有可能在内存中重新排序linq IQueryable?
我看到你是对的。我期待VS更像VS, RubyMine在清理空白时并不像VS那么具有攻击性。 – jcollum
同意。我喜欢VS一般更好一点,尤其是有更多的控制。 – WiredPrairie