From: Leo Davidson on 30 Jan 2010 18:26 On Jan 30, 10:22 pm, Colin Peters <cpet...(a)coldmail.com> wrote: > Indeed, the procedure can be complex. But who holds on to the data in > between? You can copy from notepad, close notepad then start another app > and paste. So the clipboard contents are persisted system wide. This is > what I want to find out about. Apps that set the clipboard can either copy the data into shared memory, so that it's owned by the system and the app is free to exit, or they can just put a flag into the clipboard which effectively says "if anyone wants this data, call me back and I'll provide it." Apps which do the latter often have a user-configurable option to populate the clipboard with the actual data on exit, or clear the clipboard on exit. (Assuming it's still the same thing in the clipboard, of course.) The "call me back" method is obviously a lot more complex so it's usually only done when providing that data takes significant time/ memory and it's likely that the only thing requesting the data, if anyone at all, will be the same app that put it there (allowing it to short-circuit most of that work).
From: m on 1 Feb 2010 20:54 IIRC the interactions are complex and the semantics date back to the pre-NT shared memory & cooperative multi-tasking environment and are overlain with COM in many cases. For more details look at SetClipboardData in MSDN. There are several system defied formats, but applications frequently register other 'custom' formats using RegisterClipboadFormat. "Colin Peters" <cpeters(a)coldmail.com> wrote in message news:e3rAsqfoKHA.1544(a)TK2MSFTNGP02.phx.gbl... > Indeed, the procedure can be complex. But who holds on to the data in > between? You can copy from notepad, close notepad then start another app > and paste. So the clipboard contents are persisted system wide. This is > what I want to find out about. > > > Pavel A. wrote: >> Some apps handle copy&paste in quite non trivial ways. >> >> Example: copy from IE and paste into OneNote and notepad. >> Notepad instantly pastes the plain text. >> By contrast, onenote takes a *lot* of time to complete the paste, it >> apparently talks to the browser. >> --pa >> >> "Colin Peters" <cpeters(a)coldmail.com> wrote in message >> news:eP5u$SeoKHA.4648(a)TK2MSFTNGP06.phx.gbl... >> >>> Jonathan de Boyne Pollard wrote: >>> >>>>> >>>>> >>>>> Can someone recommend any documentation that explains what process is >>>>> responsible for administering the clipboard. >>>>> >>>> Possibly. Given that you use the singular "process", what that >>>> documentation will tell you won't be what you're expecting. (-: >>>> >>> >>> Well, what I was after was some kind of description about what happens >>> when you call the API to put something on or off the clipboard. I assume >>> there's some mechanism at play to ensure that when two processes try to >>> copy at the same time (because the amount of data is large) that they >>> are somehow coordinated. Its really this kind of detail I'm after. >>> >>> I'm not even sure I'm on the right newsgroup. >> >>
From: Pavel A. on 1 Feb 2010 21:01 Another interesting example: Copy a large file from a VMware virtual machine, and paste it on the host (or v.v.). Obviously, it won't be copied via the clipboard. --pa "m" <m(a)b.c> wrote in message news:O5fliq6oKHA.5696(a)TK2MSFTNGP04.phx.gbl... > IIRC the interactions are complex and the semantics date back to the > pre-NT shared memory & cooperative multi-tasking environment and are > overlain with COM in many cases. For more details look at > SetClipboardData in MSDN. There are several system defied formats, but > applications frequently register other 'custom' formats using > RegisterClipboadFormat. > > > "Colin Peters" <cpeters(a)coldmail.com> wrote in message > news:e3rAsqfoKHA.1544(a)TK2MSFTNGP02.phx.gbl... >> Indeed, the procedure can be complex. But who holds on to the data in >> between? You can copy from notepad, close notepad then start another app >> and paste. So the clipboard contents are persisted system wide. This is >> what I want to find out about. >> >> >> Pavel A. wrote: >>> Some apps handle copy&paste in quite non trivial ways. >>> >>> Example: copy from IE and paste into OneNote and notepad. >>> Notepad instantly pastes the plain text. >>> By contrast, onenote takes a *lot* of time to complete the paste, it >>> apparently talks to the browser. >>> --pa >>> >>> "Colin Peters" <cpeters(a)coldmail.com> wrote in message >>> news:eP5u$SeoKHA.4648(a)TK2MSFTNGP06.phx.gbl... >>> >>>> Jonathan de Boyne Pollard wrote: >>>> >>>>>> >>>>>> >>>>>> Can someone recommend any documentation that explains what process is >>>>>> responsible for administering the clipboard. >>>>>> >>>>> Possibly. Given that you use the singular "process", what that >>>>> documentation will tell you won't be what you're expecting. (-: >>>>> >>>> >>>> Well, what I was after was some kind of description about what happens >>>> when you call the API to put something on or off the clipboard. I >>>> assume there's some mechanism at play to ensure that when two processes >>>> try to copy at the same time (because the amount of data is large) that >>>> they are somehow coordinated. Its really this kind of detail I'm after. >>>> >>>> I'm not even sure I'm on the right newsgroup. >>> >>>
First
|
Prev
|
Pages: 1 2 Prev: Code and Creation 73155 Next: Where can I find the CodeView specification |