windows-pr 1.2.2 → 1.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CHANGES +444 -438
- data/MANIFEST +68 -65
- data/README +154 -153
- data/Rakefile +42 -37
- data/doc/conversion_guide.txt +37 -37
- data/lib/windows/clipboard.rb +61 -61
- data/lib/windows/com.rb +192 -192
- data/lib/windows/com/accessibility.rb +16 -16
- data/lib/windows/com/automation.rb +149 -149
- data/lib/windows/com/variant.rb +24 -24
- data/lib/windows/console.rb +114 -114
- data/lib/windows/debug.rb +35 -35
- data/lib/windows/device_io.rb +248 -248
- data/lib/windows/directory.rb +27 -27
- data/lib/windows/error.rb +504 -498
- data/lib/windows/eventlog.rb +80 -80
- data/lib/windows/file.rb +264 -264
- data/lib/windows/file_mapping.rb +25 -25
- data/lib/windows/filesystem.rb +15 -15
- data/lib/windows/gdi/bitmap.rb +65 -65
- data/lib/windows/gdi/device_context.rb +46 -46
- data/lib/windows/gdi/metafile.rb +40 -40
- data/lib/windows/gdi/painting_drawing.rb +115 -115
- data/lib/windows/handle.rb +23 -23
- data/lib/windows/library.rb +44 -44
- data/lib/windows/limits.rb +34 -34
- data/lib/windows/mailslot.rb +24 -24
- data/lib/windows/memory.rb +128 -128
- data/lib/windows/msvcrt/buffer.rb +75 -75
- data/lib/windows/msvcrt/directory.rb +31 -31
- data/lib/windows/msvcrt/file.rb +47 -47
- data/lib/windows/msvcrt/io.rb +73 -73
- data/lib/windows/msvcrt/string.rb +182 -182
- data/lib/windows/msvcrt/time.rb +169 -169
- data/lib/windows/national.rb +580 -580
- data/lib/windows/network/management.rb +525 -525
- data/lib/windows/network/snmp.rb +92 -92
- data/lib/windows/network/winsock.rb +128 -128
- data/lib/windows/nio.rb +50 -50
- data/lib/windows/ntfs/winternl.rb +117 -117
- data/lib/windows/path.rb +143 -143
- data/lib/windows/pipe.rb +42 -42
- data/lib/windows/process.rb +176 -176
- data/lib/windows/registry.rb +171 -171
- data/lib/windows/security.rb +479 -479
- data/lib/windows/security/authentication.rb +32 -32
- data/lib/windows/security/sspi.rb +153 -0
- data/lib/windows/service.rb +142 -142
- data/lib/windows/shell.rb +171 -171
- data/lib/windows/socket.rb +86 -86
- data/lib/windows/sound.rb +39 -39
- data/lib/windows/synchronize.rb +133 -133
- data/lib/windows/system_info.rb +229 -229
- data/lib/windows/thread.rb +64 -64
- data/lib/windows/time.rb +48 -48
- data/lib/windows/tool_helper.rb +36 -36
- data/lib/windows/unicode.rb +155 -155
- data/lib/windows/volume.rb +61 -61
- data/lib/windows/window.rb +81 -81
- data/lib/windows/window/classes.rb +59 -59
- data/lib/windows/window/dialog.rb +91 -91
- data/lib/windows/window/menu.rb +102 -102
- data/lib/windows/window/message.rb +297 -297
- data/lib/windows/window/properties.rb +20 -20
- data/lib/windows/window/timer.rb +19 -19
- data/lib/windows/wsa.rb +102 -102
- data/test/tc_clipboard.rb +41 -41
- data/test/tc_com.rb +32 -32
- data/test/tc_com_automation.rb +15 -15
- data/test/tc_console.rb +108 -108
- data/test/tc_debug.rb +48 -48
- data/test/tc_device_io.rb +29 -29
- data/test/tc_directory.rb +25 -25
- data/test/tc_error.rb +38 -38
- data/test/tc_eventlog.rb +58 -58
- data/test/tc_file.rb +67 -67
- data/test/tc_file_mapping.rb +38 -38
- data/test/tc_filesystem.rb +27 -27
- data/test/tc_gdi_bitmap.rb +25 -25
- data/test/tc_gdi_metafile.rb +23 -23
- data/test/tc_handle.rb +36 -36
- data/test/tc_library.rb +37 -37
- data/test/tc_limits.rb +34 -34
- data/test/tc_mailslot.rb +22 -22
- data/test/tc_memory.rb +44 -44
- data/test/tc_msvcrt_buffer.rb +63 -63
- data/test/tc_msvcrt_directory.rb +96 -96
- data/test/tc_msvcrt_file.rb +80 -80
- data/test/tc_msvcrt_io.rb +48 -48
- data/test/tc_msvcrt_string.rb +94 -94
- data/test/tc_msvcrt_time.rb +19 -19
- data/test/tc_national.rb +38 -38
- data/test/tc_network_management.rb +32 -32
- data/test/tc_network_snmp.rb +31 -31
- data/test/tc_network_winsock.rb +34 -34
- data/test/tc_nio.rb +32 -32
- data/test/tc_ntfs_winternl.rb +48 -48
- data/test/tc_path.rb +90 -90
- data/test/tc_pipe.rb +53 -53
- data/test/tc_process.rb +24 -24
- data/test/tc_registry.rb +29 -29
- data/test/tc_security.rb +104 -104
- data/test/tc_security_authentication.rb +34 -34
- data/test/tc_security_sspi.rb +23 -0
- data/test/tc_service.rb +57 -57
- data/test/tc_shell.rb +34 -34
- data/test/tc_socket.rb +20 -20
- data/test/tc_sound.rb +37 -37
- data/test/tc_synchronize.rb +75 -75
- data/test/tc_system_info.rb +33 -33
- data/test/tc_thread.rb +29 -29
- data/test/tc_time.rb +32 -32
- data/test/tc_tool_helper.rb +29 -29
- data/test/tc_unicode.rb +83 -83
- data/test/tc_volume.rb +47 -47
- data/test/tc_window.rb +45 -45
- data/test/tc_window_classes.rb +33 -33
- data/test/tc_window_dialog.rb +33 -33
- data/test/tc_window_menu.rb +29 -29
- data/test/tc_window_message.rb +33 -33
- data/test/tc_window_properties.rb +29 -29
- data/test/tc_window_timer.rb +29 -29
- data/test/tc_wsa.rb +19 -19
- data/windows-pr.gemspec +33 -34
- metadata +31 -32
data/lib/windows/file_mapping.rb
CHANGED
@@ -1,25 +1,25 @@
|
|
1
|
-
require 'windows/api'
|
2
|
-
|
3
|
-
module Windows
|
4
|
-
module FileMapping
|
5
|
-
API.auto_namespace = 'Windows::FileMapping'
|
6
|
-
API.auto_constant = true
|
7
|
-
API.auto_method = true
|
8
|
-
API.auto_unicode = true
|
9
|
-
|
10
|
-
private
|
11
|
-
|
12
|
-
FILE_MAP_COPY = 0x0001
|
13
|
-
FILE_MAP_WRITE = 0x0002
|
14
|
-
FILE_MAP_READ = 0x0004
|
15
|
-
FILE_MAP_ALL_ACCESS = 983071
|
16
|
-
|
17
|
-
API.new('CreateFileMapping', 'LPLLLP', 'L')
|
18
|
-
API.new('FlushViewOfFile', 'PL', 'B')
|
19
|
-
API.new('GetMappedFileName', 'LLPL', 'L', 'psapi')
|
20
|
-
API.new('MapViewOfFile', 'LLLLL', 'L')
|
21
|
-
API.new('MapViewOfFileEx', 'LLLLLL', 'L')
|
22
|
-
API.new('OpenFileMapping', 'LIP', 'L')
|
23
|
-
API.new('UnmapViewOfFile', 'P', 'B')
|
24
|
-
end
|
25
|
-
end
|
1
|
+
require 'windows/api'
|
2
|
+
|
3
|
+
module Windows
|
4
|
+
module FileMapping
|
5
|
+
API.auto_namespace = 'Windows::FileMapping'
|
6
|
+
API.auto_constant = true
|
7
|
+
API.auto_method = true
|
8
|
+
API.auto_unicode = true
|
9
|
+
|
10
|
+
private
|
11
|
+
|
12
|
+
FILE_MAP_COPY = 0x0001
|
13
|
+
FILE_MAP_WRITE = 0x0002
|
14
|
+
FILE_MAP_READ = 0x0004
|
15
|
+
FILE_MAP_ALL_ACCESS = 983071
|
16
|
+
|
17
|
+
API.new('CreateFileMapping', 'LPLLLP', 'L')
|
18
|
+
API.new('FlushViewOfFile', 'PL', 'B')
|
19
|
+
API.new('GetMappedFileName', 'LLPL', 'L', 'psapi')
|
20
|
+
API.new('MapViewOfFile', 'LLLLL', 'L')
|
21
|
+
API.new('MapViewOfFileEx', 'LLLLLL', 'L')
|
22
|
+
API.new('OpenFileMapping', 'LIP', 'L')
|
23
|
+
API.new('UnmapViewOfFile', 'P', 'B')
|
24
|
+
end
|
25
|
+
end
|
data/lib/windows/filesystem.rb
CHANGED
@@ -1,15 +1,15 @@
|
|
1
|
-
require 'windows/api'
|
2
|
-
|
3
|
-
module Windows
|
4
|
-
module FileSystem
|
5
|
-
API.auto_namespace = 'Windows::FileSystem'
|
6
|
-
API.auto_constant = true
|
7
|
-
API.auto_method = true
|
8
|
-
API.auto_unicode = true
|
9
|
-
|
10
|
-
private
|
11
|
-
|
12
|
-
API.new('GetDiskFreeSpace', 'SPPPP', 'B')
|
13
|
-
API.new('GetDiskFreeSpaceEx', 'SPPP', 'B')
|
14
|
-
end
|
15
|
-
end
|
1
|
+
require 'windows/api'
|
2
|
+
|
3
|
+
module Windows
|
4
|
+
module FileSystem
|
5
|
+
API.auto_namespace = 'Windows::FileSystem'
|
6
|
+
API.auto_constant = true
|
7
|
+
API.auto_method = true
|
8
|
+
API.auto_unicode = true
|
9
|
+
|
10
|
+
private
|
11
|
+
|
12
|
+
API.new('GetDiskFreeSpace', 'SPPPP', 'B')
|
13
|
+
API.new('GetDiskFreeSpaceEx', 'SPPP', 'B')
|
14
|
+
end
|
15
|
+
end
|
data/lib/windows/gdi/bitmap.rb
CHANGED
@@ -1,65 +1,65 @@
|
|
1
|
-
require 'windows/api'
|
2
|
-
|
3
|
-
module Windows
|
4
|
-
module GDI
|
5
|
-
module Bitmap
|
6
|
-
API.auto_namespace = 'Windows::GDI::Bitmap'
|
7
|
-
API.auto_constant = true
|
8
|
-
API.auto_method = true
|
9
|
-
API.auto_unicode = true
|
10
|
-
|
11
|
-
private
|
12
|
-
|
13
|
-
DIB_RGB_COLORS = 0
|
14
|
-
DIB_PAL_COLORS = 1
|
15
|
-
|
16
|
-
# Raster operations
|
17
|
-
SRCCOPY = 0x00CC0020
|
18
|
-
SRCPAINT = 0x00EE0086
|
19
|
-
SRCAND = 0x008800C6
|
20
|
-
SRCINVERT = 0x00660046
|
21
|
-
SRCERASE = 0x00440328
|
22
|
-
NOTSRCCOPY = 0x00330008
|
23
|
-
NOTSRCERASE = 0x001100A6
|
24
|
-
MERGECOPY = 0x00C000CA
|
25
|
-
MERGEPAINT = 0x00BB0226
|
26
|
-
PATCOPY = 0x00F00021
|
27
|
-
PATPAINT = 0x00FB0A09
|
28
|
-
PATINVERT = 0x005A0049
|
29
|
-
STINVERT = 0x00550009
|
30
|
-
BLACKNESS = 0x00000042
|
31
|
-
WHITENESS = 0x00FF0062
|
32
|
-
|
33
|
-
API.new('AlphaBlend', 'LIIIILIIIIL', 'B', 'msimg32')
|
34
|
-
API.new('BitBlt', 'LIIIILIIL', 'B', 'gdi32')
|
35
|
-
API.new('CreateBitmap', 'IILLP', 'L', 'gdi32')
|
36
|
-
API.new('CreateBitmapIndirect', 'P', 'L', 'gdi32')
|
37
|
-
API.new('CreateCompatibleBitmap', 'LII', 'L', 'gdi32')
|
38
|
-
API.new('CreateDIBitmap', 'LLLPPL', 'L', 'gdi32')
|
39
|
-
API.new('CreateDIBSection', 'LPLPLL', 'L', 'gdi32')
|
40
|
-
API.new('CreateDiscardableBitmap', 'LII', 'L', 'gdi32')
|
41
|
-
API.new('ExtFloodFill', 'LIILL', 'B', 'gdi32')
|
42
|
-
API.new('FloodFill', 'LIIL', 'B', 'gdi32')
|
43
|
-
API.new('GetBitmapDimensionEx', 'LP', 'B', 'gdi32')
|
44
|
-
API.new('GetDIBColorTable', 'LLLP', 'L', 'gdi32')
|
45
|
-
API.new('GetDIBits', 'LLIIPPI', 'I', 'gdi32')
|
46
|
-
API.new('GetPixel', 'LII', 'L', 'gdi32')
|
47
|
-
API.new('GetStretchBltMode', 'L', 'I', 'gdi32')
|
48
|
-
API.new('GradientFill', 'LLLLLL', 'B', 'msimg32')
|
49
|
-
API.new('LoadBitmap', 'LP', 'L', 'user32')
|
50
|
-
API.new('MaskBlt', 'LIIIILIILIIL', 'B', 'gdi32')
|
51
|
-
API.new('PlgBlt', 'LPLIIIILII', 'B', 'gdi32')
|
52
|
-
API.new('SetBitmapBits', 'LLP', 'L', 'gdi32')
|
53
|
-
API.new('SetBitmapDimensionEx', 'LIIP', 'L', 'gdi32')
|
54
|
-
API.new('SetDIBColorTable', 'LLLP', 'L', 'gdi32')
|
55
|
-
API.new('SetDIBits', 'LLLLPPL', 'I', 'gdi32')
|
56
|
-
API.new('SetDIBitsToDevice', 'LIILLIILLPPL', 'I', 'gdi32')
|
57
|
-
API.new('SetPixel', 'LIIL', 'L', 'gdi32')
|
58
|
-
API.new('SetPixelV', 'LIIL', 'B', 'gdi32')
|
59
|
-
API.new('SetStretchBltMode', 'LI', 'I', 'gdi32')
|
60
|
-
API.new('StretchBlt', 'LIIIILIIIIL', 'B', 'gdi32')
|
61
|
-
API.new('StretchDIBits', 'LIIIIIIIIPPLL', 'I', 'gdi32')
|
62
|
-
API.new('TransparentBlt', 'LIIIILIIIIL', 'B', 'msimg32')
|
63
|
-
end
|
64
|
-
end
|
65
|
-
end
|
1
|
+
require 'windows/api'
|
2
|
+
|
3
|
+
module Windows
|
4
|
+
module GDI
|
5
|
+
module Bitmap
|
6
|
+
API.auto_namespace = 'Windows::GDI::Bitmap'
|
7
|
+
API.auto_constant = true
|
8
|
+
API.auto_method = true
|
9
|
+
API.auto_unicode = true
|
10
|
+
|
11
|
+
private
|
12
|
+
|
13
|
+
DIB_RGB_COLORS = 0
|
14
|
+
DIB_PAL_COLORS = 1
|
15
|
+
|
16
|
+
# Raster operations
|
17
|
+
SRCCOPY = 0x00CC0020
|
18
|
+
SRCPAINT = 0x00EE0086
|
19
|
+
SRCAND = 0x008800C6
|
20
|
+
SRCINVERT = 0x00660046
|
21
|
+
SRCERASE = 0x00440328
|
22
|
+
NOTSRCCOPY = 0x00330008
|
23
|
+
NOTSRCERASE = 0x001100A6
|
24
|
+
MERGECOPY = 0x00C000CA
|
25
|
+
MERGEPAINT = 0x00BB0226
|
26
|
+
PATCOPY = 0x00F00021
|
27
|
+
PATPAINT = 0x00FB0A09
|
28
|
+
PATINVERT = 0x005A0049
|
29
|
+
STINVERT = 0x00550009
|
30
|
+
BLACKNESS = 0x00000042
|
31
|
+
WHITENESS = 0x00FF0062
|
32
|
+
|
33
|
+
API.new('AlphaBlend', 'LIIIILIIIIL', 'B', 'msimg32')
|
34
|
+
API.new('BitBlt', 'LIIIILIIL', 'B', 'gdi32')
|
35
|
+
API.new('CreateBitmap', 'IILLP', 'L', 'gdi32')
|
36
|
+
API.new('CreateBitmapIndirect', 'P', 'L', 'gdi32')
|
37
|
+
API.new('CreateCompatibleBitmap', 'LII', 'L', 'gdi32')
|
38
|
+
API.new('CreateDIBitmap', 'LLLPPL', 'L', 'gdi32')
|
39
|
+
API.new('CreateDIBSection', 'LPLPLL', 'L', 'gdi32')
|
40
|
+
API.new('CreateDiscardableBitmap', 'LII', 'L', 'gdi32')
|
41
|
+
API.new('ExtFloodFill', 'LIILL', 'B', 'gdi32')
|
42
|
+
API.new('FloodFill', 'LIIL', 'B', 'gdi32')
|
43
|
+
API.new('GetBitmapDimensionEx', 'LP', 'B', 'gdi32')
|
44
|
+
API.new('GetDIBColorTable', 'LLLP', 'L', 'gdi32')
|
45
|
+
API.new('GetDIBits', 'LLIIPPI', 'I', 'gdi32')
|
46
|
+
API.new('GetPixel', 'LII', 'L', 'gdi32')
|
47
|
+
API.new('GetStretchBltMode', 'L', 'I', 'gdi32')
|
48
|
+
API.new('GradientFill', 'LLLLLL', 'B', 'msimg32')
|
49
|
+
API.new('LoadBitmap', 'LP', 'L', 'user32')
|
50
|
+
API.new('MaskBlt', 'LIIIILIILIIL', 'B', 'gdi32')
|
51
|
+
API.new('PlgBlt', 'LPLIIIILII', 'B', 'gdi32')
|
52
|
+
API.new('SetBitmapBits', 'LLP', 'L', 'gdi32')
|
53
|
+
API.new('SetBitmapDimensionEx', 'LIIP', 'L', 'gdi32')
|
54
|
+
API.new('SetDIBColorTable', 'LLLP', 'L', 'gdi32')
|
55
|
+
API.new('SetDIBits', 'LLLLPPL', 'I', 'gdi32')
|
56
|
+
API.new('SetDIBitsToDevice', 'LIILLIILLPPL', 'I', 'gdi32')
|
57
|
+
API.new('SetPixel', 'LIIL', 'L', 'gdi32')
|
58
|
+
API.new('SetPixelV', 'LIIL', 'B', 'gdi32')
|
59
|
+
API.new('SetStretchBltMode', 'LI', 'I', 'gdi32')
|
60
|
+
API.new('StretchBlt', 'LIIIILIIIIL', 'B', 'gdi32')
|
61
|
+
API.new('StretchDIBits', 'LIIIIIIIIPPLL', 'I', 'gdi32')
|
62
|
+
API.new('TransparentBlt', 'LIIIILIIIIL', 'B', 'msimg32')
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
@@ -1,46 +1,46 @@
|
|
1
|
-
require 'windows/api'
|
2
|
-
|
3
|
-
module Windows
|
4
|
-
module GDI
|
5
|
-
module DeviceContext
|
6
|
-
API.auto_namespace = 'Windows::GDI::DeviceContext'
|
7
|
-
API.auto_constant = true
|
8
|
-
API.auto_method = true
|
9
|
-
API.auto_unicode = true
|
10
|
-
|
11
|
-
private
|
12
|
-
|
13
|
-
DRIVERVERSION = 0
|
14
|
-
TECHNOLOGY = 2
|
15
|
-
HORZSIZE = 4
|
16
|
-
VERTSIZE = 6
|
17
|
-
HORZRES = 8
|
18
|
-
VERTRES = 10
|
19
|
-
BITSPIXEL = 12
|
20
|
-
PLANES = 14
|
21
|
-
NUMBRUSHES = 16
|
22
|
-
NUMPENS = 18
|
23
|
-
NUMMARKERS = 20
|
24
|
-
NUMFONTS = 22
|
25
|
-
NUMCOLORS = 24
|
26
|
-
PDEVICESIZE = 26
|
27
|
-
CURVECAPS = 28
|
28
|
-
LINECAPS = 30
|
29
|
-
POLYGONALCAPS = 32
|
30
|
-
TEXTCAPS = 34
|
31
|
-
CLIPCAPS = 36
|
32
|
-
RASTERCAPS = 38
|
33
|
-
ASPECTX = 40
|
34
|
-
ASPECTY = 42
|
35
|
-
ASPECTXY = 44
|
36
|
-
|
37
|
-
API.new('CreateCompatibleDC', 'L', 'L', 'gdi32')
|
38
|
-
API.new('DeleteDC', 'L', 'B', 'gdi32')
|
39
|
-
API.new('DeleteObject', 'L', 'B', 'gdi32')
|
40
|
-
API.new('GetDC', 'L', 'L', 'user32')
|
41
|
-
API.new('GetDeviceCaps', 'LI', 'I', 'gdi32')
|
42
|
-
API.new('ReleaseDC', 'LL', 'I', 'user32')
|
43
|
-
API.new('SelectObject', 'LL', 'L', 'gdi32')
|
44
|
-
end
|
45
|
-
end
|
46
|
-
end
|
1
|
+
require 'windows/api'
|
2
|
+
|
3
|
+
module Windows
|
4
|
+
module GDI
|
5
|
+
module DeviceContext
|
6
|
+
API.auto_namespace = 'Windows::GDI::DeviceContext'
|
7
|
+
API.auto_constant = true
|
8
|
+
API.auto_method = true
|
9
|
+
API.auto_unicode = true
|
10
|
+
|
11
|
+
private
|
12
|
+
|
13
|
+
DRIVERVERSION = 0
|
14
|
+
TECHNOLOGY = 2
|
15
|
+
HORZSIZE = 4
|
16
|
+
VERTSIZE = 6
|
17
|
+
HORZRES = 8
|
18
|
+
VERTRES = 10
|
19
|
+
BITSPIXEL = 12
|
20
|
+
PLANES = 14
|
21
|
+
NUMBRUSHES = 16
|
22
|
+
NUMPENS = 18
|
23
|
+
NUMMARKERS = 20
|
24
|
+
NUMFONTS = 22
|
25
|
+
NUMCOLORS = 24
|
26
|
+
PDEVICESIZE = 26
|
27
|
+
CURVECAPS = 28
|
28
|
+
LINECAPS = 30
|
29
|
+
POLYGONALCAPS = 32
|
30
|
+
TEXTCAPS = 34
|
31
|
+
CLIPCAPS = 36
|
32
|
+
RASTERCAPS = 38
|
33
|
+
ASPECTX = 40
|
34
|
+
ASPECTY = 42
|
35
|
+
ASPECTXY = 44
|
36
|
+
|
37
|
+
API.new('CreateCompatibleDC', 'L', 'L', 'gdi32')
|
38
|
+
API.new('DeleteDC', 'L', 'B', 'gdi32')
|
39
|
+
API.new('DeleteObject', 'L', 'B', 'gdi32')
|
40
|
+
API.new('GetDC', 'L', 'L', 'user32')
|
41
|
+
API.new('GetDeviceCaps', 'LI', 'I', 'gdi32')
|
42
|
+
API.new('ReleaseDC', 'LL', 'I', 'user32')
|
43
|
+
API.new('SelectObject', 'LL', 'L', 'gdi32')
|
44
|
+
end
|
45
|
+
end
|
46
|
+
end
|
data/lib/windows/gdi/metafile.rb
CHANGED
@@ -1,40 +1,40 @@
|
|
1
|
-
require 'windows/api'
|
2
|
-
|
3
|
-
module Windows
|
4
|
-
module GDI
|
5
|
-
module MetaFile
|
6
|
-
API.auto_namespace = 'Windows::GDI::MetaFile'
|
7
|
-
API.auto_constant = true
|
8
|
-
API.auto_method = true
|
9
|
-
API.auto_unicode = true
|
10
|
-
|
11
|
-
private
|
12
|
-
|
13
|
-
API.new('CloseEnhMetaFile', 'L', 'L', 'gdi32')
|
14
|
-
API.new('CloseMetaFile', 'L', 'L', 'gdi32')
|
15
|
-
API.new('CopyEnhMetaFile', 'LS', 'L', 'gdi32')
|
16
|
-
API.new('CopyMetaFile', 'LS', 'L', 'gdi32')
|
17
|
-
API.new('CreateEnhMetaFile', 'LSPS', 'L', 'gdi32')
|
18
|
-
API.new('CreateMetaFile', 'S', 'L', 'gdi32')
|
19
|
-
API.new('DeleteEnhMetaFile', 'L', 'B', 'gdi32')
|
20
|
-
API.new('DeleteMetaFile', 'L', 'B', 'gdi32')
|
21
|
-
API.new('EnumEnhMetaFile', 'LLKKP', 'B', 'gdi32')
|
22
|
-
API.new('EnumMetaFile', 'LLKP', 'B', 'gdi32')
|
23
|
-
API.new('GdiComment', 'LLP', 'B', 'gdi32')
|
24
|
-
API.new('GetEnhMetaFile', 'S', 'L', 'gdi32')
|
25
|
-
API.new('GetEnhMetaFileBits', 'LLP', 'L', 'gdi32')
|
26
|
-
API.new('GetEnhMetaFileDescription', 'LLP', 'L', 'gdi32')
|
27
|
-
API.new('GetEnhMetaFileHeader', 'LLP', 'L', 'gdi32')
|
28
|
-
API.new('GetEnhMetaFilePaletteEntries', 'LLP', 'L', 'gdi32')
|
29
|
-
API.new('GetMetaFileBitsEx', 'LLP', 'L', 'gdi32')
|
30
|
-
API.new('GetWinMetaFileBits', 'LLPIL', 'L', 'gdi32')
|
31
|
-
API.new('PlayEnhMetaFile', 'LLP', 'L', 'gdi32')
|
32
|
-
API.new('PlayEnhMetaFileRecord', 'LLPL', 'L', 'gdi32')
|
33
|
-
API.new('PlayMetaFile', 'LL', 'B', 'gdi32')
|
34
|
-
API.new('PlayMetaFileRecord', 'LPPL', 'B', 'gdi32')
|
35
|
-
API.new('SetEnhMetaFileBits', 'LP', 'L', 'gdi32')
|
36
|
-
API.new('SetMetaFileBitsEx', 'LP', 'L', 'gdi32')
|
37
|
-
API.new('SetWinMetaFileBits', 'LPLP', 'L', 'gdi32')
|
38
|
-
end
|
39
|
-
end
|
40
|
-
end
|
1
|
+
require 'windows/api'
|
2
|
+
|
3
|
+
module Windows
|
4
|
+
module GDI
|
5
|
+
module MetaFile
|
6
|
+
API.auto_namespace = 'Windows::GDI::MetaFile'
|
7
|
+
API.auto_constant = true
|
8
|
+
API.auto_method = true
|
9
|
+
API.auto_unicode = true
|
10
|
+
|
11
|
+
private
|
12
|
+
|
13
|
+
API.new('CloseEnhMetaFile', 'L', 'L', 'gdi32')
|
14
|
+
API.new('CloseMetaFile', 'L', 'L', 'gdi32')
|
15
|
+
API.new('CopyEnhMetaFile', 'LS', 'L', 'gdi32')
|
16
|
+
API.new('CopyMetaFile', 'LS', 'L', 'gdi32')
|
17
|
+
API.new('CreateEnhMetaFile', 'LSPS', 'L', 'gdi32')
|
18
|
+
API.new('CreateMetaFile', 'S', 'L', 'gdi32')
|
19
|
+
API.new('DeleteEnhMetaFile', 'L', 'B', 'gdi32')
|
20
|
+
API.new('DeleteMetaFile', 'L', 'B', 'gdi32')
|
21
|
+
API.new('EnumEnhMetaFile', 'LLKKP', 'B', 'gdi32')
|
22
|
+
API.new('EnumMetaFile', 'LLKP', 'B', 'gdi32')
|
23
|
+
API.new('GdiComment', 'LLP', 'B', 'gdi32')
|
24
|
+
API.new('GetEnhMetaFile', 'S', 'L', 'gdi32')
|
25
|
+
API.new('GetEnhMetaFileBits', 'LLP', 'L', 'gdi32')
|
26
|
+
API.new('GetEnhMetaFileDescription', 'LLP', 'L', 'gdi32')
|
27
|
+
API.new('GetEnhMetaFileHeader', 'LLP', 'L', 'gdi32')
|
28
|
+
API.new('GetEnhMetaFilePaletteEntries', 'LLP', 'L', 'gdi32')
|
29
|
+
API.new('GetMetaFileBitsEx', 'LLP', 'L', 'gdi32')
|
30
|
+
API.new('GetWinMetaFileBits', 'LLPIL', 'L', 'gdi32')
|
31
|
+
API.new('PlayEnhMetaFile', 'LLP', 'L', 'gdi32')
|
32
|
+
API.new('PlayEnhMetaFileRecord', 'LLPL', 'L', 'gdi32')
|
33
|
+
API.new('PlayMetaFile', 'LL', 'B', 'gdi32')
|
34
|
+
API.new('PlayMetaFileRecord', 'LPPL', 'B', 'gdi32')
|
35
|
+
API.new('SetEnhMetaFileBits', 'LP', 'L', 'gdi32')
|
36
|
+
API.new('SetMetaFileBitsEx', 'LP', 'L', 'gdi32')
|
37
|
+
API.new('SetWinMetaFileBits', 'LPLP', 'L', 'gdi32')
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
@@ -1,115 +1,115 @@
|
|
1
|
-
require 'windows/api'
|
2
|
-
|
3
|
-
module Windows
|
4
|
-
module GDI
|
5
|
-
module PaintingDrawing
|
6
|
-
API.auto_namespace = 'Windows::GDI::PaintingDrawing'
|
7
|
-
API.auto_constant = true
|
8
|
-
API.auto_method = true
|
9
|
-
API.auto_unicode = false
|
10
|
-
|
11
|
-
private
|
12
|
-
|
13
|
-
# Flags for DrawCaption
|
14
|
-
DC_ACTIVE = 0x0001
|
15
|
-
DC_SMALLCAP = 0x0002
|
16
|
-
DC_ICON = 0x0004
|
17
|
-
DC_TEXT = 0x0008
|
18
|
-
DC_INBUTTON = 0x0010
|
19
|
-
DC_GRADIENT = 0x0020
|
20
|
-
DC_BUTTONS = 0x1000
|
21
|
-
|
22
|
-
# 3D border styles
|
23
|
-
BDR_RAISEDOUTER = 0x0001
|
24
|
-
BDR_SUNKENOUTER = 0x0002
|
25
|
-
BDR_RAISEDINNER = 0x0004
|
26
|
-
BDR_SUNKENINNER = 0x0008
|
27
|
-
|
28
|
-
BDR_OUTER = (BDR_RAISEDOUTER | BDR_SUNKENOUTER)
|
29
|
-
BDR_INNER = (BDR_RAISEDINNER | BDR_SUNKENINNER)
|
30
|
-
BDR_RAISED = (BDR_RAISEDOUTER | BDR_RAISEDINNER)
|
31
|
-
BDR_SUNKEN = (BDR_SUNKENOUTER | BDR_SUNKENINNER)
|
32
|
-
|
33
|
-
EDGE_RAISED = (BDR_RAISEDOUTER | BDR_RAISEDINNER)
|
34
|
-
EDGE_SUNKEN = (BDR_SUNKENOUTER | BDR_SUNKENINNER)
|
35
|
-
EDGE_ETCHED = (BDR_SUNKENOUTER | BDR_RAISEDINNER)
|
36
|
-
EDGE_BUMP = (BDR_RAISEDOUTER | BDR_SUNKENINNER)
|
37
|
-
|
38
|
-
# Border flags
|
39
|
-
BF_LEFT = 0x0001
|
40
|
-
BF_TOP = 0x0002
|
41
|
-
BF_RIGHT = 0x0004
|
42
|
-
BF_BOTTOM = 0x0008
|
43
|
-
|
44
|
-
BF_TOPLEFT = (BF_TOP | BF_LEFT)
|
45
|
-
BF_TOPRIGHT = (BF_TOP | BF_RIGHT)
|
46
|
-
BF_BOTTOMLEFT = (BF_BOTTOM | BF_LEFT)
|
47
|
-
BF_BOTTOMRIGHT = (BF_BOTTOM | BF_RIGHT)
|
48
|
-
BF_RECT = (BF_LEFT | BF_TOP | BF_RIGHT | BF_BOTTOM)
|
49
|
-
|
50
|
-
BF_DIAGONAL = 0x0010
|
51
|
-
|
52
|
-
BF_DIAGONAL_ENDTOPRIGHT = (BF_DIAGONAL | BF_TOP | BF_RIGHT)
|
53
|
-
BF_DIAGONAL_ENDTOPLEFT = (BF_DIAGONAL | BF_TOP | BF_LEFT)
|
54
|
-
BF_DIAGONAL_ENDBOTTOMLEFT = (BF_DIAGONAL | BF_BOTTOM | BF_LEFT)
|
55
|
-
BF_DIAGONAL_ENDBOTTOMRIGHT = (BF_DIAGONAL | BF_BOTTOM | BF_RIGHT)
|
56
|
-
|
57
|
-
BF_MIDDLE = 0x0800 # Fill in the middle
|
58
|
-
BF_SOFT = 0x1000 # For softer buttons
|
59
|
-
BF_ADJUST = 0x2000 # Calculate the space left over
|
60
|
-
BF_FLAT = 0x4000 # For flat rather than 3D borders
|
61
|
-
BF_MONO = 0x8000 # For monochrome borders
|
62
|
-
|
63
|
-
# Flags for DrawFrameControl
|
64
|
-
DFC_CAPTION = 1
|
65
|
-
DFC_MENU = 2
|
66
|
-
DFC_SCROLL = 3
|
67
|
-
DFC_BUTTON = 4
|
68
|
-
DFC_POPUPMENU = 5
|
69
|
-
|
70
|
-
DFCS_CAPTIONCLOSE = 0x0000
|
71
|
-
DFCS_CAPTIONMIN = 0x0001
|
72
|
-
DFCS_CAPTIONMAX = 0x0002
|
73
|
-
DFCS_CAPTIONRESTORE = 0x0003
|
74
|
-
DFCS_CAPTIONHELP = 0x0004
|
75
|
-
|
76
|
-
DFCS_MENUARROW = 0x0000
|
77
|
-
DFCS_MENUCHECK = 0x0001
|
78
|
-
DFCS_MENUBULLET = 0x0002
|
79
|
-
DFCS_MENUARROWRIGHT = 0x0004
|
80
|
-
DFCS_SCROLLUP = 0x0000
|
81
|
-
DFCS_SCROLLDOWN = 0x0001
|
82
|
-
DFCS_SCROLLLEFT = 0x0002
|
83
|
-
DFCS_SCROLLRIGHT = 0x0003
|
84
|
-
DFCS_SCROLLCOMBOBOX = 0x0005
|
85
|
-
DFCS_SCROLLSIZEGRIP = 0x0008
|
86
|
-
DFCS_SCROLLSIZEGRIPRIGHT = 0x0010
|
87
|
-
|
88
|
-
DFCS_BUTTONCHECK = 0x0000
|
89
|
-
DFCS_BUTTONRADIOIMAGE = 0x0001
|
90
|
-
DFCS_BUTTONRADIOMASK = 0x0002
|
91
|
-
DFCS_BUTTONRADIO = 0x0004
|
92
|
-
DFCS_BUTTON3STATE = 0x0008
|
93
|
-
DFCS_BUTTONPUSH = 0x0010
|
94
|
-
|
95
|
-
DFCS_INACTIVE = 0x0100
|
96
|
-
DFCS_PUSHED = 0x0200
|
97
|
-
DFCS_CHECKED = 0x0400
|
98
|
-
|
99
|
-
DFCS_TRANSPARENT = 0x0800
|
100
|
-
DFCS_HOT = 0x1000
|
101
|
-
|
102
|
-
DFCS_ADJUSTRECT = 0x2000
|
103
|
-
DFCS_FLAT = 0x4000
|
104
|
-
DFCS_MONO = 0x8000
|
105
|
-
|
106
|
-
API.new('BeginPaint', 'LP', 'L', 'user32')
|
107
|
-
API.new('GetWindowDC', 'L', 'L', 'user32')
|
108
|
-
API.new('DrawAnimatedRects', 'LIPP', 'B', 'user32')
|
109
|
-
API.new('DrawCaption', 'LLPL', 'B', 'user32')
|
110
|
-
API.new('DrawEdge', 'LPII', 'B', 'user32')
|
111
|
-
API.new('DrawFocusRect', 'LP', 'B', 'user32')
|
112
|
-
API.new('DrawFrameControl', 'LPLL', 'B', 'user32')
|
113
|
-
end
|
114
|
-
end
|
115
|
-
end
|
1
|
+
require 'windows/api'
|
2
|
+
|
3
|
+
module Windows
|
4
|
+
module GDI
|
5
|
+
module PaintingDrawing
|
6
|
+
API.auto_namespace = 'Windows::GDI::PaintingDrawing'
|
7
|
+
API.auto_constant = true
|
8
|
+
API.auto_method = true
|
9
|
+
API.auto_unicode = false
|
10
|
+
|
11
|
+
private
|
12
|
+
|
13
|
+
# Flags for DrawCaption
|
14
|
+
DC_ACTIVE = 0x0001
|
15
|
+
DC_SMALLCAP = 0x0002
|
16
|
+
DC_ICON = 0x0004
|
17
|
+
DC_TEXT = 0x0008
|
18
|
+
DC_INBUTTON = 0x0010
|
19
|
+
DC_GRADIENT = 0x0020
|
20
|
+
DC_BUTTONS = 0x1000
|
21
|
+
|
22
|
+
# 3D border styles
|
23
|
+
BDR_RAISEDOUTER = 0x0001
|
24
|
+
BDR_SUNKENOUTER = 0x0002
|
25
|
+
BDR_RAISEDINNER = 0x0004
|
26
|
+
BDR_SUNKENINNER = 0x0008
|
27
|
+
|
28
|
+
BDR_OUTER = (BDR_RAISEDOUTER | BDR_SUNKENOUTER)
|
29
|
+
BDR_INNER = (BDR_RAISEDINNER | BDR_SUNKENINNER)
|
30
|
+
BDR_RAISED = (BDR_RAISEDOUTER | BDR_RAISEDINNER)
|
31
|
+
BDR_SUNKEN = (BDR_SUNKENOUTER | BDR_SUNKENINNER)
|
32
|
+
|
33
|
+
EDGE_RAISED = (BDR_RAISEDOUTER | BDR_RAISEDINNER)
|
34
|
+
EDGE_SUNKEN = (BDR_SUNKENOUTER | BDR_SUNKENINNER)
|
35
|
+
EDGE_ETCHED = (BDR_SUNKENOUTER | BDR_RAISEDINNER)
|
36
|
+
EDGE_BUMP = (BDR_RAISEDOUTER | BDR_SUNKENINNER)
|
37
|
+
|
38
|
+
# Border flags
|
39
|
+
BF_LEFT = 0x0001
|
40
|
+
BF_TOP = 0x0002
|
41
|
+
BF_RIGHT = 0x0004
|
42
|
+
BF_BOTTOM = 0x0008
|
43
|
+
|
44
|
+
BF_TOPLEFT = (BF_TOP | BF_LEFT)
|
45
|
+
BF_TOPRIGHT = (BF_TOP | BF_RIGHT)
|
46
|
+
BF_BOTTOMLEFT = (BF_BOTTOM | BF_LEFT)
|
47
|
+
BF_BOTTOMRIGHT = (BF_BOTTOM | BF_RIGHT)
|
48
|
+
BF_RECT = (BF_LEFT | BF_TOP | BF_RIGHT | BF_BOTTOM)
|
49
|
+
|
50
|
+
BF_DIAGONAL = 0x0010
|
51
|
+
|
52
|
+
BF_DIAGONAL_ENDTOPRIGHT = (BF_DIAGONAL | BF_TOP | BF_RIGHT)
|
53
|
+
BF_DIAGONAL_ENDTOPLEFT = (BF_DIAGONAL | BF_TOP | BF_LEFT)
|
54
|
+
BF_DIAGONAL_ENDBOTTOMLEFT = (BF_DIAGONAL | BF_BOTTOM | BF_LEFT)
|
55
|
+
BF_DIAGONAL_ENDBOTTOMRIGHT = (BF_DIAGONAL | BF_BOTTOM | BF_RIGHT)
|
56
|
+
|
57
|
+
BF_MIDDLE = 0x0800 # Fill in the middle
|
58
|
+
BF_SOFT = 0x1000 # For softer buttons
|
59
|
+
BF_ADJUST = 0x2000 # Calculate the space left over
|
60
|
+
BF_FLAT = 0x4000 # For flat rather than 3D borders
|
61
|
+
BF_MONO = 0x8000 # For monochrome borders
|
62
|
+
|
63
|
+
# Flags for DrawFrameControl
|
64
|
+
DFC_CAPTION = 1
|
65
|
+
DFC_MENU = 2
|
66
|
+
DFC_SCROLL = 3
|
67
|
+
DFC_BUTTON = 4
|
68
|
+
DFC_POPUPMENU = 5
|
69
|
+
|
70
|
+
DFCS_CAPTIONCLOSE = 0x0000
|
71
|
+
DFCS_CAPTIONMIN = 0x0001
|
72
|
+
DFCS_CAPTIONMAX = 0x0002
|
73
|
+
DFCS_CAPTIONRESTORE = 0x0003
|
74
|
+
DFCS_CAPTIONHELP = 0x0004
|
75
|
+
|
76
|
+
DFCS_MENUARROW = 0x0000
|
77
|
+
DFCS_MENUCHECK = 0x0001
|
78
|
+
DFCS_MENUBULLET = 0x0002
|
79
|
+
DFCS_MENUARROWRIGHT = 0x0004
|
80
|
+
DFCS_SCROLLUP = 0x0000
|
81
|
+
DFCS_SCROLLDOWN = 0x0001
|
82
|
+
DFCS_SCROLLLEFT = 0x0002
|
83
|
+
DFCS_SCROLLRIGHT = 0x0003
|
84
|
+
DFCS_SCROLLCOMBOBOX = 0x0005
|
85
|
+
DFCS_SCROLLSIZEGRIP = 0x0008
|
86
|
+
DFCS_SCROLLSIZEGRIPRIGHT = 0x0010
|
87
|
+
|
88
|
+
DFCS_BUTTONCHECK = 0x0000
|
89
|
+
DFCS_BUTTONRADIOIMAGE = 0x0001
|
90
|
+
DFCS_BUTTONRADIOMASK = 0x0002
|
91
|
+
DFCS_BUTTONRADIO = 0x0004
|
92
|
+
DFCS_BUTTON3STATE = 0x0008
|
93
|
+
DFCS_BUTTONPUSH = 0x0010
|
94
|
+
|
95
|
+
DFCS_INACTIVE = 0x0100
|
96
|
+
DFCS_PUSHED = 0x0200
|
97
|
+
DFCS_CHECKED = 0x0400
|
98
|
+
|
99
|
+
DFCS_TRANSPARENT = 0x0800
|
100
|
+
DFCS_HOT = 0x1000
|
101
|
+
|
102
|
+
DFCS_ADJUSTRECT = 0x2000
|
103
|
+
DFCS_FLAT = 0x4000
|
104
|
+
DFCS_MONO = 0x8000
|
105
|
+
|
106
|
+
API.new('BeginPaint', 'LP', 'L', 'user32')
|
107
|
+
API.new('GetWindowDC', 'L', 'L', 'user32')
|
108
|
+
API.new('DrawAnimatedRects', 'LIPP', 'B', 'user32')
|
109
|
+
API.new('DrawCaption', 'LLPL', 'B', 'user32')
|
110
|
+
API.new('DrawEdge', 'LPII', 'B', 'user32')
|
111
|
+
API.new('DrawFocusRect', 'LP', 'B', 'user32')
|
112
|
+
API.new('DrawFrameControl', 'LPLL', 'B', 'user32')
|
113
|
+
end
|
114
|
+
end
|
115
|
+
end
|