My favorites | Sign in
Project Home Downloads Wiki Issues Source
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 569: Allow copying from patches
1 person starred this issue and may be notified of changes. Back to list
Status:  WontFix
Owner:  ----
Closed:  May 2010


Sign in to add a comment
 
Project Member Reported by m.bn...@gmail.com, May 14, 2010
When viewing a patch, the contents are not copyable. This is frequently a
problem when trying to test pieces of patches or copy them from other Gerrits.

http://pastebin.com can be referenced for the necessary HTML to achieve this.
May 14, 2010
#1 sop@google.com
By "not copyable" you mean, you can copy it, but its copied
with extra junk on the lines like the line numbers and the
old version of the file.

I can't do what pastebin.com does.  They use <ol><li> tags to
generate the line numbers, and the browser is starting from
number 1 every time.  In side by side or unified diff views we
can start at a non-1 line, and have gaps.

Its nearly impossible to do everything in HTML.  We can choose
to either have the display we have with its dynamic handling of
inline comment editors, or we can choose to have text that is
easy to copy and paste out of the browser.  But we can't have
both.  I'd prefer to have better commenting interfaces, because
we can easily apply the change to our local working directory
by downloading the patch via git and applying it via git's own
native apply or merge commands.
Status: WontFix
May 14, 2010
Project Member #2 m.bn...@gmail.com
Yes, that's what I mean.

I believe that both can be done via HTML. I haven't looked into your current code,
but I believe something like the following would be feasible:

<ol class='unchanged'>
<li>some lines that wont be shown by default</li>
<li>some lines that wont be shown by default</li>
</ol>
<ol start='3'> <!-- or use the non-deprecated CSS attribute counter-reset -->
<li>Some lines around a change</li>
<li>Some lines around a change</li>
</ol>

Is this what you mean?
May 14, 2010
#3 sop@google.com
That doesn't really help me with the left-column/old-version
though.  Its still going to be part of the line copied by the
browser when you copy text.
Sign in to add a comment

Powered by Google Project Hosting