[Vm-dev] ExtendedClipboardInterface and ClipboardExtendedPlugin state?
Juan Vuletich
JuanVuletich at zoho.com
Tue Jan 4 19:53:53 UTC 2022
On 1/4/2022 3:26 PM, Vanessa Freudenberg wrote:
>
>
>
> On Tue, Jan 4, 2022 at 8:14 AM Eliot Miranda <eliot.miranda at gmail.com
> <mailto:eliot.miranda at gmail.com>> wrote:
>
> Hi Vanessa,
>
>> On Jan 3, 2022, at 1:03 PM, Vanessa Freudenberg
>> <vanessa at codefrau.net <mailto:vanessa at codefrau.net>> wrote:
>>
>>
>> In the OLPC days this plugin enabled copy/paste of objects,
>> pictures. and rich text on all platforms (Mac/Win/X11).
>>
>> E.g. you could copy/paste a morph from one image to another
>> simply by bringing up its halo, pressing cmd-c, and pressing
>> cmd-v in the other image. All its scripted behavior (Etoys
>> scripts) would be transferred with it. If instead you pasted that
>> morph into a word processor, it would insert a bitmap rendering
>> of the morph.
>>
>> Similarly you could copy a picture from a web browser and paste
>> it directly into Squeak. Or copy syntax-highlighted source code
>> from Squeak into an email.
>>
>> I'm not entirely sure how much of the machinery made into Squeak
>> trunk, but I would guess it's almost all there, might just need
>> some wiring to hook up properly.
>
> The basic image classes are there. But only the Mac vm support
> machinery made it. There is no
> platforms/unix/plugins/ClipboardExtendedPlugin
> or platforms/win32/plugins/ClipboardExtendedPlugin that I can
> find. Where or who can we reach out to to try and locate this code?
>
>
> The unix plugin is in the interpreter sources:
>
> http://squeakvm.org/cgi-bin/viewvc.cgi/squeak/trunk/platforms/unix/plugins/ClipboardExtendedPlugin/sqUnixExtendedClipboard.c?view=markup
>
> with the X11 support code in the display plugin:
>
> http://squeakvm.org/cgi-bin/viewvc.cgi/squeak/trunk/platforms/unix/vm-display-X11/sqUnixX11.c?revision=3796&view=markup#l2465
> <http://squeakvm.org/cgi-bin/viewvc.cgi/squeak/trunk/platforms/unix/vm-display-X11/sqUnixX11.c?revision=3796&view=markup#l2465>
>
> I don't see the equivalent in win32, possibly I was misremembering
> that it worked on all three platforms (I only ever use Mac and *nix).
>
> Vanessa
I believe I took related code from Sophie. In Cuis you can copy / paste
various things between images and external programs as Vanessa says.
Haven't used it in a long time, though.
The Windows support calls stuff in user32.dll via ffi, i.e. no plugin.
It doesn't support writing to clipboard. I believe Mac and Linux support
is more complete.
>>
>> Vanessa
>>
>> On Fri, Dec 31, 2021 at 5:07 PM Eliot Miranda
>> <eliot.miranda at gmail.com <mailto:eliot.miranda at gmail.com>> wrote:
>>
>> Hi Bernhard,
>>
>> On Fri, Dec 31, 2021 at 5:27 AM Bernhard Pieber
>> <bernhard at pieber.com <mailto:bernhard at pieber.com>> wrote:
>>
>>
>> Hi,
>>
>> Maybe this question is better asked on the vm-dev list.
>> Does anyone know the status of the ClipboardExtendedPlugin?
>>
>> Happy New Year!
>>
>> Bernhard
>>
>> > Am 20.12.2021 um 09:38 schrieb Bernhard Pieber
>> <bernhard at pieber.com <mailto:bernhard at pieber.com>>:
>> >
>> > Hi everyone,
>> >
>> > I tried to copy a form as PNG to the clipboard like this:
>> > ExtendedClipboardInterface current
>> addClipboardDataConvertFormToPNG: self imageForm
>>
>>
>> With fixes to the plugin ClipboardExtendedPlugin.c generated
>> C file to declare the interface it uses, and the Makefile to
>> compile it, I am able to copy and paste the display into
>> TextEdit on macOS 10.14. I'll commit fixes to the
>> opensmalltalk-vm repository, and add the plugin to Squeak
>> macOS builds. Thanks for the heads up :-)
>>
>> >
>> > This seems not to work correctly. If I paste it to
>> TextEdit I get the binary data starting with PNG instead
>> of the image itself. It looks as if the
>> ClipboardExtendedPlugin is not loaded. The plugin seems
>> to be in the current VM source
>> (src/pugins/ClipboardExtendedPlugin), though. I am on
>> macOS Big Sur 11.6.1.
>> >
>> > Should this work? I tried on Squeak 3.4, 4.6 and 5.3 but
>> the ExtendedClipboardInterface is not loaded in these images.
>> >
>> > Cheers,
>> > Bernhard
>>
>>
>>
>>
>> --
>> _,,,^..^,,,_
>> best, Eliot
>>
--
Juan Vuletich
www.cuis-smalltalk.org
https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev
https://github.com/jvuletich
https://www.researchgate.net/profile/Juan-Vuletich
https://www.linkedin.com/in/juan-vuletich-75611b3
https://independent.academia.edu/JuanVuletich
@JuanVuletich
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20220104/d09b105d/attachment-0001.html>
More information about the Vm-dev
mailing list