Index: app/views/common/_diff.html.erb =================================================================== --- app/views/common/_diff.html.erb (revision 21371) +++ app/views/common/_diff.html.erb (working copy) @@ -6,7 +6,7 @@ <% diff.each do |table_file| -%>
<% if diff.diff_type == 'sbs' -%> - +
- + <% end -%> - + - + <% end -%> @@ -39,7 +39,7 @@
@@ -21,17 +21,17 @@ <% table_file.each_line do |spacing, line| -%> <% if spacing -%>
......
<%= line.nb_line_left %> -
<%= line.html_line_left.html_safe %>
+
<%= line.html_line_left.html_safe %>
<%= line.nb_line_right %> -
<%= line.html_line_right.html_safe %>
+
<%= line.html_line_right.html_safe %>
<% else -%> - +
<% end -%> - - + + <% end -%> Index: app/views/common/_file.html.erb =================================================================== --- app/views/common/_file.html.erb (revision 21371) +++ app/views/common/_file.html.erb (working copy) @@ -4,11 +4,13 @@ <% line_num = 1 %> <% syntax_highlight_lines(filename, Redmine::CodesetUtil.to_utf8_by_setting(content)).each do |line| %> - + <% line_num += 1 %> Index: app/views/repositories/annotate.html.erb =================================================================== --- app/views/repositories/annotate.html.erb (revision 21371) +++ app/views/repositories/annotate.html.erb (working copy) @@ -17,7 +17,7 @@ <% syntax_highlight_lines(@path, Redmine::CodesetUtil.to_utf8_by_setting(@annotate.content)).each do |line| %> <% revision = @annotate.revisions[line_num - 1] %> - + - + <% if line == "\n" or line == "\r\n" %> + + <% else %> + + <% end %> <% line_num += 1; previous_revision = revision %> <% end %> Index: public/stylesheets/scm.css =================================================================== --- public/stylesheets/scm.css (revision 21371) +++ public/stylesheets/scm.css (working copy) @@ -61,8 +61,14 @@ text-decoration: none; color: inherit; } +table.filecontent th.line-num a:after { + content: attr(data-txt); +} +table.diffcontent th.line-num:after { + content: attr(data-txt); +} table.filecontent td.line-code {padding: 0 0 0 4px;} -table.filecontent td.line-code pre { +table.filecontent td.line-code pre, table.filecontent td.line-code div { margin: 0px; white-space: pre-wrap; font-family:Consolas, Menlo, "Liberation Mono", Courier, monospace; font-size:12px;
@@ -58,10 +58,10 @@
<%= line.nb_line_left %><%= line.nb_line_right %> -
<%= line.html_line.html_safe %>
+
<%= line.html_line.html_safe %>
- <%= line_num %> - -
<%= line.html_safe %>
+ <% if line == "\n" or line == "\r\n" %> +
+ <% else %> +
<%= line.html_safe %>
+ <% end %>
<%= line_num %> <% if revision && revision != previous_revision %> <%= revision.identifier ? @@ -31,7 +31,11 @@ <%= author.split('<').first %> <% end %>
<%= line.html_safe %>

<%= line.html_safe %>