comparison src/glyphs-msw.c @ 418:e804706bfb8c r21-2-17

Import from CVS: tag r21-2-17
author cvs
date Mon, 13 Aug 2007 11:23:13 +0200
parents 697ef44129c6
children 41dbb7a9d5f2
comparison
equal deleted inserted replaced
417:43a18b32d56e 418:e804706bfb8c
69 DEFINE_DEVICE_IIFORMAT (mswindows, widget); 69 DEFINE_DEVICE_IIFORMAT (mswindows, widget);
70 DEFINE_DEVICE_IIFORMAT (mswindows, label); 70 DEFINE_DEVICE_IIFORMAT (mswindows, label);
71 DEFINE_DEVICE_IIFORMAT (mswindows, scrollbar); 71 DEFINE_DEVICE_IIFORMAT (mswindows, scrollbar);
72 DEFINE_DEVICE_IIFORMAT (mswindows, combo); 72 DEFINE_DEVICE_IIFORMAT (mswindows, combo);
73 DEFINE_DEVICE_IIFORMAT (mswindows, progress); 73 DEFINE_DEVICE_IIFORMAT (mswindows, progress);
74 DEFINE_DEVICE_IIFORMAT (mswindows, tree);
75 DEFINE_DEVICE_IIFORMAT (mswindows, tab);
74 76
75 DEFINE_IMAGE_INSTANTIATOR_FORMAT (bmp); 77 DEFINE_IMAGE_INSTANTIATOR_FORMAT (bmp);
76 Lisp_Object Qbmp; 78 Lisp_Object Qbmp;
77 Lisp_Object Vmswindows_bitmap_file_path; 79 Lisp_Object Vmswindows_bitmap_file_path;
78 static COLORREF transparent_color = RGB (1,1,1); 80 static COLORREF transparent_color = RGB (1,1,1);
280 { 282 {
281 Lisp_Object device = IMAGE_INSTANCE_DEVICE (ii); 283 Lisp_Object device = IMAGE_INSTANCE_DEVICE (ii);
282 struct device *d = XDEVICE (device); 284 struct device *d = XDEVICE (device);
283 struct frame *f; 285 struct frame *f;
284 void* bmp_buf=0; 286 void* bmp_buf=0;
285 int type; 287 int type = 0;
286 HBITMAP bitmap; 288 HBITMAP bitmap;
287 HDC hdc; 289 HDC hdc;
288 290
289 if (!DEVICE_MSWINDOWS_P (d)) 291 if (!DEVICE_MSWINDOWS_P (d))
290 signal_simple_error ("Not an mswindows device", device); 292 signal_simple_error ("Not an mswindows device", device);
2039 if (IMAGE_INSTANCE_TYPE (p) == IMAGE_WIDGET) 2041 if (IMAGE_INSTANCE_TYPE (p) == IMAGE_WIDGET)
2040 { 2042 {
2041 /* buttons checked or otherwise */ 2043 /* buttons checked or otherwise */
2042 if ( EQ (IMAGE_INSTANCE_WIDGET_TYPE (p), Qbutton)) 2044 if ( EQ (IMAGE_INSTANCE_WIDGET_TYPE (p), Qbutton))
2043 { 2045 {
2044 if (gui_item_selected_p (&IMAGE_INSTANCE_WIDGET_ITEM (p))) 2046 if (gui_item_selected_p (IMAGE_INSTANCE_WIDGET_SINGLE_ITEM (p)))
2045 SendMessage (WIDGET_INSTANCE_MSWINDOWS_HANDLE (p), 2047 SendMessage (WIDGET_INSTANCE_MSWINDOWS_HANDLE (p),
2046 BM_SETCHECK, (WPARAM)BST_CHECKED, 0); 2048 BM_SETCHECK, (WPARAM)BST_CHECKED, 0);
2047 else 2049 else
2048 SendMessage (WIDGET_INSTANCE_MSWINDOWS_HANDLE (p), 2050 SendMessage (WIDGET_INSTANCE_MSWINDOWS_HANDLE (p),
2049 BM_SETCHECK, (WPARAM)BST_UNCHECKED, 0); 2051 BM_SETCHECK, (WPARAM)BST_UNCHECKED, 0);
2053 2055
2054 /* register widgets into our hastable so that we can cope with the 2056 /* register widgets into our hastable so that we can cope with the
2055 callbacks. The hashtable is weak so deregistration is handled 2057 callbacks. The hashtable is weak so deregistration is handled
2056 automatically */ 2058 automatically */
2057 static int 2059 static int
2058 mswindows_register_widget_instance (Lisp_Object instance, Lisp_Object domain) 2060 mswindows_register_gui_item (Lisp_Object gui, Lisp_Object domain)
2059 { 2061 {
2060 Lisp_Object frame = FW_FRAME (domain); 2062 Lisp_Object frame = FW_FRAME (domain);
2061 struct frame* f = XFRAME (frame); 2063 struct frame* f = XFRAME (frame);
2062 int id = gui_item_hash (FRAME_MSWINDOWS_WIDGET_HASH_TABLE (f), 2064 int id = gui_item_id_hash (FRAME_MSWINDOWS_WIDGET_HASH_TABLE (f),
2063 &XIMAGE_INSTANCE_WIDGET_ITEM (instance), 2065 gui,
2064 WIDGET_GLYPH_SLOT); 2066 WIDGET_GLYPH_SLOT);
2065 Fputhash (make_int (id), 2067 Fputhash (make_int (id),
2066 XIMAGE_INSTANCE_WIDGET_CALLBACK (instance), 2068 XGUI_ITEM (gui)->callback,
2067 FRAME_MSWINDOWS_WIDGET_HASH_TABLE (f)); 2069 FRAME_MSWINDOWS_WIDGET_HASH_TABLE (f));
2068 return id; 2070 return id;
2071 }
2072
2073 static int
2074 mswindows_register_widget_instance (Lisp_Object instance, Lisp_Object domain)
2075 {
2076 return mswindows_register_gui_item (XIMAGE_INSTANCE_WIDGET_SINGLE_ITEM (instance),
2077 domain);
2069 } 2078 }
2070 2079
2071 static void 2080 static void
2072 mswindows_subwindow_instantiate (Lisp_Object image_instance, Lisp_Object instantiator, 2081 mswindows_subwindow_instantiate (Lisp_Object image_instance, Lisp_Object instantiator,
2073 Lisp_Object pointer_fg, Lisp_Object pointer_bg, 2082 Lisp_Object pointer_fg, Lisp_Object pointer_bg,
2162 2171
2163 2172
2164 /************************************************************************/ 2173 /************************************************************************/
2165 /* widgets */ 2174 /* widgets */
2166 /************************************************************************/ 2175 /************************************************************************/
2167
2168 static void 2176 static void
2169 mswindows_widget_instantiate (Lisp_Object image_instance, Lisp_Object instantiator, 2177 mswindows_widget_instantiate (Lisp_Object image_instance, Lisp_Object instantiator,
2170 Lisp_Object pointer_fg, Lisp_Object pointer_bg, 2178 Lisp_Object pointer_fg, Lisp_Object pointer_bg,
2171 int dest_mask, Lisp_Object domain, 2179 int dest_mask, Lisp_Object domain,
2172 CONST char* class, int flags, int exflags) 2180 CONST char* class, int flags, int exflags)
2180 struct device* d = XDEVICE (device); 2188 struct device* d = XDEVICE (device);
2181 Lisp_Object frame = FW_FRAME (domain); 2189 Lisp_Object frame = FW_FRAME (domain);
2182 Extbyte* nm=0; 2190 Extbyte* nm=0;
2183 HWND wnd; 2191 HWND wnd;
2184 int id = 0xffff; 2192 int id = 0xffff;
2185 struct gui_item* pgui = &IMAGE_INSTANCE_WIDGET_ITEM (ii); 2193 Lisp_Object gui = IMAGE_INSTANCE_WIDGET_ITEM (ii);
2194 struct Lisp_Gui_Item* pgui = XGUI_ITEM (gui);
2186 2195
2187 if (!DEVICE_MSWINDOWS_P (d)) 2196 if (!DEVICE_MSWINDOWS_P (d))
2188 signal_simple_error ("Not an mswindows device", device); 2197 signal_simple_error ("Not an mswindows device", device);
2189 #if 0 2198 #if 0
2190 /* if the user specified another glyph as a group pick up the 2199 /* if the user specified another glyph as a group pick up the
2195 group = XSYMBOL (group)->value; 2204 group = XSYMBOL (group)->value;
2196 group = glyph_image_instance (group, domain, ERROR_ME, 1); 2205 group = glyph_image_instance (group, domain, ERROR_ME, 1);
2197 groupii = XIMAGE_INSTANCE (group); 2206 groupii = XIMAGE_INSTANCE (group);
2198 } 2207 }
2199 #endif 2208 #endif
2200 if (!gui_item_active_p (pgui)) 2209 if (!gui_item_active_p (gui))
2201 flags |= WS_DISABLED; 2210 flags |= WS_DISABLED;
2202 2211
2203 style = pgui->style; 2212 style = pgui->style;
2204 2213
2205 if (!NILP (pgui->callback)) 2214 if (!NILP (pgui->callback))
2254 { 2263 {
2255 struct Lisp_Image_Instance *ii = XIMAGE_INSTANCE (image_instance); 2264 struct Lisp_Image_Instance *ii = XIMAGE_INSTANCE (image_instance);
2256 HWND wnd; 2265 HWND wnd;
2257 int flags = BS_NOTIFY; 2266 int flags = BS_NOTIFY;
2258 Lisp_Object style; 2267 Lisp_Object style;
2259 struct gui_item* pgui = &IMAGE_INSTANCE_WIDGET_ITEM (ii); 2268 Lisp_Object gui = IMAGE_INSTANCE_WIDGET_ITEM (ii);
2269 struct Lisp_Gui_Item* pgui = XGUI_ITEM (gui);
2260 Lisp_Object glyph = find_keyword_in_vector (instantiator, Q_image); 2270 Lisp_Object glyph = find_keyword_in_vector (instantiator, Q_image);
2261 2271
2262 if (!gui_item_active_p (pgui)) 2272 if (!gui_item_active_p (gui))
2263 flags |= WS_DISABLED; 2273 flags |= WS_DISABLED;
2264 2274
2265 if (!NILP (glyph)) 2275 if (!NILP (glyph))
2266 { 2276 {
2267 if (!IMAGE_INSTANCEP (glyph)) 2277 if (!IMAGE_INSTANCEP (glyph))
2289 pointer_bg, dest_mask, domain, "BUTTON", flags, 2299 pointer_bg, dest_mask, domain, "BUTTON", flags,
2290 WS_EX_CONTROLPARENT); 2300 WS_EX_CONTROLPARENT);
2291 2301
2292 wnd = WIDGET_INSTANCE_MSWINDOWS_HANDLE (ii); 2302 wnd = WIDGET_INSTANCE_MSWINDOWS_HANDLE (ii);
2293 /* set the checked state */ 2303 /* set the checked state */
2294 if (gui_item_selected_p (pgui)) 2304 if (gui_item_selected_p (gui))
2295 SendMessage (wnd, BM_SETCHECK, (WPARAM)BST_CHECKED, 0); 2305 SendMessage (wnd, BM_SETCHECK, (WPARAM)BST_CHECKED, 0);
2296 else 2306 else
2297 SendMessage (wnd, BM_SETCHECK, (WPARAM)BST_UNCHECKED, 0); 2307 SendMessage (wnd, BM_SETCHECK, (WPARAM)BST_UNCHECKED, 0);
2298 /* add the image if one was given */ 2308 /* add the image if one was given */
2299 if (!NILP (glyph) && IMAGE_INSTANCEP (glyph)) 2309 if (!NILP (glyph) && IMAGE_INSTANCEP (glyph))
2318 ES_LEFT | ES_AUTOHSCROLL | WS_TABSTOP 2328 ES_LEFT | ES_AUTOHSCROLL | WS_TABSTOP
2319 | WS_BORDER, 2329 | WS_BORDER,
2320 WS_EX_CLIENTEDGE | WS_EX_CONTROLPARENT); 2330 WS_EX_CLIENTEDGE | WS_EX_CONTROLPARENT);
2321 } 2331 }
2322 2332
2323 /* instantiate an edit control */ 2333 /* instantiate a progress gauge */
2324 static void 2334 static void
2325 mswindows_progress_instantiate (Lisp_Object image_instance, Lisp_Object instantiator, 2335 mswindows_progress_instantiate (Lisp_Object image_instance, Lisp_Object instantiator,
2326 Lisp_Object pointer_fg, Lisp_Object pointer_bg, 2336 Lisp_Object pointer_fg, Lisp_Object pointer_bg,
2327 int dest_mask, Lisp_Object domain) 2337 int dest_mask, Lisp_Object domain)
2328 { 2338 {
2350 (XIMAGE_INSTANCE_WIDGET_FACE (ii), 2360 (XIMAGE_INSTANCE_WIDGET_FACE (ii),
2351 XIMAGE_INSTANCE_SUBWINDOW_FRAME (ii)))))); 2361 XIMAGE_INSTANCE_SUBWINDOW_FRAME (ii))))));
2352 #endif 2362 #endif
2353 } 2363 }
2354 2364
2365 /* instantiate a tree view widget */
2366 static HTREEITEM add_tree_item (Lisp_Object image_instance,
2367 HWND wnd, HTREEITEM parent, Lisp_Object entry,
2368 int children, Lisp_Object domain)
2369 {
2370 TV_INSERTSTRUCT tvitem;
2371 HTREEITEM ret;
2372
2373 tvitem.hParent = parent;
2374 tvitem.hInsertAfter = TVI_LAST;
2375 tvitem.item.mask = TVIF_TEXT | TVIF_CHILDREN;
2376 tvitem.item.cChildren = children;
2377
2378 if (VECTORP (entry))
2379 {
2380 /* we always maintain the real gui item at the head of the
2381 list. We have to put them in the list in the first place
2382 because the whole model assumes that the glyph instances have
2383 references to all the associated data. If we didn't do this
2384 GC would bite us badly. */
2385 Lisp_Object gui = gui_parse_item_keywords_no_errors (entry);
2386 if (CONSP (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance)))
2387 {
2388 Lisp_Object rest =
2389 Fcons (gui, XCDR (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance)));
2390 Fsetcdr (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance), rest);
2391 }
2392 else
2393 {
2394 XIMAGE_INSTANCE_WIDGET_ITEM (image_instance) =
2395 Fcons (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance), gui);
2396 }
2397
2398 tvitem.item.lParam = mswindows_register_gui_item (gui, domain);
2399 tvitem.item.mask |= TVIF_PARAM;
2400 GET_C_STRING_OS_DATA_ALLOCA (XGUI_ITEM (gui)->name,
2401 tvitem.item.pszText);
2402 }
2403 else
2404 GET_C_STRING_OS_DATA_ALLOCA (entry, tvitem.item.pszText);
2405
2406 tvitem.item.cchTextMax = strlen (tvitem.item.pszText);
2407
2408 if ((ret = (HTREEITEM)SendMessage (wnd, TVM_INSERTITEM,
2409 0, (LPARAM)&tvitem)) == 0)
2410 signal_simple_error ("error adding tree view entry", entry);
2411
2412 return ret;
2413 }
2414
2415 static void add_tree_item_list (Lisp_Object image_instance,
2416 HWND wnd, HTREEITEM parent, Lisp_Object list,
2417 Lisp_Object domain)
2418 {
2419 Lisp_Object rest;
2420
2421 /* get the first item */
2422 parent = add_tree_item (image_instance, wnd, parent, XCAR (list), TRUE, domain);
2423 /* recursively add items to the tree view */
2424 LIST_LOOP (rest, XCDR (list))
2425 {
2426 if (LISTP (XCAR (rest)))
2427 add_tree_item_list (image_instance, wnd, parent, XCAR (rest), domain);
2428 else
2429 add_tree_item (image_instance, wnd, parent, XCAR (rest), FALSE, domain);
2430 }
2431 }
2432
2433 static void
2434 mswindows_tree_instantiate (Lisp_Object image_instance, Lisp_Object instantiator,
2435 Lisp_Object pointer_fg, Lisp_Object pointer_bg,
2436 int dest_mask, Lisp_Object domain)
2437 {
2438 Lisp_Object rest;
2439 HWND wnd;
2440 HTREEITEM parent;
2441 struct Lisp_Image_Instance *ii = XIMAGE_INSTANCE (image_instance);
2442 mswindows_widget_instantiate (image_instance, instantiator, pointer_fg,
2443 pointer_bg, dest_mask, domain, WC_TREEVIEW,
2444 WS_TABSTOP | WS_BORDER | PBS_SMOOTH
2445 | TVS_HASLINES | TVS_HASBUTTONS,
2446 WS_EX_CLIENTEDGE | WS_EX_CONTROLPARENT);
2447
2448 wnd = WIDGET_INSTANCE_MSWINDOWS_HANDLE (ii);
2449
2450 /* define a root */
2451 parent = add_tree_item (image_instance,
2452 wnd, NULL, IMAGE_INSTANCE_WIDGET_TEXT (ii), TRUE,
2453 domain);
2454
2455 /* recursively add items to the tree view */
2456 LIST_LOOP (rest, Fplist_get (IMAGE_INSTANCE_WIDGET_PROPS (ii), Q_items, Qnil))
2457 {
2458 if (LISTP (XCAR (rest)))
2459 add_tree_item_list (image_instance, wnd, parent, XCAR (rest), domain);
2460 else
2461 add_tree_item (image_instance, wnd, parent, XCAR (rest), FALSE, domain);
2462 }
2463 }
2464
2465 /* instantiate a tab control */
2466 static TC_ITEM* add_tab_item (Lisp_Object image_instance,
2467 HWND wnd, Lisp_Object entry,
2468 Lisp_Object domain, int index)
2469 {
2470 TC_ITEM tvitem, *ret;
2471
2472 tvitem.mask = TCIF_TEXT;
2473
2474 if (VECTORP (entry))
2475 {
2476 /* we always maintain the real gui item at the head of the
2477 list. We have to put them in the list in the first place
2478 because the whole model assumes that the glyph instances have
2479 references to all the associated data. If we didn't do this
2480 GC would bite us badly. */
2481 Lisp_Object gui = gui_parse_item_keywords_no_errors (entry);
2482 if (CONSP (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance)))
2483 {
2484 Lisp_Object rest =
2485 Fcons (gui, XCDR (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance)));
2486 Fsetcdr (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance), rest);
2487 }
2488 else
2489 {
2490 XIMAGE_INSTANCE_WIDGET_ITEM (image_instance) =
2491 Fcons (XIMAGE_INSTANCE_WIDGET_ITEM (image_instance), gui);
2492 }
2493
2494 tvitem.lParam = mswindows_register_gui_item (gui, domain);
2495 tvitem.mask |= TCIF_PARAM;
2496 GET_C_STRING_OS_DATA_ALLOCA (XGUI_ITEM (gui)->name,
2497 tvitem.pszText);
2498 }
2499 else
2500 GET_C_STRING_OS_DATA_ALLOCA (entry, tvitem.pszText);
2501
2502 tvitem.cchTextMax = strlen (tvitem.pszText);
2503
2504 if ((ret = (TC_ITEM*)SendMessage (wnd, TCM_INSERTITEM,
2505 index, (LPARAM)&tvitem)) < 0)
2506 signal_simple_error ("error adding tab entry", entry);
2507
2508 return ret;
2509 }
2510
2511 static void
2512 mswindows_tab_instantiate (Lisp_Object image_instance, Lisp_Object instantiator,
2513 Lisp_Object pointer_fg, Lisp_Object pointer_bg,
2514 int dest_mask, Lisp_Object domain)
2515 {
2516 Lisp_Object rest;
2517 HWND wnd;
2518 HTREEITEM parent;
2519 int index = 0;
2520 struct Lisp_Image_Instance *ii = XIMAGE_INSTANCE (image_instance);
2521 mswindows_widget_instantiate (image_instance, instantiator, pointer_fg,
2522 pointer_bg, dest_mask, domain, WC_TABCONTROL,
2523 /* borders don't suit tabs so well */
2524 WS_TABSTOP,
2525 WS_EX_CONTROLPARENT);
2526
2527 wnd = WIDGET_INSTANCE_MSWINDOWS_HANDLE (ii);
2528
2529 /* add items to the tab */
2530 LIST_LOOP (rest, Fplist_get (IMAGE_INSTANCE_WIDGET_PROPS (ii), Q_items, Qnil))
2531 {
2532 add_tab_item (image_instance, wnd, XCAR (rest), domain, index);
2533 index++;
2534 }
2535 }
2536
2355 /* instantiate a static control possible for putting other things in */ 2537 /* instantiate a static control possible for putting other things in */
2356 static void 2538 static void
2357 mswindows_label_instantiate (Lisp_Object image_instance, Lisp_Object instantiator, 2539 mswindows_label_instantiate (Lisp_Object image_instance, Lisp_Object instantiator,
2358 Lisp_Object pointer_fg, Lisp_Object pointer_bg, 2540 Lisp_Object pointer_fg, Lisp_Object pointer_bg,
2359 int dest_mask, Lisp_Object domain) 2541 int dest_mask, Lisp_Object domain)
2556 IIFORMAT_HAS_DEVMETHOD (mswindows, xbm, instantiate); 2738 IIFORMAT_HAS_DEVMETHOD (mswindows, xbm, instantiate);
2557 #ifdef HAVE_XFACE 2739 #ifdef HAVE_XFACE
2558 INITIALIZE_DEVICE_IIFORMAT (mswindows, xface); 2740 INITIALIZE_DEVICE_IIFORMAT (mswindows, xface);
2559 IIFORMAT_HAS_DEVMETHOD (mswindows, xface, instantiate); 2741 IIFORMAT_HAS_DEVMETHOD (mswindows, xface, instantiate);
2560 #endif 2742 #endif
2743 /* button widget */
2561 INITIALIZE_DEVICE_IIFORMAT (mswindows, button); 2744 INITIALIZE_DEVICE_IIFORMAT (mswindows, button);
2562 IIFORMAT_HAS_DEVMETHOD (mswindows, button, property); 2745 IIFORMAT_HAS_DEVMETHOD (mswindows, button, property);
2563 IIFORMAT_HAS_DEVMETHOD (mswindows, button, instantiate); 2746 IIFORMAT_HAS_DEVMETHOD (mswindows, button, instantiate);
2564 2747
2565 INITIALIZE_DEVICE_IIFORMAT (mswindows, edit); 2748 INITIALIZE_DEVICE_IIFORMAT (mswindows, edit);
2573 IIFORMAT_HAS_DEVMETHOD (mswindows, widget, set_property); 2756 IIFORMAT_HAS_DEVMETHOD (mswindows, widget, set_property);
2574 #if 0 2757 #if 0
2575 INITIALIZE_DEVICE_IIFORMAT (mswindows, group); 2758 INITIALIZE_DEVICE_IIFORMAT (mswindows, group);
2576 IIFORMAT_HAS_DEVMETHOD (mswindows, group, instantiate); 2759 IIFORMAT_HAS_DEVMETHOD (mswindows, group, instantiate);
2577 #endif 2760 #endif
2761 /* label */
2578 INITIALIZE_DEVICE_IIFORMAT (mswindows, label); 2762 INITIALIZE_DEVICE_IIFORMAT (mswindows, label);
2579 IIFORMAT_HAS_DEVMETHOD (mswindows, label, instantiate); 2763 IIFORMAT_HAS_DEVMETHOD (mswindows, label, instantiate);
2580 2764
2765 /* combo box */
2581 INITIALIZE_DEVICE_IIFORMAT (mswindows, combo); 2766 INITIALIZE_DEVICE_IIFORMAT (mswindows, combo);
2582 IIFORMAT_HAS_DEVMETHOD (mswindows, combo, property); 2767 IIFORMAT_HAS_DEVMETHOD (mswindows, combo, property);
2583 IIFORMAT_HAS_DEVMETHOD (mswindows, combo, instantiate); 2768 IIFORMAT_HAS_DEVMETHOD (mswindows, combo, instantiate);
2584 2769
2770 /* scrollbar */
2585 INITIALIZE_DEVICE_IIFORMAT (mswindows, scrollbar); 2771 INITIALIZE_DEVICE_IIFORMAT (mswindows, scrollbar);
2586 IIFORMAT_HAS_DEVMETHOD (mswindows, scrollbar, instantiate); 2772 IIFORMAT_HAS_DEVMETHOD (mswindows, scrollbar, instantiate);
2587 2773
2774 /* progress gauge */
2588 INITIALIZE_DEVICE_IIFORMAT (mswindows, progress); 2775 INITIALIZE_DEVICE_IIFORMAT (mswindows, progress);
2589 IIFORMAT_HAS_DEVMETHOD (mswindows, progress, set_property); 2776 IIFORMAT_HAS_DEVMETHOD (mswindows, progress, set_property);
2590 IIFORMAT_HAS_DEVMETHOD (mswindows, progress, instantiate); 2777 IIFORMAT_HAS_DEVMETHOD (mswindows, progress, instantiate);
2591 2778
2779 /* tree view widget */
2780 INITIALIZE_DEVICE_IIFORMAT (mswindows, tree);
2781 /* IIFORMAT_HAS_DEVMETHOD (mswindows, progress, set_property);*/
2782 IIFORMAT_HAS_DEVMETHOD (mswindows, tree, instantiate);
2783
2784 /* tab control widget */
2785 INITIALIZE_DEVICE_IIFORMAT (mswindows, tab);
2786 IIFORMAT_HAS_DEVMETHOD (mswindows, tab, instantiate);
2787
2788 /* windows bitmap format */
2592 INITIALIZE_IMAGE_INSTANTIATOR_FORMAT (bmp, "bmp"); 2789 INITIALIZE_IMAGE_INSTANTIATOR_FORMAT (bmp, "bmp");
2593
2594 IIFORMAT_HAS_METHOD (bmp, validate); 2790 IIFORMAT_HAS_METHOD (bmp, validate);
2595 IIFORMAT_HAS_METHOD (bmp, normalize); 2791 IIFORMAT_HAS_METHOD (bmp, normalize);
2596 IIFORMAT_HAS_METHOD (bmp, possible_dest_types); 2792 IIFORMAT_HAS_METHOD (bmp, possible_dest_types);
2597 IIFORMAT_HAS_METHOD (bmp, instantiate); 2793 IIFORMAT_HAS_METHOD (bmp, instantiate);
2598 2794
2599 IIFORMAT_VALID_KEYWORD (bmp, Q_data, check_valid_string); 2795 IIFORMAT_VALID_KEYWORD (bmp, Q_data, check_valid_string);
2600 IIFORMAT_VALID_KEYWORD (bmp, Q_file, check_valid_string); 2796 IIFORMAT_VALID_KEYWORD (bmp, Q_file, check_valid_string);
2601 2797
2798 /* mswindows resources */
2602 INITIALIZE_IMAGE_INSTANTIATOR_FORMAT (mswindows_resource, 2799 INITIALIZE_IMAGE_INSTANTIATOR_FORMAT (mswindows_resource,
2603 "mswindows-resource"); 2800 "mswindows-resource");
2604 2801
2605 IIFORMAT_HAS_METHOD (mswindows_resource, validate); 2802 IIFORMAT_HAS_METHOD (mswindows_resource, validate);
2606 IIFORMAT_HAS_METHOD (mswindows_resource, normalize); 2803 IIFORMAT_HAS_METHOD (mswindows_resource, normalize);
2628 Fprovide (Qedit); 2825 Fprovide (Qedit);
2629 Fprovide (Qcombo); 2826 Fprovide (Qcombo);
2630 Fprovide (Qscrollbar); 2827 Fprovide (Qscrollbar);
2631 Fprovide (Qlabel); 2828 Fprovide (Qlabel);
2632 Fprovide (Qprogress); 2829 Fprovide (Qprogress);
2830 Fprovide (Qtree);
2831 Fprovide (Qtab);
2633 } 2832 }
2634 2833
2635 void 2834 void
2636 complex_vars_of_glyphs_mswindows (void) 2835 complex_vars_of_glyphs_mswindows (void)
2637 { 2836 {