You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openoffice.apache.org by bu...@apache.org on 2019/08/06 09:23:50 UTC

[Issue 128168] New: Pasting Cliboard content into Text box

https://bz.apache.org/ooo/show_bug.cgi?id=128168

          Issue ID: 128168
        Issue Type: DEFECT
           Summary: Pasting Cliboard content into Text box
           Product: General
           Version: 4.1.6
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P5 (lowest)
         Component: ui
          Assignee: issues@openoffice.apache.org
          Reporter: czeslaw.wolanski@gmail.com
  Target Milestone: ---

Operating system: Windows 7 Home Premium 64 bit
Apache OpenOffice 4.1.6

1. SITUATION:
 - macro executing simple Dialog - only Text Box
(com.sun.star.awt.UnoControlEdit)
 - value of Model.MaxTextLen set
 - current length of text equals MaxTextLen
 - OVERWRITE mode is on
 - cursor at any position


2. PROBLEM:   
Pasting content of Clipboard <Ctrl-V> results in:
 - OpenOffice displaying message about cutting text (OK)
 - removing character at cursor position ?????


3. EXAMPLES:

  Edit Control, MaxTexLen = 5, current text = 12345
  Clipboard content = ab
  * - marks cursor position


                *
before pasting  12345

                *
after pasting   2345



                 *  
before pasting 12345

                 *
after pasting  1245

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

oooforum (fr) <oo...@free.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |NOT_AN_OOO_ISSUE
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #4 from oooforum (fr) <oo...@free.fr> ---
Well, this message occurs certainly because you have not only "ab" in
Clipboard.
Select "ab" in a cell and you will have "ab" and a carriage return. 
So more than 2 chars.

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Cliboard content into Text box

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

oooforum (fr) <oo...@free.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |oooforum@free.fr

--- Comment #1 from oooforum (fr) <oo...@free.fr> ---
Save our time and provide the document

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

--- Comment #5 from czeslaw.wolanski@gmail.com ---
(In reply to oooforum (fr) from comment #4)
> Well, this message occurs certainly because you have not only "ab" in
> Clipboard.
> Select "ab" in a cell and you will have "ab" and a carriage return. 
> So more than 2 chars.

I see that "Issue 128168 - Pasting Clipboard content into Text field" has now
gained status "RESOLVED NOT_AN_OOO_ISSUE"
Excuse my stubbornness - but am I missing something? If that's the case, would
someone care to enlighten me on Clipboard and text/string handling philosophy
in OpenOffice.

Please read the following and then - if you find it advisable - reply. I shall
truly appreciate it.

1. Issue i.e. MISSING CHARACTER in OVERWRITE mode does not occur when:
   - lenght of text is not equal to MaxTexLen (text is shorter than limit)
   - block is marked (blue background) - one character or more

2. Before I decided to report this "would-be bug" I checked pasting 
   Clipboard content set in:
   - Notepad++ 
     (Menu > View > Show End of Line). Clearly I copied to Clipboard only 
     characters, not characters and CR/LF. NotePad++ allows to copy line 
     with CR/LF too.

   - OpenOffice
     I tested many cases:
      (i) copy cell,
      (ii) copy cell content (as you described in your comment),
      (iii) copy part of a cell content

Your remark << Select "ab" in a cell and you will have "ab" and a carriage
return>>  is perfectly correct yet if generalized has strange onsequencies. If
the cell content is, say "xxabyy", and I mark part of it - for example "ab" -
and copy it, then OpenOffice copies "ab" and adds carriage return. (see (iii)
above - after Paste operation one character vanished).
If I paste "ab" into the OpenOffice Writer actually new line appears.
If I paste same "ab" into Notepad++, new line does not appear (spooky, isn't
it? Or at least proves inconsistency)
Part of cell content should be string as it is not string with carriage return
(unless explicitly stated or predefined - like in Basic: Chr(13) & Chr(10) or
"MultiLine" property in UNO), no matter what I intend to do with: copy to
Clipboard, copy to another cell and so one.


3. Even if a carriage return is added (as in case of barcode scanner adding 
   CR/LF/Return or Enter key to barcode for efficiency), why one character      
   after paste operation is MISSING? (see point 1.). One would argue that 
   when lenght of text reaches MaxTextLen and pasting occurs:
   - in INSERT mode text remains unchanged
   - in OVERWRITE mode - text shall be shortened - really? (again: what 
   about missing character and cases mentionned in point 1. above)

Hence my humble request at the beginning.

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

Marcus <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |CLOSED

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

--- Comment #2 from czeslaw.wolanski@gmail.com ---
Created attachment 86720
  --> https://bz.apache.org/ooo/attachment.cgi?id=86720&action=edit
pasting two character string into text field in Overwrite mode

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

--- Comment #3 from czeslaw.wolanski@gmail.com ---
Created attachment 86721
  --> https://bz.apache.org/ooo/attachment.cgi?id=86721&action=edit
Calc file with macro - Dialog with text field

run macro ---> Library PasteTEST, Module1, subroutine Main

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

czeslaw.wolanski@gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Pasting Cliboard content    |Pasting Clipboard content
                   |into Text box               |into Text field

-- 
You are receiving this mail because:
You are the assignee for the issue.

[Issue 128168] Pasting Clipboard content into Text field

Posted by bu...@apache.org.
https://bz.apache.org/ooo/show_bug.cgi?id=128168

--- Comment #6 from czeslaw.wolanski@gmail.com ---
(In reply to oooforum (fr) from comment #4)
> Well, this message occurs certainly because you have not only "ab" in
> Clipboard.
> Select "ab" in a cell and you will have "ab" and a carriage return. 
> So more than 2 chars.

ADDENDUM to Comment #5 (reply to Comment #4)

Seems if have found another clear inconsistency in above explanation, this time
solely within OpenOffice.
If, as stated above, OpenOffice adds a carriage return to string copied from a
cell, then why when Clipboard content is pasted into another cell, new line
does not appear - please compare this with pasting Clipboard content into
OpenOffice Writer (new line does appear). Is therefore a carriage return in
effect as a general rule or is handled on case-by-case basis?

Please note in this context that pressing OK when cell is in Edit mode
results in moving cursor cell into adjacent cell.

Pasting string with added carriage return merely changes cell content.

-- 
You are receiving this mail because:
You are the assignee for the issue.