summaryrefslogtreecommitdiff
path: root/fpcsrc/packages/palmunits/src/clipboard.pp
blob: f260b988343a975206bc3ae3385a4e5116221748 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
{$MACRO ON}

(******************************************************************************
 *
 * Copyright (c) 1994-2000 Palm, Inc. or its subsidiaries.
 * All rights reserved.
 *
 * File: clipBoard.h
 *
 * Release: Palm OS SDK 4.0 (63220)
 *
 * Description:
 *   This file defines clipboard structures and routines.
 *
 * History:
 *    September 1, 1994 Created by Art Lamb
 *
 *****************************************************************************)

unit clipboard;

interface

uses  palmos, coretraps;

const
  numClipboardForamts = 3;
  numClipboardFormats = numClipboardForamts;
  cbdMaxTextLength = 1000;

// Clipboard standard formats
type
  clipboardFormats = Enum;

const
  clipboardText = 0;
  clipboardInk = Succ(clipboardText);
  clipboardBitmap = Succ(clipboardInk);

type
  ClipboardFormatType = clipboardFormats;

type
  ClipboardItem = record
{$ifdef ALLOW_ACCESS_TO_INTERNALS_OF_CLIPBOARDS} // These fields will not be available in the next OS release!
    item: MemHandle;
    length: UInt16;
{$endif}
  end;
  ClipboardItemTag = ClipboardItem;

//----------------------------------------------------------
// Clipboard Functions
//----------------------------------------------------------

procedure ClipboardAddItem(const format: ClipboardFormatType; const ptr: Pointer; length: UInt16); syscall sysTrapClipboardAddItem;

function ClipboardAppendItem(const format: ClipboardFormatType; const ptr: Pointer; length: UInt16): Err; syscall sysTrapClipboardAppendItem;

function ClipboardGetItem(const format: ClipboardFormatType; var length: UInt16): MemHandle; syscall sysTrapClipboardGetItem;

implementation

end.