View Issue Details

IDProjectCategoryView StatusLast Update
0034832LazarusWidgetsetpublic2019-05-17 23:40
ReporterZoë Peterson Assigned ToDmitry Boyarintsev  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version2.0RC3 
Summary0034832: [Patch] Pasting clipboard text from other applications doesn't work
DescriptionThere's a typo in cocoawsclipboards.pas that means that "Clipboard.HasFormat(CF_TEXT)" doesn't work. Copying/pasting within an LCL application works, but if you copy text in an external application, it won't be supported correctly.
Steps To Reproduce1) Create a new LCL Cocoa application.
2) Add an OnCreate with the line
   Caption := BoolToStr(Clipboard.HasFormat(CF_TEXT), True);
3) Copy plain text from another application, then run the LCL one. Without the patch the caption will say "False"
TagsNo tags attached.
Fixed in Revision60029
LazTarget-
WidgetsetCocoa
Attached Files

Activities

Zoë Peterson

2019-01-07 23:27

reporter  

cocoawsclipboard.pas.patch (441 bytes)   
Index: cocoawsclipboard.pas
===================================================================
--- cocoawsclipboard.pas	(revision 60027)
+++ cocoawsclipboard.pas	(working copy)
@@ -431,7 +431,7 @@
 begin
   // "default" types must be mapped to a default LCL mime-type
   if AType.isEqualToString(_NSPasteboardTypeString) then
-    Result := 'text/plan'
+    Result := 'text/plain'
   else
     Result := NSStringToString(AType);
 end;
cocoawsclipboard.pas.patch (441 bytes)   

Dmitry Boyarintsev

2019-01-08 04:19

developer   ~0113247

Last edited: 2019-01-08 07:06

View 2 revisions

Thank you, applied
please test and close if ok

Issue History

Date Modified Username Field Change
2019-01-07 23:27 Zoë Peterson New Issue
2019-01-07 23:27 Zoë Peterson File Added: cocoawsclipboard.pas.patch
2019-01-08 04:19 Dmitry Boyarintsev Fixed in Revision => 60029
2019-01-08 04:19 Dmitry Boyarintsev LazTarget => -
2019-01-08 04:19 Dmitry Boyarintsev Note Added: 0113247
2019-01-08 04:19 Dmitry Boyarintsev Status new => resolved
2019-01-08 04:19 Dmitry Boyarintsev Resolution open => fixed
2019-01-08 04:19 Dmitry Boyarintsev Assigned To => Dmitry Boyarintsev
2019-01-08 07:06 Dmitry Boyarintsev Note Edited: 0113247 View Revisions
2019-05-17 23:40 Zoë Peterson Status resolved => closed