summaryrefslogtreecommitdiff
path: root/gdk/win32/gdkinput-win32.c
Commit message (Collapse)AuthorAgeFilesLines
* gdk/win32/gdkprivate-win32.h Drop global variable _gdk_root_window, justTor Lillqvist2005-03-161-4/+4
| | | | | | | | | | | | | | | | | | | | | 2005-03-16 Tor Lillqvist <tml@novell.com> * gdk/win32/gdkprivate-win32.h * gdk/win32/*.c: Drop global variable _gdk_root_window, just call GetDesktopWindow(). Rename the GdkWindow* _gdk_parent_root to _gdk_root. * gdk/win32/gdkwindow-win32.h (GdkWindowImplWin32): Add toplevel_window_type field. * gdk/win32/gdkwindow-win32.c: As there is only one root window in GDK on Win32, we can compare directly to _gdk_root instead of checking the window type. (gdk_window_reparent): When reparenting a child of the desktop clear out the window decorations. Correspondingly, when reparenting to the desktop, add decorations. As in the X11 backend, save the window type of a toplevel window when reparenting, in case it is reparented back to toplevel.
* Print debugging output only if asked for, not always.Tor Lillqvist2005-03-161-9/+9
| | | | | | | | | | | | | | | | | | | 2005-03-16 Tor Lillqvist <tml@novell.com> * gdk/win32/gdkdisplay-win32.c (_win32_on_clipboard_change): Print debugging output only if asked for, not always. * gdk/win32/*.c: Use the %+d%+d format for coordinate pairs in debugging printout instead of +%d+%d. Misc other additions and cosmetic improvements to debugging printouts. Use API_CALL() and GDI_CALL() macros in more places. * gdk/win32/gdkwindow-win32.c (gdk_window_move, gdk_window_resize, gdk_window_move_resize): To detect child windows, check whether the real parent is not the desktop window, instead of relying on the GDK window type being GDK_WINDOW_CHILD. Foreign GtkPlug windows have a GDK window type GDK_WINDOW_FOREIGN, but are still de facto child windows.
* Implement better handling of Wintab tablet context overlap on Win32.Robert Ögren2005-02-251-0/+26
| | | | | | | | | | | | | | | 2005-02-24 Robert Ögren <gtk@roboros.com> Implement better handling of Wintab tablet context overlap on Win32. (#167298) * gdk/win32/gdkinput-win32.c (_gdk_input_set_tablet_active): New function that brings any tablet contexts to the top of the overlap order. * gdk/win32/gdkinput-win32.h: Declare _gdk_input_set_tablet_active () * gdk/win32/gdkevents-win32.c (gdk_event_translate): Call _gdk_input_set_tablet_active when a window is activated (on WM_ACTIVATE)
* Implement lazy extended input initialization on Win32, by Robert Ögren.Tor Lillqvist2005-02-021-6/+17
| | | | | | | | | | | | | | | | | | | | | | | 2005-02-02 Tor Lillqvist <tml@novell.com> Implement lazy extended input initialization on Win32, by Robert Ögren. Fixes #163163, possibly #162334. Lazy initialization would be a good idea in any case even if it didn't fix any visible problems, though. The Wacom tablet driver seems to get confused if Wintab is initialized but no window is shown before the process exits. This is the case for some GIMP plug-ins, for instance. * gdk/win32/gdkinput-win32.c (_gdk_input_wintab_init_check): Made non-static (and renamed). (_gdk_input_init): Don't call _gdk_input_wintab_init_check(). * gdk/win32/gdkinput-win32.h: Declare _gdk_input_wintab_init_check(). * gdk/win32/gdkinput.c (gdk_devices_list, gdk_display_list_devices, gdk_input_set_extension_events): Call _gdk_input_wintab_init_check() here instead.
* Set lcSysOrgX and lcSysOrgY from device instead of hardcoding to 0, aRobert Ögren2004-09-251-1/+2
| | | | | | | | 2004-09-25 Robert Ögren <gtk@roboros.com> * gdk/win32/gdkinput-win32.c (gdk_input_wintab_init): Set lcSysOrgX and lcSysOrgY from device instead of hardcoding to 0, a further fix for bug #145467.
* On Win32, do not produce tablet motion or button events while a window isRobert Ögren2004-08-311-1/+8
| | | | | | | | | | | | | | | 2004-08-28 Robert Ögren <gtk@roboros.com> On Win32, do not produce tablet motion or button events while a window is being moved or resized. (#151090, reported by Shaneyfelt) * gdk/win32/gdkprivate-win32.h * gdk/win32/gdkglobals-win32.c * gdk/win32/gdkevents-win32.c: Rename the variable resizing to _sizemove_in_progress and make it extern. * gdk/win32/gdkinput-win32.c (_gdk_input_other_event): Ignore motion and button events if _sizemove_in_progress is true.
* On Win32, make graphical tablets work on multi-monitor systems. (#145467,Robert Ögren2004-08-261-15/+12
| | | | | | | | | | | | | 2004-08-22 Robert Ögren <gtk@roboros.com> On Win32, make graphical tablets work on multi-monitor systems. (#145467, reported by buttknock1@ya...) * gdk/win32/gdkinput-win32.c (gdk_input_translate_coordinates): Use dimensions of _gdk_parent_root as screen size. (gdk_input_get_root_relative_geometry): Get coordinates relative to GDK root window instead of Win32 coordinates. (_gdk_input_other_event): Updated accordingly.
* Set x_root and y_root in button and motion events from the tablet.Robert Ögren2004-08-061-0/+14
| | | | | | | 2004-07-28 Robert Ögren <gtk@roboros.com> * gdk/win32/gdkinput-win32.c (_gdk_input_other_event): Set x_root and y_root in button and motion events from the tablet. (#148715)
* Fix win32 build problem w/o wintab. Fixed #145242J. Ali Harlow2004-07-011-1/+1
| | | | | | | 2004-07-01 J. Ali Harlow <ali@juiblex.co.uk> * gdk/win32/gdkinput-win32.c (_gdk_input_ungrab_pointer): Fix win32 build problem w/o wintab. Fixed #145242
* Send key modifiers (shift, ctrl etc) in button and motion events from theRobert Ögren2004-05-271-37/+51
| | | | | | | | | | | | | | 2004-05-26 Robert Ögren <gtk@roboros.com> * gdk/win32/gdkinput-win32.c (_gdk_input_other_event): Send key modifiers (shift, ctrl etc) in button and motion events from the tablet. (#143240) 2004-05-26 Robert Ögren <gtk@roboros.com> * gdk/win32/gdkinput-win32.c (gdk_device_get_state): Simple implementation for extended input devices using last known device state (#143237)
* Don't propagate mouse events to windows that want extended input events.Robert Ögren2004-05-241-5/+49
| | | | | | | | | | | | | | | | | | | 2004-05-11 Robert Ögren <gtk@roboros.com> * gdk/win32/gdkevents-win32.c (propagate): Don't propagate mouse events to windows that want extended input events. (#142943) (gdk_event_translate): Move check for extended input devices to propagate, new parameter to propagate. (gdk_pointer_grab, gdk_display_pointer_ungrab): Enable calls to _gdk_input_(un)grab_pointer. (#142943) * gdk/win32/gdkinput-win32.c (_gdk_input_other_event): Check for input grab. [Fix missing update of impl in "dijkstra" event propagation loop] Drop the parallel "impl" pointer, just use a cast. Don't propagate beyond windows that want normal input events. (#142943) (gdk_input_grab_pointer, gdk_input_ungrab_pointer): Limited implementation of input grab. (#142943)
* Remove duplicated line. (Spotted by Benoît Carpentier.)Tor Lillqvist2004-05-221-1/+0
| | | | | | | 2004-05-22 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkinput-win32.c (print_lc): Remove duplicated line. (Spotted by Benoît Carpentier.)
* Add missing call to g_object_ref in Wintab code. (#138341)Robert Ögren2004-05-121-6/+25
| | | | | | | | | | | | | 2004-05-11 Robert Ögren <gtk@roboros.com> * gdk/win32/gdkevents-win32.c (gdk_event_translate): Add missing call to g_object_ref in Wintab code. (#138341) * gdk/win32/gdkinput-win32.c: Fix numerous Wintab problems including unallocated buffers for event->motion.axes and event->button.axes, unsigned wraparound problem in the code for detecting missing press/release events and assigning min instead of max when setting up axes.
* Fixes #136082 and #135265, patch by Morten Welinder.Federico Mena Quintero2004-03-061-1/+1
| | | | | | | | | | 2004-03-05 Federico Mena Quintero <federico@ximian.com> Fixes #136082 and #135265, patch by Morten Welinder. * configure.in: Use AC_SYS_LARGEFILE. * */*.c: #include <config.h>
* Add missing entries, thanks to J. Ali Harlow.Tor Lillqvist2004-03-051-15/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-03-05 Tor Lillqvist <tml@iki.fi> * gdk/gdk.def: Add missing entries, thanks to J. Ali Harlow. * gdk/win32/gdkcursor-win32.c (color_is_white): const-correctness. (gdk_cursor_new_from_pixbuf): Copy of the non-Xcursor X11 implementation. (gdk_display_supports_cursor_alpha, gdk_display_supports_cursor_color): Dummy implementations. (gdk_display_get_default_cursor_size, gdk_display_get_maximal_cursor_size): Implement. * gdk/win32/gdkdisplay-win32.c (gdk_display_get_default_group): Dummy implementation. * gdk/win32/gdkevents-win32.c (gdk_net_wm_supports): Dummy implementation. * gdk/win32/gdkfont-win32.c (gdk_font_get_display): Implement. * gdk/win32/gdkinput-win32.c (gdk_input_motion_events): Remove, not in API. * gdk/win32/gdkwindow-win32.c (gdk_window_get_group): Dummy implementation.
* gdk/win32/gdkinput-win32.h Drop the GdkEvent* parameter, it wasn't used.Tor Lillqvist2003-08-071-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-08-07 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkinput-win32.h * gdk/win32/gdkinput-win32.c (_gdk_input_configure_event, _gdk_input_enter_event): Drop the GdkEvent* parameter, it wasn't used. * gdk/win32/gdkevents-win32.c (gdk_event_translate): Adapt caller accordingly, in fact an uninitialised variable was dereferenced. [Win32] Add support for multiple monitors. * gdk/win32/gdkprivate-win32.h * gdk/win32/gdkglobals-win32.c: New global variables for multiple-monitor info: _gdk_num_monitors, _gdk_monitors, and _gdk_offset_x and _gdk_offset_y. * gdk/win32/gdkdisplay-win32.c (count_monitor, enum_monitor): New functions, enumeration functions passed to EnumDisplayMonitors(). (gdk_display_open): If the EnumDisplayMonitors() and GetMonitorInfo() API is present (on Win98, Win2000 and newer), use if to find out monitor info. Calculate the offset between Win32 coordinates (relative to the primary monitor's origin (and thus negative on monitors to the left of or above it), and GDK's (visible coordinates should be non-negative). * gdk/win32/gdkscreen-win32 (gdk_screen_get_n_monitors, gdk_screen_get_monitor_geometry): Use information collected above. (gdk_window_move, gdk_window_move_resize_window_get_geometry): Subtract _gdk_offset_{x,y} from GDK root window coordinates. (gdk_window_get_geometry, gdk_window_get_origin, gdk_window_get_frame_extents): For top-level windows, add _gdk_offset_{x,y} to GDK root window coordinates Still need to handle multiple monitors in gdk_window_fullscreen(). Probably should make the window fullscreen on the monitor where the cursor is? * gdk/win32/gdkevents-win32.c: Add _gdk_offset_{x,y} to all GDK root window coordinates in GdkEvents. [Win32] Fix geometry hint handling. Add support for resize increment and base size, and aspect ratio geometry hints. The "gridded geometry" test in testgtk now works beautifully. * gdk/win32/gdkwindow-win32.c (gdk_window_set_geometry_hints): Turns out this function shouldn't actually ever modify the window's size, just store the hints. (Old code kept for a while inside #if 0.) (gdk_window_set_hints): Remove presumably broken code that handles the position hints, this function is obsolete anyway. * gdk/win32/gdkevents-win32.c: Drop the current_{x,y}_root variables, not used. (adjust_drag): New function, used to implement resize increment hints. (gdk_event_translate): Handle WM_SIZING, implement resize increment and base size, and aspect ratio geometry hints here. The WM_GETMINMAXINFO handler takes care of the minimum and maximum size hints as before. Fix the WM_GETMINMAXINFO handler to take into account window decorations. No need to modify the ptMaxPosition and ptMaxSize fields in the MINMAXINFO struct, the defaults are fine. * gdk/win32/gdkprivate-win32.h * gdk/win32/gdkwindow-win32.c (_gdk_win32_adjust_client_rect, _gdk_win32_get_adjusted_client_rect): New helper functions.
* New function, callback proc for EnumWindows().Tor Lillqvist2003-06-301-4/+4
| | | | | | | | | | | | | | | | 2003-06-30 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkdnd-win32.c (find_window_enum_proc): New function, callback proc for EnumWindows(). (gdk_drag_find_window_for_screen): Actually take the drag_window argument into account: Instead of using WindowFromPoint(), use EnumWindows(), to be able to skip the drag_window. (#116320, Tony M Brown, Herman Bloggs) * gdk/win32/*.c: Replace gdk_drawable_ref()/unref() and gdk_window_ref()/unref() calls with g_object_ref()/unref(). Consistently use %p format in debugging output of pointers and HANDLEs.
* Bug #107664 continued:Matthias Clasen2003-03-081-9/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-03-08 Matthias Clasen <maclas@gmx.de> Bug #107664 continued: * gdk/x11/gdkinputprivate.h: * gdk/x11/gdkinput-none.c (_gdk_input_window_none_event): Remove. (_gdk_input_other_event): Return gboolean. * gdk/x11/gdkinput-xfree.c (_gdk_input_window_none_event): Remove. (_gdk_input_other_event): Return gboolean. * gdk/x11/gdkinput-x11.c (_gdk_input_common_other_event): Return gboolean. * gdk/x11/gdkevents-x11.c (gdk_event_translate): Make return_val gboolean, remove pointless call to _gdk_input_window_none_event. * gdk/win32/gdkinput-win32.[hc] (_gdk_input_other_event): Return gboolean. (_gdk_input_window_none_event): Remove. * gtk/gtktextiter.c (_gtk_text_iter_get_indexable_segment): (_gtk_text_iter_get_any_segment): (_gtk_text_iter_get_segment_byte): (_gtk_text_iter_get_segment_char): (_gtk_text_iter_get_text_line): (_gtk_text_iter_get_btree): Fix 0/NULL confusion. * gdk/x11/gdkdnd-x11.c (motif_target_table_check): Return gint. * gdk/win32/gdkfont-win32.c (gdk_font_equal): * gdk/linux-fb/gdkwindow-fb.c (gdk_window_get_deskrelative_origin): (gdk_window_get_origin): * gdk/linux-fb/gdkcolor-fb.c (gdk_colors_alloc): Fix 0/FALSE confusion.
* gdk/win32/gdkprivate-win32.h Rename all global variables and functions toTor Lillqvist2002-11-121-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-11-12 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkprivate-win32.h * gdk/win32/*.c: Rename all global variables and functions to start with underscore. Merge from stable: More work on the Win32 backend. The cause of some scrolling problems was that SetWindowPos() and ScrollWindowEx() don't blit those parts of the window they think are invalid. As we didn't keep Windows's update region in synch with GDK's, Windows thought those areas that in fact had been updated were invalid. Calling ValidateRgn() in _gdk_windowing_window_queue_antiexpose() seems to be an elegant and efficient solution, removing from Windows's update region those areas we are about to repaint proactively. In some cases garbage leftover values were used for the clip origin in GdkGCWin32. This showed up as odd blank areas around the pixmaps included in the Text Widget in gtk-demo. Having the clip region either as a GdkRegion or a HRGN in GdkGCWin32 was unnecessary, it's better to just use a HRGN. The translation and antiexpose queue handling in gdkgeometry-win32.c seems unnecessary (and not implementable in the same way as on X11 anyway, no serial numbers) on Windows, ifdeffed out. Don't (try to) do guffaw scrolling as there is no static window gravity on Windows. Guffaw scrolling would be unnecessary anyway, as there is the ScrollWindow() API. This improves the behaviour of the Text Widget demo in gtk-demo a lot. But I have no idea how the lack of static win gravity should be handled in other places where the X11 code uses it. Especially _gdk_window_move_resize_child(). There is still some problem in expose handling. By moving an obscuring window back and forth over testgtk's main window, for instance, every now and then you typically get narrow vertical or horizontal strips of pixels that haven't been properly redrawn after being exposed. A fencepost error somewhere? Otherwise, all of testgtk and gtk-demo except "big windows" now seem to work pretty well. Bug #79720 should be fixed now. * gdk/win32/gdkcolor-win32.c (gdk_win32_color_to_string, gdk_win32_print_paletteentries, gdk_win32_print_system_palette, gdk_win32_print_hpalette) * gdk/win32/gdkdrawable-win32.c (gdk_win32_drawable_description) * gdk/win32/gdkevents-win32.c (gdk_win32_message_name): Move all debugging helper functions to gdkmain-win32.c. * gdk/win32/gdkdrawable-win32.c (_gdk_win32_draw_tiles): Rewrite. Make static. Must take tile origin parameters, too. (gdk_win32_draw_rectangle): Pass the tile/stipple origin to _gdk_win32_draw_tiles(). Remove #if 0 code. (blit_inside_window): Don't call ScrollDC(), that didn't work at all like I thought. A simple call to BitBlt() is enough. * gdk/win32/gdkevents-win32.c (gdk_event_translate) Remove unused latin_locale_loaded variable. (_gdk_win32_get_next_tick): New function. Used to make sure timestamps of events are always increasing, both in events generated from the window procedure and in events gotten via PeekMessage(). Not sure whether this is actually useful, but it seemed as a good idea. (real_window_procedure): Don't use a local GdkEventPrivate variable. Don't attempt any compression of configure or expose events here, handled elsewhere. (erase_background): Accumulate window offsets when traversing up the parent chain for GDK_PARENT_RELATIVE_BG, in order to get correct alignment of background pixmaps. Don't fill with BLACK_BRUSH if GDK_NO_BG. (gdk_event_get_graphics_expose): A bit more verbose debugging output. (gdk_event_translate): Use _gdk_win32_get_next_tick(). In the WM_PAINT handler, don't check for empty update rect. When we get a WM_PAINT, the update region isn't empty. And if it for some strange reason is, that will be handled later anyway. Call GetUpdateRgn() before calling BeginPaint() and EndPaint() (which empty the update region). * gdk/win32/gdkdnd-win32.c * gdk/win32/gdkinput-win32.c: Use _gdk_win32_get_next_tick(). * gdk/win32/gdkfont-win32.c: Use %p to print HFONTs. (gdk_text_size): Remove, unused. * gdk/win32/gdkgc-win32.c: Set clip origins to zero when appropriate. (gdk_gc_copy): Increase refcount on colormap if present. (gdk_win32_hdc_get): Handle just hcliprgn. If we have a stipple, combine it with clip region after selecting into the DC. (_gdk_win32_bitmap_to_hrgn): Rename from _gdk_win32_bitmap_to_region. (_gdk_win3_gdkregion_to_hrgn): New function, code snippet extracted from gdk_win32_hdc_get(). * gdk/win32/gdkgeometry-win32.c: Ifdef out the translate_queue handling. (gdk_window_copy_area_scroll): Increase clipRect to avoid ScrollWindowEx() not scrolling pixels it thinks are invalid. Scroll also children with the ScrollWindowEx() call. No need to call gdk_window_move() on the children. (gdk_window_scroll): Don't do guffaw scrolling. (gdk_window_compute_position): Fix typo, used win32_y where x was intended. (gdk_window_premove, gdk_window_postmove, gdk_window_clip_changed): Add debugging output. (_gdk_windowing_window_queue_antiexpose): Just call ValidateRgn() on the region. (_gdk_window_process_expose): No use for the serial number parameter now. Instead of a rectangle, take a region parameter, as Windows gives us one in WM_PAINT. * gdk/win32/gdkmain-win32.c (_gdk_win32_lbstyle_to_string, _gdk_win32_pstype_to_string, _gdk_win32_psstyle_to_string, _gdk_win32_psendcap_to_string, _gdk_win32_psjoin_to_string, _gdk_win32_rect_to_string, _gdk_win32_gdkrectangle_to_string, _gdk_win32_gdkregion_to_string): New debugging functions. (static_printf): Helper function for the above. sprintfs into a static circular buffer, return value should be used "soon". * gdk/win32/gdkwindow-win32.c (gdk_propagate_shapes): Plug memory leak, free list after use. (gdk_window_gravity_works): Remove, we know that there is no such thing on Windows. (gdk_window_set_static_bit_gravity, gdk_window_set_static_win_gravity): Ditto, remove, they didn't do anything anyway. (_gdk_windowing_window_init, gdk_window_foreign_new): Call _gdk_window_init_position() like in the X11 backend. (gdk_window_reparent): Don't call the now nonexistent gdk_window_set_static_win_gravity(). No idea what should be done instead. (gdk_window_get_geometry): The returned x and y should be relative to parent. Used to be always zero.. (gdk_window_set_static_gravities): Return FALSE if trying to set static gravity. * gdk/win32/gdkprivate-win32.h: Drop the clip_region field from GdkGCWin32. Only use the HRGN hcliprgn. Declare new functions. * gdk/win32/*.c: Use new debugging functions. * gdk/win32/rc/gdk.rc.in: Update copyright year.
* Delete leftover declarations of the obsolete Win32-only functionsTor Lillqvist2002-09-191-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-09-20 Tor Lillqvist <tml@iki.fi> * gdk/gdkfont.h: Delete leftover declarations of the obsolete Win32-only functions gdk_font_full_name_get() and gdk_font_full_name_free(). * gdk/gdk.def: Delete from here, too. * gdk/win32/gdkfont-win32.c (logfont_to_xlfd, gdk_font_full_name_get, gdk_font_full_name_free): Delete implementation, and helper functions. (pattern_match, InnerEnumFontFamExProc, EnumFontFamExProc, gdk_font_list_new, gdk_font_list_free): Delete unused functions. (gdk_text_width, gdk_text_width_wc) Instead of code duplication, let gdk_text_extents() and gdk_text_extents_wc() do the job. * gdk/win32/gdkgc-win32.c (gdk_win32_gc_values_to_win32values): Don't use the above removed functions in debugging output. * gdk/win32/gdkdisplay-win32.c * gdk/win32/gdkmain-win32.c * gdk/win32/gdkprivate-win32.h * gdk/win32/gdkselection-win32.c * gdk/win32/gdkinput-win32.h * gdk/win32/gdkinput.c: Make it compile again, pass a GdkDisplay in a couple of places.
* Merge from gtk-1-3-win32-production and gtk-2-0:Tor Lillqvist2002-09-111-2/+2
| | | | | | | | | | | | | | | 2002-09-12 Tor Lillqvist <tml@iki.fi> Merge from gtk-1-3-win32-production and gtk-2-0: * gdk/win32/gdkinput-win32.c (gdk_input_init): Use GetSystemMetrics (SM_C[XY]SCREEN) instead of gdk_screen_{width,height}(). * gdk/win32/gdkselection-win32.c (gdk_selection_convert): Don't use return value from GlobalSize() as length of string when calling MultiByteToWideChar(). Pass -1 instead (zero-terminated string). Thanks to Iwasa Kazmi.
* Use correct function name in warning messages.Tor Lillqvist2002-09-111-2/+2
| | | | | | | 2002-09-12 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkinput-win32.c (gdk_input_wintab_init): Use correct function name in warning messages.
* Fix args to pango_x_shutdown_display().Owen Taylor2002-08-021-4/+4
| | | | | | | | | | | | | | | Fri Aug 2 15:56:47 2002 Owen Taylor <otaylor@redhat.com> * gdk/x11/gdkscreen-x11.c (gdk_screen_x11_dispose): Fix args to pango_x_shutdown_display(). * gdk/linux-fb/gdkinput.c gdk/linux-fb/gdkinputprivate.h gdk/win32/gdkinput-win32.[ch] gdk/win32/gdkinput.c gdk/win32/gdkwindow-win32.c gdk/x11/gdkinput-x11.c gdk/x11/gdkinput-xfree.c gdk/x11/gdkinput.c gdk/x11/gdkinputprivate.h gdk/x11/gdkwindow-x11.c: Move a bunch of functions gdk_input => _gdk_input. Clean up some header file cruft. (#79971)
* Make the core pointer object per-display. (#85698)Owen Taylor2002-06-181-1/+1
| | | | | | | | | | Tue Jun 18 19:11:51 2002 Owen Taylor <otaylor@redhat.com> * gdk/gdkdisplay.[ch] gdk/gdkevents.c gdk/gdkinput.h gdk/gdkinternals.h gdk/win32/gdkevents-win32.c gdk/win32/gdkinput-win32.[ch] gdk/x11/gdkevents-x11.c gdk/x11/gdkinput{,-none,-x11}.c gdk/x11/gdkinputprivate.h: Make the core pointer object per-display. (#85698)
* Changes multihead reorganizing code for win32 support, mostly from a patchOwen Taylor2002-06-061-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Wed Jun 5 18:34:47 2002 Owen Taylor <otaylor@redhat.com> Changes multihead reorganizing code for win32 support, mostly from a patch by Hans Breuer. * gdk/gdkcolor.c gdk/x11/gdkcolor-x11.c gdk/gdkcursor.c gdk/x11/gdkcursor-x11.c gdk/gdkevents.c gdk/x11/gdkevents-x11.c gdk/gdkfont.c gdk/x11/gdkfont-x11.c gdk/gdkkeys.c gdk/x11/gdkkeys-x11.c gdk/gdkimage.c gdk/x11/gdkimage-x11.c gdk/gdkscreen.c gdk/x11/gdkmain-x11.c gdk/gdkdisplay.c gdk/gdkevents-x11.c gdk/gdkpango.c gdk/x11/gdkpango-x11.c gdk/gdkselection.c gdk/x11/gdkselection-x11.c gdk/gdkwindow.c gdk/x11/gdkwindow-x11.c gdk/gdkvisual.c gdk/x11/gdkvisual-x11.c: Move port-independent singlehead wrapper functions into port-independent part of GDK. (#80009) * gdk/win32/gdkcolor-win32.c gdk/win32/gdkcursor-win32.c gdk/win32/gdkevents-win32.c gdk/win32/gdkfont-win32.c gdk/win32/gdkimage-win32.c gdk/win32/gdkkeys-win32.c gdk/win32/gdkmain-win32.c gdk/win32/gdkproperty-win32.c gdk/win32/gdkselection-win32.c gdk/win32/gkwindow-win32.c: Turn singlehead functions into "multihead" functions that ignore their GdkDisplay or GdkScreen arguments. * gdk/win32/gdkdrawable-win32.c gdk/win32/gdkevents-win32.c gdk/win32/gdkinput-win32.c gdk/win32/gdkprivate-win32.h: Misc multihead-compatibility changes. * gtk/gtk.def gdk/gdk.def: Update for multihead functions. * gdk/gdkcolormap.h gdk/gdkvisual.h gdk/x11/gdkcolormap-x11.c gdk/x11/gdkvisual-x11.c: Remove the screen fields from the public parts of the colormap/visual structures, add accessors instead. * gdk/gdkpixbuf-render.c gdk/gdkpixmap.c gdk/gdkrgb.c gdk/x11/gdkcolormap-x11.c gdk/x11/gdkimage-x11.c gdk/x11/gdkimage-x11.c gdk/x11/gdkprivate-x11.h gtk/gtkgc.c gtk/gtkstyle.c gtk/gtkwidget.c: Use accessors to get the screen for colormaps, visuals; move the fields into the private structures for the x11 backend. * gdk/gdkdisplay.[ch] gdk/x11/gdkdisplay-x11.[ch] gdk/gdkscreen.[ch] gdk/x11/gdkscreen-x11.c: Remove virtualization of screen and display functions. (#79990, patch from Erwann Chenede) * gdk/win32/gdkdisplay-x11.c gdk/win32/gdkscreen-win32.c gdk/win32/{Makefile.am, makefile.msc, makefile.mingw}: New files containing stub implementations of Display, Screen functions. * gdk/x11/gdkscreen-x11.[ch] gdk/x11/gdkdisplay-x11.[ch] gdk/x11/gdkx.h: Clean up function exports and what headers they are in. (#79954) * gdk/x11/gdkx.h: Fix macro that was referring to a non-existant screen->screen_num. (In the patch for #79972, Erwann Chenede) * gdk/gdkscreen.c gdk/gdkwindow.c gdk/x11/gdkinternals.h gdk/x11/gdkscreen-x11.c: Fix gdk_screen_get_window_at_pointer() to use window hooks. (#79972, patch partly from Erwann Chenede) * gdk/x11/gdkdisplay-x11.c gdk/x11/gdkevents-x11.c: Fix some warnings.
* Bypass calls to the grab/ungrab functions in gdkinput-win32.c, as theyTor Lillqvist2002-03-061-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-03-06 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkevents-win32.c (gdk_pointer_grab, gdk_pointer_ungrab): Bypass calls to the grab/ungrab functions in gdkinput-win32.c, as they don't effectively do anything anyway. (build_key_event_state): Set MOD2 bit if key is in AltGr group. (gdk_event_translate): Call _gdk_windowing_window_get_offsets() each time the offsets are used, on the window they refer to, instead of once in the beginning. The window in question might change due to event propagation. (gdk_event_translate): Set key event group to 0 for non-AltGr keys. Do set the SHIFT bit in the key event state also for ISO_Left_Tab. Now backtabbing finally works again. * gdk/win32/gdkunput-win32.c: Minor debugging output change. * gdk/win32/gdkkeys-win32.c (update_keymap): Set VK_TAB mapping to Gdk_Tab and GDK_ISO_Left_Tab, like on X11. (gdk_keymap_translate_keyboard_state): Add similar code as in the non-XKB case on X11 to generate a more correct consumed_modifiers. Add debugging output. (gdk_keyval_name): Use the U+xxxx format for UCS characters encoded as keyvals. Never return NULL, but hex number representation if keyval not in table. * gdk/win32/gdkwindow-win32.c (gdk_window_focus): Call SetFocus(). Doesn't seem to have any harmful effect, and probably is close to what this function is supposed to do. But it didn't fix GtkCombo as I had hoped. (gdk_window_set_type_hint): Don't intern the _NET_WM_* atoms that weren't used and wouldn't have any meaning on Win32 anyway.
* process WM_PAINT messages for bg_pixmap == GDK_NO_BG, fixes The GIMP'sHans Breuer2002-02-181-1/+1
| | | | | | | | | | | | | | | | | | 2002-02-18 Hans Breuer <hans@breuer.org> * gdk/win32/gdkevents-win32.c : process WM_PAINT messages for bg_pixmap == GDK_NO_BG, fixes The GIMP's canvas rendering glitches on win32 * gdk/win32/gdkinput-win32.c : use g_object_new to create GdkDevice instead of g_new * gtk/gtkpaned.c : make LAST_SIGNAL the last in enum. This avoids to smash totally unrelated static data and resulting random crashes. (as reported on gtk-devel-list, 2002-02-10 : testgtk crashes) * gtk/gtk.def : add new file selection entry points
* Massive changes. Too many to list here, but I'll try a summary:Tor Lillqvist2002-02-171-35/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-02-17 Tor Lillqvist <tml@iki.fi> * gdk/win32/*.c: Massive changes. Too many to list here, but I'll try a summary: 1) Unify GdkPixmap and GdkImage implementation: For each GdkPixmap, allocate a GdkImage, and vice versa. GdkPixmapImplWin32Data has a pointer to the GdkImage. GdkImage::windowing_data is a pointer to the GdkPixmap. This simplifies many pixmap and image related functions a lot, and reduces duplicated code snippets. For instance, there is only one place in gdk/win32 where CreateDIBSection() is called, in the function _gdk_win32_new_pixmap(). Converting a bitmap (GdkPixmap) to a Windows region is almost trivial, with the bitmap bits being readily accessible in the associated GdkImage. All blitting between GdkPixmaps, GdkWindows and GdkImages goes through handled the _gdk_win32_blit() function, which calls different functions to handle the cases of blitting from pixmaps, inside windows (scrolling), or from windows, which all require somewhat different handling. 2) Support 256-color mode. This has long been very broken, now it works more or less OK. Keep the logical palette for each colormap as small as possible while allocating and freeing colors. Select and realize the logical palette associated with a GdkColormap into a DC before drawing or blitting. When the display is in 256-color mode, make it possible for the user to override the size of the palette(s) used with either the GDK_WIN32_MAX_COLORS environment variable, or a -max-colors command line option. It is possible to reduce the palette size all the way down to using just the 16 static colors (which causes the system visual to be of type GDK_VISUAL_STATIC_COLOR. This could possibly be useful if one desperately wants to avoid color flashing. (Note that in order for this to work properly, an as of yet not commited fix to gdkrgb.c is needed.) Handle the palette messages. On WM_PALETTECHANGED, call UpdateColors() for the given window hierarchy. Do this only if a window in some other top-level window hierarchy caused the palette change (realized a palette). Do this max five times in a row (an arbitrarily chosen limit), though, otherwise redraw by generating expose events. On WM_QUERYNEWPALETTE, cause a redraw of the whole window hierarchy by generating GDK_EXPOSE events. 3) Code cleanup in general. For instance, remove the "emulated" X11 structs ColormapStruct, Visual and XStandardColormap. Use the new GDK_DEBUG_* flags for debugging output in the relevant source files. Remove the unused colormap hash table in gdkcolor-win32.c 4) Plug some resource leaks. 2002-02-14 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkdnd-win32.c (gdk_dropfiles_filter): Use g_filename_to_uri() to actually create legal URIs in the text/uri-list data.
* Append EXEEXT to ../gdk-pixbuf/gdk-pixbuf-csource.Tor Lillqvist2002-01-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | 2002-01-01 Tor Lillqvist <tml@iki.fi> * demos/Makefile.am (test-inline-pixbufs.h): Append EXEEXT to ../gdk-pixbuf/gdk-pixbuf-csource. 2001-12-31 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkgc-win32.c (predraw_set_foreground): Improved error handling. (gdk_win32_hdc_get,gdk_win32_hdc_release): Silence gcc -Wall. * gdk/win32/gdkimage-win32.c (_gdk_win32_get_image): Silence gcc -Wall. Use GDK_IS_PIXMAP_IMPL_WIN32 instead of GDK_IS_PIXMAP in one more place. * gdk/win32/gdkinput-win32.c (_gdk_input_other_event): Silence gcc -Wall. * gtk/Makefile.am (libgtk_win32_1_3_la_LDFLAGS): Add -lwsock32.
* Make gdkx.h the only installed header from gdk/x11. All structures inOwen Taylor2001-09-071-21/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fri Sep 7 11:51:44 2001 Owen Taylor <otaylor@redhat.com> Make gdkx.h the only installed header from gdk/x11. All structures in gdk/x11 are opaque. * gdk/x11/Makefile.am gdk/x11/gdkx.h gdk/x11/gdkprivate-x11.h: Don't install gdk{drawable,pixmap,window}-x11.h. * gdk/x11/{gdkcolormap-x11.c, gdkfont-x11.c, gdkx.h, gdkvisual-x11.c: Move GdkColormapPrivateX11, GdkFontPrivateX GdkImagePrivateX11, GdkVisualClass into C files. * gdk/gdkpixmap-x11.[ch]: Make gdk_pixmap_impl_get_type() static. * gdk/x11/{gdkcolor-x11.c, gdkcursor-x11.c, gdkdrawable-x11.c, gdkfont-x11.c, gdkgc-x11.c, gdkx.h, gdkimage-x11,gdkvisual-x11.c} Add public functions to replace previously exported direct structure access. gdk_x11_colormap_get_{xdisplay,xcolormap} gdk_x11_cursor_get_{xdisplay,xcursor}, gdk_x11_drawable_get_{xdisplay,xcursor,gdk_x11_visual_get_xvisual, gdk_x11_font_get_{xdisplay,xfont}, gdk_x11_image_get_{xdisplay,ximage}, gdk_x11_gc_get_{xdisplay,ximage} * gdk/gdkprivate.h gdk/gdkinternals.h: Move GdkColorInfo, GdkEventFilter, GdkClientFilter, GdkFontPrivate to gdkinternals. Fix a number of variables and functions that were exported "accidentally" from GDK. * gdk/**.[ch]: gdk => _gdk for gdk_visual_init, gdk_events_init, gdk_input_init, gdk_dnd_init, gdk_image_exit, gdk_input_exit, gdk_windowing_exit, gdk_event_func, gdk_event_data, gdk_event_notify, gdk_queued_events, gdk_queued_tail, gdk_event_new, gdk_events_queue, gdk_events_unqueue, gdk_event_queue_find_first, gdk_event_queue_remove_link, gdk_event_queue_append, gdk_event_button_generate, gdk_debug_flags, gdk_default_filters, gdk_parent_root. * gdk/x11/{gdkevents-x11.c, gdkglobals-x11.c, gdkimage-x11.c, gdkmain-x11.c, gdkprivate-x11.h, gdk/x11/gdkwindow-x11.c}: gdk => _gdk for gdk_event_mask_table, gkd_nevent_masks, gdk_wm_window_protocols, gdk_leader_window, gdk_xgrab_window, gdk_use_xshm, gdk_input_ignore_core. * gdk/x11/xsettings-common.h (xsettings_list_insert): Add #defines to namespace functions into the private _gdk_ namespace. * gdk/gdkwindow.[ch] gdk/x11/gdkx.h: Add gdk_get_default_root_window () to replace gdk_parent_root exported variable. Adjust and deprecate GDK_ROOT_PARENT(). * demos/{testpixbuf-drawable.c,testpixbuf-save.c}: Fix GDK_ROOT_PARENT usage, remove includes of port-specific headers. * gdk/{win32,x11,fb}/gdkinput*.[ch]: s/gdk/_gdk/ for _gdk_input_gxid_host, _gdk_input_gxid_port, _gdk_input_ignore_core, gdk_input_devices, _gdk_input_windows, gdk_init_input_core. * gdk/x11/{gdkevents-x11.,c gdkglobals-x11.c, gdkmain-x11.c} docs/Changes-2.0.txt: Remove gdk_wm_protocols, gdk_wm_delete_window functions, gdk_wm_take_focus, use gdk_atom_intern() instead. * gdk/linux-fb/{gdkselection-fb.c, gdkmain-fb.c, gdkprivatefb.h} gdk/win32/{gdkselection-win32.c, gdkmgdkwin32.h, gdkprivate-win32.h} gdk/x11/{gdkselection-x11.c gdkx.h, gtkprivate-x11.h} gtk/gtkselection.c Unexport gdk_selection_property, just use gdk_atom_intern ("GDK_SELECTION"). * gdk/x11/{gdkprivate-x11.h,gdkdrawable-x11h,gdkgc-x11.c,gdkx.h}: Unexport gdk_drawable_impl_x11_get_type, gdk_gc_x11_get_type, GDK_GC_X11 cast macros, GdkGCX11 structures, GdkCursorPrivate, GdkVisualprivate, gdk_x11_gc_flush. Make a number of public exports of variables into functions to increase encapsulation. * gdk/gdkinternals.h gdk/gdkinput.h gdk/gdkevents.h gdk/linux-fb/gdkmouse-fb.c: gdk_core_pointer => _gdk_core_pointer, move to gdkinternals.h. Add gdk_device_get_core_pointer (). * gdk/gdkprivate.h gdk/gdkpango.c gdk/gdkinternals.h docs/Changes-2.0.txt: Unexport gdk_parent_root, gdk_error_code, gdk_error_warnings. * gdk/x11/{gdkcolormap-x11.c, gdkmain-x11.c, gdkx.h} docs/Changes-2.0.txt: s/gdk_screen/_gdk_screen/, add gdk_x11_get_default_screen() s/gdk_root_window/_gdk_root_window/, add gdk_x11_get_default_root_xwindow() Add gdk_x11_get_default_xdisplay(). * gdk/gdk.h gdk/gdk.c linux-fb/gdkfb.h linux-fb/gdkglobals-fb.c win32/gdkwin32.h x11/gdkglobals-x11.c gdk/x11/gdkmain-x11.c gdk/x11/gdkx.h: gdk/gdk.def: Add gdk_get/set_program_class, Don't export gdk_progclass, move --class command line option and handling to common portion of GDK. Miscellaneous fixes: * gdk/x11/gdkwindow-x11.c (gdk_window_set_icon_list): Fix g_return_val_if_fail that should have been g_return_if_fail. * gdk/gdkinternals.h gdk/gdkprivate.h: Move gdk_synthesize_window_state() to the semi-public gdkprivate.h. * gtk/gtkdnd.c (_gtk_drag_source_handle_event): Remove uneeded X11 dependency. * gdk/linux-fb/gdkmain-fb.c gdk/win32/gdkmain-win32.c gdk/TODO: Remove unused gdk_key_repeat_disable/restore. * linux-fb/gdkglobals-fb.c win32/gdkglobals-win32.c x11/gdkglobals-x11.c x11/gdkprivate-x11.h gdk/gdk.def: Remove unused gdk_null_window_warnings variable. * gdk/Makefile.am (DIST_SUBDIRS) nanox/*: cvs remove nanox; it can be retrieved from the repository; it is too far from functional to be worth having people check out; it would be easier to start from scratch, I suspect. * gdk/x11/gdkpixmap-x11.c: Fix lvalue usage of GDK_PIXMAP_XID(). * gdk/x11/gdkkeys-x11.c gdk/gdkrgb.c gdk/gdkwindow.c gdk/x11/gdkpango-x11.c gdk/x11/gdkselection-x11.c: Fix some accidentally global variables and unused global variables. * gdk/x11/gdkkeys-x11.c gdk/gdkrgb.c gdk/gdkwindow.c gdk/x11/gdkpango-x11.c gdk/x11/gdkselection-x11.c: Fix some accidentally global variables and unused global variables. Add some space for future expansion to multihead. * gdk/gdkdrawable.h: Add four reserved function pointers for future expansion of GdkDrawableClass. * gtk/gtkwindow.h gtk/gtkinvisible.h: Add reserved pointer where we can put a GdkScreen * later.
* gdk_device_get_history moved to gdk/gdkinput.c like the other backendsHans Breuer2001-07-201-26/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-07-20 Hans Breuer <hans@breuer.org> * gdk/win32/gdkinput-win32.c : gdk_device_get_history moved to gdk/gdkinput.c like the other backends * gdk/win32/gdkinput-win32.h : * gdk/win32/gdkinput.c : * gdk/win32/gdkvisual-win32.c : * gdk/win32/gdkwin32.h : mechanical adaption to GdkDevice and GdkVisual GObjectification. UNTESTED for pen-devices because I simply have none. * gdk/gdk.def : * gtk/gtk.def : updated externals * gtk/gtkiconfactory.c : * gtk/gtkoldeditable.c : GError *error needs to be initialized (= NULL) before passing &error to functions to avoid strange crashes * gtk/gtkcontainer.c (gtk_container_real_set_focus_child) : is static * gtk/gtkwidget.c (gtk_widget_get_child_visible): use g_return_val_if_fail * gtk/makefile.msc.in : updated
* Include x11/gdkx.h only when building for X11.Tor Lillqvist2000-10-251-14/+11
| | | | | | | | | | | | | | | | | | 2000-10-25 Tor Lillqvist <tml@iki.fi> * gdk/gdkwindow.c: Include x11/gdkx.h only when building for X11. * gdk/win32/gdkdrawable-win32.c * gdk/win32/gdkimage-win32.c * gdk/win32/gdkprivate-win32.h: Corresponding changes as in the X11 backend. * gdk/win32/gdkcc-win32.c * gdk/win32/gdkcolor-win32.c * gdk/win32/gdkfont-win32.c * gdk/win32/gdkinput-win32.c * gdk/win32/gdkmain-win32.c * gdk/win32/gdkproperty-win32.c: Silence gcc -Wall.
* Update.Tor Lillqvist2000-10-091-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-09 Tor Lillqvist <tml@iki.fi> * README.win32: Update. * gdk/win32/gdkgeometry-win32.c (gdk_window_clip_changed): Add two lines that had been deleted by mistake (?). * gdk/win32/gdkcursor-win32.c (gdk_cursor_new_from_pixmap): Handle also the case fg==white and bg==black (but still not randomly coloured cursors). Thanks to Wolfgang Sourdeau. * gdk/win32/*.c: Silence gcc -Wall. * gtk/gtk.def: Add missing entry points. Fixes by Hans Breuer: * gdk/makefile.msc * gdk/win32/makefile.msc: Update. * gdk/testgdk.c: If compiling with debugging (with _DEBUG defined, some MSVC thing, presumably), cause breakpoint on failures. Add GDK_NOR case. Call g_log_set_always_fatal. * gdk/win32/gdkwin32id.c (gdk_win32_handle_table_insert): Handle should be pased by reference. * gdk/win32/gdkprivate-win32.h: Correct declaration accordingly. * gdk/win32/*.c: Correct calls to gdk_win32_handle_table_insert. * gdk/win32/gdkevents-win32.c * gdk/win32/gdkwindow-win32.c: Handle WM_CREATE. * gdk/win32/gdkgc-win32.c: Fix mixups of drawable and implementation object. * gdk/win32/gdkimage-win32.c (gdk_image_get): Handle drawables, not just windows. * gdk/win32/gdkpixmap-win32.c (gdk_pixmap_impl_win32_finalize): Use the wrapper object.
* gdk/gdk.def Add missing entries.Tor Lillqvist2000-08-121-0/+67
| | | | | | | | | | | | | | | | | | | | 2000-08-12 Tor Lillqvist <tml@iki.fi> * gdk/gdk.def * gtk/gtk.def: Add missing entries. * gdk/win32/gdkfont-win32.c (gdk_font_load_internal): Use OUT_TT_ONLY_PRECIS, try to get a TrueType font. * gdk/win32/gdkinput-win32.c (gdk_device_get_state): New function. Dummy implementation at this point. * gtk/makefile.mingw.in: Fix typo. Add testtext and testtextbuffer rules. Undefine GTK_COMPILATION when compiling the test programs. * gtk/gtkdebug.h: Mark gtk_debug_flags for export/import. * gdk_pixbuf.def: Add missing entry point.
* applied patch from Andreas Persenius <ndap@swipnet.se> that updates theTim Janik2000-07-261-4/+4
| | | | | | | | Wed Jul 26 12:59:31 2000 Tim Janik <timj@gtk.org> * *.[hc]: applied patch from Andreas Persenius <ndap@swipnet.se> that updates the license headers to the GNU Lesser General Public License, as well as updating the copyright year to 2000.
* Generate gtk/makefile.mingw.Tor Lillqvist2000-07-251-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-07-25 Tor Lillqvist <tml@iki.fi> * configure.in: Generate gtk/makefile.mingw. * config.h.win32: Add GETTEXT_PACKAGE. * gdk/gdk.def * gtk/gtk.def: Updates. * gdk/gdkfont.h * gdk/gdkpixmap.h: Remove temporary Win32-only functions, we don't need them any longer. * gdk/gdkinput.h: Mark gdk_core_pointer for export/import. * gdk/win32/*.c: More work. * gdk/win32/gdkpango-win32.c: New file. * gtk/makefile.mingw.in: New file * gtk/makefile.cygwin: Removed * gtk/Makefile.am: Update accordingly. * gtk/gtkmain.c: Use gtk_win32_get_installation_directory(). * gtk/gtktextdisplay.c: No need to include pangox.h, pango.h is enough. * gtk/gtktypeutils.c: Mark glib_debug_objects for import.
* Include the build directory.Tor Lillqvist2000-07-251-801/+298
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-07-25 Tor Lillqvist <tml@iki.fi> * Makefile.am: Include the build directory. * configure.in: Generate build/Makefile and build/win32/Makefile. * config.h.win32: Add USE_GMODULE and USE_MMX for gdk-pixbuf. * gdk/gdk.def * gtk/gtk.def: Updates. * gdk/makefile.mingw.in: Define GDK_COMPILATION. Link with PANGOWIN32_LIBS and gdk_pixbuf. * gdk/win32: Compiles, but no doubt doesn't work at all. * gdk/win32/makefile.mingw.in: Define GDK_COMPILATION. * gdk/win32/gdkinput.c: New file, temporarily. * gdk/win32/gdkinput-win32.h: New file * gdk/win32/gdkinputprivate.h: Remove. * gtk/gtkrc.[ch] (gtk_win32_get_installation_directory): Renamed and made externally visible.
* Patch from George Liebl to add a GdkGrabStatus enumeration to use as aOwen Taylor2000-07-061-2/+2
| | | | | | | | | | | | | Thu Jul 6 11:54:03 2000 Owen Taylor <otaylor@redhat.com> * gdk/gdk.h gdk/gdktypes.h gdk/linux-fb/gdkmain-fb.c gdk/nanox/gdkmain-nanox.c gdk/win32/gdkevents-win32.c gdk/win32/gdkinput-win32.c gdk/win32/gdkwin32.h gdk/x11/gdkmain-x11.c: Patch from George Liebl to add a GdkGrabStatus enumeration to use as a return value of gdk_*_grab(). Previously, we just returned the X11 values directly.
* Large changes to the Win32 backend, partially made necessary by theTor Lillqvist2000-05-011-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-05-02 Tor Lillqvist <tml@iki.fi> Large changes to the Win32 backend, partially made necessary by the changes to the backend-independent internal structures. Attempts to implement similar backing store stuff as on X11. The current (CVS) version of the Win32 backend is *not* as stable as it was before the no-flicker branch was merged. A zipfile with that version is available from http://www.gimp.org/win32/. That should be use by "production" code until this CVS version is usable. (But note, the Win32 backend has never been claimed to be "production quality".) * README.win32: Add the above comment about versions. * gdk/gdkwindow.c: Don't use backing store for now on Win32. * gdk/gdk.def: Update. * gdk/gdkfont.h: Declare temporary Win32-only functions. Will presumably be replaced by some more better mechanism as 1.4 gets closer to release shape. * gdk/makefile.{cygwin,msc}: Update. * gdk/win32/*.c: Correct inclusions of the backend-specific and internal headers. Change code according to changes in these. Use gdk_drawable_*, not gdk_window_* where necessary. * gdk/win32/gdkdnd-win32.c: Use MISC selector for GDK_NOTE, not our old DND. * gdk/win32/gdkdrawable-win32.c (gdk_win32_draw_text): Don't try to interpret single characters as UTF-8. Thanks to Hans Breuer. Use correct function name in warning messages. * gdk/win32/gdkevents-win32.c: Use correct parameter lists for the GSourceFuncs gdk_event_prepare and gdk_event_check. (gdk_event_get_graphics_expose): Do implement, use PeekMessage. Thanks to Hans Breuer. (event_mask_string): Debugging function to print an GdkEventMask. (gdk_pointer_grab): Use it. * gdk/win32/gdkfont-win32.c: The Unicode subrange that the (old) book I used claimed was Hangul actually is CJK Unified Ideographs Extension A. Also, Hangul Syllables were missing. Improve logging. * gdk/win32/gdkgc-win32.c: Largish changes. * gdk/win32/gdkim-win32.c (gdk_set_locale): Use g_win32_getlocale() from GLib, and not setlocale() to get current locale name. * gdk/win32/gdkprivate-win32.h * gdk/win32/gdkwin32.h: Move stuff from gdkprivate-win32.h to gdkwin32.h, similarily as in the X11 backend. * gdk/win32/gdkwindow-win32.c (gdk_propagate_shapes): Bugfix, assignment was used instead of equals in if test. Thanks to Hans Breuer. * gdk/win32/makefile.{cygwin,msc} * gtk/makefile.{cygwin,msc}: Updates. Better kludge to get the path to the Win32 headers that works also with the mingw compiler. * gtk/gtkstyle.c: Include <string.h>.
* gdk/win32/gdkprivate-win32.h gdk/win32/gdkevents-win32.cTor Lillqvist1999-12-301-1/+1
| | | | | | | | | | | | 1999-12-30 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkprivate-win32.h * gdk/win32/gdkevents-win32.c * gdk/win32/gdkinput-win32.c * gdk/win32/gdkwindow-win32.c: Remove the superfluous extension_events field in the GdkWindowWin32Data struct. Use only the extension_events field in GdkWindowPrivate. Previously one was set, and the other one tested, which broke tablet functionality.
* Must mark also gdk_error_warnings and gdk_error_code as GDKVAR, as theyTor Lillqvist1999-12-111-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | 1999-12-11 Tor Lillqvist <tml@iki.fi> * gdk/gdkprivate.h: Must mark also gdk_error_warnings and gdk_error_code as GDKVAR, as they are referred outside GDK. * gdk/win32/gdkinput-win32.c: Remove debugging leftover. * gdk/win32/gdkwindow-win32.c (gdk_window_new): Assure title is non-NULL. * gtk/gtkdnd.c * gtk/gtklayout.c * gtk/gtkplug.c * gtk/gtkselection.c * gtk/gtksocket.c * gtk/gtkwindow.c: Include x11/gdkx.h *or* win32/gdkwin32.c as appropriate. There must be a cleaner way to handle this? * gtk/gtkrc.c: Must include windows.h on Win32. * gtk/testgtk.c: No need to include gdkx.h. * gtk/makefile.cygwin: Correct invokation of genmarshal.pl.
* Further hacking. Now actually compiles. Haven't tried yet whetherTor Lillqvist1999-11-201-34/+20
| | | | actually does anything useful... Time for bed.
* Intermediate commit. I go to bed now.Tor Lillqvist1999-11-171-1/+4
|
* re-adding for manual rename of repository files.Tor Lillqvist1999-11-111-0/+1685
|
* Just renamed the Win32 backend files to *-win32.Tor Lillqvist1999-11-101-1685/+0
|
* Add new keysyms from X11R6.4 (including EuroSign).Tor Lillqvist1999-10-311-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1999-10-31 Tor Lillqvist <tml@iki.fi> * gdk/gdkkeysyms.h: Add new keysyms from X11R6.4 (including EuroSign). * gdk/gdktypes.h: Add note about wchar_t not necessarily being the same type as GdkWChar, especially on Win32. * gdk/win32/*.c: Change gdk_root_parent to be a pointer. * gdk/win32/*.c: Assume all strings are UTF-8. Convert to Unicode before passing to Windows GDI for drawing etc. Convert to the system default codepage before passing to Windows as window titles. * gdk/win32/gdkprivate.h: Add more fields to GdkWindowPrivate to support changing input locale on the fly. * gdk/win32/gdkevent.c: Support input language (keyboard locale) on-the-fly changes. Convert incoming characters from the current codepage to Unicode (and then to a UTF-8 multi-byte string) based on the current input language. Use keysym<->Unicode mapping tables and functions borrowed from xterm sources. Support IMEs (Input Method Editors) for CJK languages. On non-CJK editions of Win9x, use the ActiveX-based Active IMM (Input Method Manager) if available. IMEs and the Active IMM are available under the disguise of Chinese, Korean and Japanese support for IE and Outlook Express from "Windows Update" for Win98. On Win2k, the CJK support is present in all editions (as long as you install it). Call DispatchMessage from gdk_events_queue() (and thus gdk_WindowProc()), instead of duplicating the code in gdk_WindowProc(). Reworked the grab handling and propagation code, factored out duplicated code snippets into separate functions. Other cleanups, too. * gdk/win32/surrogate-dimm.h: Provide just the bits we need from the <dimm.h> header describing the Active IMM. * gdk/win32/gdkfont.c: Pretend to support fontsets, but so far just do the same as for "single" fonts. * gdk/win32/gdk.c: Call CoInitialize() (COM initialisation) from gdk_init_check, and CoUninitialize() from gdk_exit_func. Handle the new keysyms from gdkkeysyms.h. * gtk/gtkfontsel.c (Win32): Load the font for the preview as a fontset, so that gtkentry uses wide characters. * gtk/gtkrc.c (Win32): Get the locale with gwin_getlocale(). Call GTk+'s system directory "gtk+", not "gtk".
* Corresponding changes as in X11 backend.Tor Lillqvist1999-10-051-22/+19
| | | | | | | | | | | | | | | 1999-10-05 Tor Lillqvist <tml@iki.fi> * gdk/win32/*.[ch]: Corresponding changes as in X11 backend. * gdk/win32/gdkcompat.c: New file, actually provide an implementation for the deprecated functions. (Just temporarily.) * gtk/gtkfilesel.c: Fix an #ifdef syntax botch. * gtk/makefile.{cygwin,msc}: Update gdk_headers. * gdk/win32/gdk.def gtk/gtk.def: Updates.
* A few includes added for the picky MSVC compiler.Tor Lillqvist1999-10-021-0/+1
|
* Change GDK_WINDOWING_WIN32 usage to #ifdef also here.Tor Lillqvist1999-10-021-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | 1999-10-03 Tor Lillqvist <tml@iki.fi> * gdk/gdkimage.h gdk/gdkpixmap.h: Change GDK_WINDOWING_WIN32 usage to #ifdef also here. * gdk/win32/*.h gdk/win32/*.c: Make corresponding changes as those Owen did to the X11 backend. * gdk/win32/gdkdraw.c (gdk_draw_pixmap): Fix it again, don't use ScrollWindowEx when blitting inside a window, it can't be correct in the general case. * gdk/win32/gdkevents.c: Don't handle WM_SIZING, handling WM_GETMINMAXINFO is easier. * gdk/win32/gdkimage.c (gdk_image_new): Create new image with depth equal to the bitspixel value, not the visual's depth. * gdk/win32/gdkvisual.c (gdk_visual_init): Set the visual's depth to 24 even if the bitspixel value is 32. * gdk/gdkrgb.c (gdk_rgb_select_conv): After the above change, no need to check for depth==32 when bpp==32, depth will always be 24.
* README.win32 Add HAVE_WINTAB. Undefine it if bulding without the WintabTor Lillqvist1999-07-251-153/+305
| | | | | | | | | | | | | | | | | | | * README.win32 * config.h.win32: Add HAVE_WINTAB. Undefine it if bulding without the Wintab SDK. * gdk/win32/gdkinput.c: Hack some more. Still doesn't quite work OK, but getting closer. Guard against bogus tilt data from Wacom ArtPad II with the 3.40 driver. Add ifdefs for HAVE_WINTAB to enable easier building without Wintab. * gdk/win32/gdkinput.h * gdk/win32/gdkevents.c * gdk/win32/gdkwindow.c: Minor changes related related to above. * gdk/win32/gdkvisual.c: Simplify a lot, remove leftovers from X11 code. As we have just one visual on Win32, no sense to have it in a table, and no need for the hash table.