Issue 125717 - insert frame should not add newline
Summary: insert frame should not add newline
Status: UNCONFIRMED
Alias: None
Product: Writer
Classification: Application
Component: editing (show other issues)
Version: 4.1.1
Hardware: All All
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-06 02:33 UTC by TAB
Modified: 2017-04-21 18:11 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
file with frames (16.13 KB, application/vnd.oasis.opendocument.text)
2014-10-06 02:33 UTC, TAB
no flags Details
file with cells to copy (7.77 KB, application/vnd.oasis.opendocument.spreadsheet)
2014-10-06 02:41 UTC, TAB
no flags Details
125717-bugzill-step-6.png (126.04 KB, image/png)
2014-10-08 00:37 UTC, Bugzill Apatcheer
no flags Details
125717-bugzill-step-9.png (139.68 KB, image/png)
2014-10-08 00:38 UTC, Bugzill Apatcheer
no flags Details
125717-bugzill-step-11.png (151.79 KB, image/png)
2014-10-08 00:38 UTC, Bugzill Apatcheer
no flags Details
125717-bugzill-step-14.png (136.96 KB, image/png)
2014-10-08 00:38 UTC, Bugzill Apatcheer
no flags Details
Screenshots (831.77 KB, application/x-7z-compressed)
2017-04-15 20:20 UTC, Sergiusz Golec
no flags Details
Bug overview in one image (390.07 KB, image/jpeg)
2017-04-21 18:11 UTC, Sergiusz Golec
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description TAB 2014-10-06 02:33:42 UTC
Created attachment 84017 [details]
file with frames

Open Figs.odt and Figs.ods. In Figs.ods, copy (^c) A1 to the clipboard, and paste it (^v) to the end of Figa: 'aa' appears in a new parag (visible as nonprinting char EOL) below 'Figa'.
	Now, click the graphic under Figb, copy it to the clipboard, and paste it (^v) to the end of 'Figc': the graphic appears OVER 'Figc'. So, to obtain the graphic under 'Figc', you must first hit Enter to make a new parag.
	If you delete the frame 'aa' from Figa, the new parag that was created remains; so, if you copy-and-paste cell B1 (because you wanted to replace 'aa' with 'bb'), you get it in another new parag; the 'old-new' parag associated with 'aa' must be deleted --annoying.
	Summary: the behaviour of paste (automatically adding, or not, a new parag) depends on the object. It should be consistent. Adding automatically a new parag may seem convenient, but it's unexpected (counter-intuitive), and annoying when replacing the object.
Conclusion: paste should not add a new parag; that's an unexpected side-effect.
Comment 1 TAB 2014-10-06 02:41:50 UTC
Created attachment 84018 [details]
file with cells to copy
Comment 2 Bugzill Apatcheer 2014-10-08 00:36:20 UTC
I managed to replicate the bug with following steps:

1. Download "file with frames" (Figs.odt) and "file with cells to copy" (Figs.ods) attachments.
2. Open Figs.odt in OO Writer.
3. Open Figs.ods in OO Calc.
4. Click on A1 cell in Figs.ods and press ctrl+c
5. Place cursor at the end of word "Figa" in Figs.odt and press ctrl+v
6. Observe a frame with "aa" appear with a new paragraph symbol (see 125717-bugzill-step-6.png screenshot).
7. Click on the graphic under "Figb" word in Figs.odt and press ctrl+c
8. Place cursor at the end of word "Figc" in Figs.odt and press ctrl+v
9. Observe the graphic appearing over the "Figc" word without any paragraph symbol being added (see 125717-bugzill-step-9.png screenshot).
10. Click on "aa" under "Figa" in Figs.odt to select it and press Delete on keyboard to delete it.
11. Observe a paragraph that was added with "aa" remaining (see 125717-bugzill-stpe-11.png screenshot).
12. Click on B1 cell in Figs.ods and press ctrl+c
13. Place cursor at the end of word "Figa" in Figs.odt and press ctrl+v
14. Observe a frame with "bb" appear with a new paragraph symbol (see 125717-bugzill-step-14.png screenshot).

Note that ^c and ^v are just another names for ctrl+c and ctrl+v that are more used on unix-like systems.

I wanted to see if other objects besides the frame add the new paragraph when being inserted, so I did the next follow-up tests:
1. Create a new OO Writer document (call it Document A).
2. Add a chart with Insert->Object->Chart...
3. Create another new OO Writer document (call it Document B).
4. Copy the chart from Document A with ctrl+c
5. Paste the chart into Document B with ctrl+v
6. Observe that the pasted chart didn't add any paragraph symbols to Document B.

1. Create a new OO Writer document (call it Document A).
2. Add a picture with Insert->Picture->From File...
3. Create another new OO Writer document (call it Document B).
4. Copy the picture from Document A with ctrl+c
5. Paste the picture into Document B with ctrl+v
6. Observe that the pasted picture didn't add any paragraph symbols to Document B.

It looks like copy-pasting charts and pictures from other documents doesn't case new paragraphs to be added.


System:
Windows 7 64bit,
clean install of Apache OpenOffice 4.1.1
AOO411m6(Build:9775)  -  Rev. 1617669
2014-08-13 09:06:54 (Mi, 13 Aug 2014)
Comment 3 Bugzill Apatcheer 2014-10-08 00:37:29 UTC
Created attachment 84033 [details]
125717-bugzill-step-6.png
Comment 4 Bugzill Apatcheer 2014-10-08 00:38:08 UTC
Created attachment 84034 [details]
125717-bugzill-step-9.png
Comment 5 Bugzill Apatcheer 2014-10-08 00:38:28 UTC
Created attachment 84035 [details]
125717-bugzill-step-11.png
Comment 6 Bugzill Apatcheer 2014-10-08 00:38:44 UTC
Created attachment 84036 [details]
125717-bugzill-step-14.png
Comment 7 TAB 2014-10-12 13:56:08 UTC
Comment 2 items 6 and 14 confirm the problem: new parag added for SOME paste operations. 'other objects' don't add any paragraph..
Comment 8 Sergiusz Golec 2017-04-15 20:20:24 UTC
Created attachment 86003 [details]
Screenshots

Extra (End Of Line / newline / paragraph) character is added in OO Writer, when user inserts a cell from the OO Calc.

I was able to reproduce the issue, both with copied Cell and the Table. 
And I discovered something new, including:
* Selected cell is not replaced when we paste (via Ctrl+v) the new cell. We have to delete the selected cell 1st, or paste a new cell in a different place (and delete original cell). Which is a potential for the effort optimisation.
* ODS ('OO Calc') cells are pasted in an ODT (OO Writer), via Ctrl+c/v, as an embedded Calc software. Not as a plain text. Or a table. (Alike from Google Docs Spreadsheet.)
* Copied "Calc cell" from Writer, into a Calc (into a different cell) - are pasted in an ODS (OO Calc) as an embedded Calc software. It's like Calc within a Calc. Which makes little to no sense for 1 cell.
* Copy paste a cell (text) or a table from Writer into Calc, results in an extra issue with a typeface identification - Calc is not showing the font name. Even if it displays the content, formatted as per the original source in a Writer. 

Tests::
Test 1 - reproduction of steps mentioned by Bugzill Apatcheer (in a post from 2014-10-08 00:36:20 UTC). 
I confirm - I have the same outcome. The same problem is observed: Extra (End Of Line / paragraph) character is added in OO Writer, when user inserts a cell from OO Calc.
(Plsease reffer to Bugzill Apatcheer steps from the mentioned post, when needed.)

Test 2 - In ODT (Writer) try to replace 1 ODS (Calc) cell with another ODS (Calc) cell.  
1. Copy cell A1 (with 'aa' text) from Figs.ODS (Calc) into Figs.ODT (Writer) \ 'Figa' frame. Via Ctrl+c/v.
2. Select new cell 'aa' in ODT (Writer). 
3. Copy cell B1 ('bb') from Figs.ODS (Calc) into Figs.ODT (Writer) \ 'Figa' frame \ cell 'aa'. Via Ctrl+c/v.
Result - the cell is not replaced.
4. I set a new place in the ODT (Writer) document - so the 'aa' cell was not selected. And with ctrl+v, I was able to paste the B1 'bb' cell. (From the same memory buffer.)

Test 3 - ODS ('OO Calc') cells as an embedded software in a Writer.
5. Double click the newly inserted cell 'aa' in ODT (Writer). 
Result: ODS (Calc) document loads within the ODT (Writer) as an embedded 'OO Calc' software.
Note: 
a) Copied table (2 columns x 3 rows) from ODS (Calc) into ODT - results in one extra paragraph in a Writer. 
b) Copied cell from ODS into Notepad++ - results in one extra paragraph in Notepad++.
c) Copied table (2 columns x 3 rows) from ODS into Notepad++ - results in one extra paragraph in a Notepad++.

Test 4  - compare Calc with Google Docs Spreadsheet (GDS)
6. Open online GDS. Copy cell with 'Q' text. And paste it into ODT document.
Result: 'Q ' is shown in ODT document.
7. Copy (GDS) cell with "A" text. Paste in ODT - it results in "A ". Same text with extra space sign ' ' at the end.
8. Copy (GDS) cell with "Blah-blah" text. And in ODT it becomes "Blah-blah ".  Same text with extra space sign ' ' at the end.
Result: 
Single cells copied from Google GDS and pasted in ODT - results in an extra space ' ' at the end of the cell text.
Single cells copied from OO ODS and pasted in ODT - results in an extra paragraph (end of line / newline sign) 

Test 5 - Repeat test 4 for "3 columns x 2 rows" table (with every cell filled with 1 text letter "A, B, C, D, E, F")
Result: In ODT a new table is pasted. The only change observed is that transparent table border in GDS becomes not transparent in ODT. Yet it's shown as a table. And not as an embedded application (with table).

Test 6 - Embed Calc within Calc by copying "Calc cell" from the Writer.
1. Make sure that in the ODT document there is A1 ('aa') cell pasted from ODS document. ODT with embedded Calc is available.
2. Select 'aa' cell in ODT document and press Ctrl+C (copy).
3. In the OO Calc, paste the memory buffer via Ctrl+V. (In a free space / empty cell).
Result: The copied cell, in Calc has an extra green border.
4. Double click the new cell.
Result: In Calc, the embedded Calc is loaded.
Expected result: Cell (from Calc) is copied as a Cell. And not as an embedded Calc.
Note: There might be a potential for a bigger issue here. If we embed one Calc into another. And repeat the same several times. Alike Folder 10 in Folder 9, which is in Folder 8, which is in Folder 7, etc.

Test 7 - Table from Writer (originally GDS) copy into Calc. And check the fonts.
1. Copy table (3columns x 2 rows) from ODT (originally copied from GDS) into the ODS (Calc).
Result: The table is copied (with not transparent borders). 
ODS (Calc) - shows empty Font and Size of the copied text in the table. When ODT shows "Times New Roman;12". When in Calc, in a new cell, I've entered the same text and formatted it as "Times New Roman;12" - I could not see the difference between the cells (except the empty font from a copied table from ODT).


OO 4.2.0.    AOO420m1(Build:9800)  -  Rev. 1785175
Windows 7 Professional Edition (64-bit) Service Pack 1 (Build 7601)
2017-04-13 10:41 CET
Comment 9 Sergiusz Golec 2017-04-21 18:11:16 UTC
Created attachment 86033 [details]
Bug overview in one image

As a summary of my "big" post above: I could reproduce the issue.

Severity - Medium:
The severity of the original core issue is rather medium. Because: 
* from one side - there is a simple workaround. Deleting extra character. Or pasting value into a different spot / place. And deleting unnecessary leftovers.
* from another side - it may lead user to use another Office and abandon OO at all. Because copy-paste is a "basic feature". And if the Office (Writer and Calc) cannot support it fully as a market standard - we may wonder, what else we can (not) do with it.

Speculation - Is it one bug or many? Writer and /or Calc?:
All extra findings / issues - may tie into 1 bigger issue - regarding "Copy-Paste" feature. It also may be a set of minor issues, features and settings. 
Or an issue with a Calc (and not a Writer), as when we paste Calc cell (or a table) into the Notepad++, we still observe extra "newline" (paragraph / End Of Line character).
I hope it's not by Design. Because this way we can insert one cell from Calc through Writer into Calc as an embedded Calc. Not as a copied cell. Calc app in a Calc app. That make no sense for me, at all.


Speculation about "What's Next":
F1 Help / Manual will not reflect the code ties behind the GUI. Therefore developer(s) help will be appreciated. Maybe on the edge of Writer and Calc cooperation expertise.
Because it's either 1 issue. Or many. In the Writer and /or Calc. 

Or it's inconsistent behaviour "by design".
Yet even if it is by design - I believe, it can still be improved. 
And /or aligned to the market. Because similar software on the market. Alike Google Docs or MS Office, do not paste cell (or a table) as an embedded Software with copy-paste. With an extra new line. 
(It's as if an altered market standard, where everywhere F1 key triggers help manual, but in a "blah-blah" app - it's a search functionality, by default.)

Developers feedback will be much appreciated.