Mercurial > dwindows
comparison mac/dw.c @ 549:b744c2b86df8
Argh, MacOS was using increments... let's see if we can work around it,
and avoid the problem entirely.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Wed, 07 Apr 2004 09:56:11 +0000 |
parents | caa7ed17c132 |
children | 33b792d5c8ab |
comparison
equal
deleted
inserted
replaced
548:0369176130af | 549:b744c2b86df8 |
---|---|
963 * type: Either DW_VERT (vertical) or DW_HORZ (horizontal). | 963 * type: Either DW_VERT (vertical) or DW_HORZ (horizontal). |
964 * pad: Number of pixels to pad around the box. | 964 * pad: Number of pixels to pad around the box. |
965 */ | 965 */ |
966 HWND API dw_box_new(int type, int pad) | 966 HWND API dw_box_new(int type, int pad) |
967 { | 967 { |
968 return 0; | 968 ControlRef hwnd = NewControl(CreationWindow, NULL, "\p", |
969 true, kControlSupportsEmbedding | kControlHasSpecialBackground, | |
970 0, 1, kControlUserPaneProc, (SInt32) 0); | |
971 return (HWND)hwnd; | |
969 } | 972 } |
970 | 973 |
971 /* | 974 /* |
972 * Create a new Group Box to be packed. | 975 * Create a new Group Box to be packed. |
973 * Parameters: | 976 * Parameters: |
1146 HWND API dw_text_new(char *text, ULONG id) | 1149 HWND API dw_text_new(char *text, ULONG id) |
1147 { | 1150 { |
1148 HWND hwnd = 0; | 1151 HWND hwnd = 0; |
1149 CFStringRef cftext = CFStringCreateWithCString(NULL, text, kCFStringEncodingDOSLatinUS); | 1152 CFStringRef cftext = CFStringCreateWithCString(NULL, text, kCFStringEncodingDOSLatinUS); |
1150 CreateStaticTextControl (CreationWindow, &CreationRect, cftext, NULL, &hwnd); | 1153 CreateStaticTextControl (CreationWindow, &CreationRect, cftext, NULL, &hwnd); |
1151 CFRelease(cftext); | 1154 CFRelease(cftext); |
1152 return hwnd; | 1155 return hwnd; |
1153 } | 1156 } |
1154 | 1157 |
1155 /* | 1158 /* |
1156 * Create a new status text window (widget) to be packed. | 1159 * Create a new status text window (widget) to be packed. |
1311 * id: An ID to be used with dw_window_from_id() or 0L. | 1314 * id: An ID to be used with dw_window_from_id() or 0L. |
1312 */ | 1315 */ |
1313 HWND API dw_scrollbar_new(int vertical, ULONG id) | 1316 HWND API dw_scrollbar_new(int vertical, ULONG id) |
1314 { | 1317 { |
1315 HWND hwnd; | 1318 HWND hwnd; |
1316 CreateScrollBarControl(CreationWindow, &CreationRect, 0, 0, increments, increments, FALSE, 0, &hwnd); | 1319 CreateScrollBarControl(CreationWindow, &CreationRect, 0, 0, 100, 100, FALSE, 0, &hwnd); |
1317 return hwnd; | 1320 return hwnd; |
1318 } | 1321 } |
1319 | 1322 |
1320 /* | 1323 /* |
1321 * Create a new percent bar window (widget) to be packed. | 1324 * Create a new percent bar window (widget) to be packed. |