Commit Graph

11 Commits

Author SHA1 Message Date
3
c181cd8efc Don't leak built-in cursors.
2001-01-23    <alexl@redhat.com>

        * linux-fb/gdkcursor-fb.c:
	Don't leak built-in cursors.

	* linux-fb/gdkdrawable-fb2.c (gdk_fb_draw_polygon):
	Don't leak tmp_points.

	* linux-fb/gdkfont-fb.c (gdk_font_from_description):
	Don't modify desc. Don't leak font if the PangoFont
	isn't found.

	* linux-fb/gdkgc-fb.c (gdk_fb_gc_finalize):
	Free dash_list.

	* linux-fb/gdkkeyboard-fb.c (gdk_fb_handle_key):
	Don't leak string.
2001-01-23 14:37:54 +00:00
Alexander Larsson
b29eece81f Added ENABLE_SHADOW_FB
2001-01-11  Alexander Larsson  <alexl@redhat.com>

	* acconfig.h:
	Added ENABLE_SHADOW_FB

	* configure.in:
	Added --disable-shadowfb

	* gdk/linux-fb/gdkcursor-fb.c:
	Update shadowfb when updating cursor

	* gdk/linux-fb/gdkdrawable-fb2.c:
	Added wrappers for shadowfb that calls 	the normal drawable
	methods, but calls gdk_shadow_fb_update(bounding box) when
	GdkWindows are drawed to.
	Moved gdk_draw_glyphs implementation to _gdk_draw_glyphs
	which also returns the bounding box.

	* gdk/linux-fb/gdkfb.h:
	Added GdkFBAngle type and gdk_fb_set_rotation declaration.

	* gdk/linux-fb/gdkgeometry-fb.c:
	Update shadowfb when scrolling window.

	* gdk/linux-fb/gdkglobals-fb.c:
	Add _gdk_fb_screen_angle.

	* gdk/linux-fb/gdkkeyboard-fb.c:
	Test code for screen rotation. Shift-F2 in the xlate driver
	rotates the screen.

	* gdk/linux-fb/gdkmain-fb.c:
	Handle shadowfb. Add gdk_fb_set_rotation(). Remove CM and RP.

	* gdk/linux-fb/gdkmouse-fb.c:
	Use fb_width/height instead of modeinfo.xres/yres.

	* gdk/linux-fb/gdkprivate-fb.h:
	Added fb_men, fb_width, fb_height & fb_stride. When using
	shadow fb these can differ from the framebuffer stuff.
	Declarations for gdk_shadow_fb_update, gdk_shadow_fb_init,
	gdk_shadow_fb_stop_updates, gdk_fb_recompute_all,
	_gdk_fb_screen_angle. Removed CM, RP.

	* gdk/linux-fb/gdkrender-fb.c:
	Added code for shadowfb handling and screen rotation using
	shadowfb.

	* gdk/linux-fb/gdkwindow-fb.c:
	Use fb_mem, fb_stride, fb_width, fb_height.
	Added recompute_rowstride to reset the rowstride of all windows.
	Added gdk_fb_recompute_all() which recomputes rootwindow size,
	window abs positions and window rowstrides. Usefull when the
	rotation has changed.
2001-01-11 16:39:21 +00:00
Alexander Larsson
6d0c6b792e New file containing the abstracted keyboard driver. Most code taken from
2000-12-08  Alexander Larsson  <alla@lysator.liu.se>

	* gdk/linux-fb/gdkkeyboard-fb.c:
	New file containing the abstracted keyboard driver. Most code
	taken from gdkinput-ps2.c

	* gdk/linux-fb/gdkinput-ps2.c:
	Removed file.

	* gdk/linux-fb/Makefile.am:
	Added gdkkeyboard-fb.c, removed gdkinput-ps2.c.

	* gdk/linux-fb/gdkcolor-fb.c:
	display->fb was renamed to display->fb_fd.

	* gdk/linux-fb/gdkcursor-fb.c:
	gdk_mouse_get_info -> gdk_fb_mouse_get_info

	* gdk/linux-fb/gdkinput.c:
	Moved gdk_input_init here from gdkinput-ps2.c

	* gdk/linux-fb/gdkmain-fb.c:
	display->fb was renamed to display->fb_fd.
	Now the tty and the console is opened here instead
	of in the keyboard driver. Also check GDK_VT to see what
	tty to open.
	Move gdk_beep () here from gdkinput-ps2.c
	gdk_mouse_get_info -> gdk_fb_mouse_get_info

	* gdk/linux-fb/gdkmouse-fb.c:
	Add header.
	gdk_mouse_get_info -> gdk_fb_mouse_get_info
	Return correct keyboard modifiers.
	GDK_MOUSETYPE -> GDK_MOUSE_TYPE for consistancy

	* gdk/linux-fb/gdkprivate-fb.h:
	Add tty and vt info to display.
	Add orignal modeinfo storage to display
	Update global functions

	* gdk/linux-fb/gdkwindow-fb.c:
	Added gdk_fb_window_find_focus().
	gdk_mouse_get_info -> gdk_fb_mouse_get_info
2000-12-08 12:38:48 +00:00
Alexander Larsson
7fa13eaf35 Add gdkmouse-fb.c
2000-12-06  Alexander Larsson  <alexl@redhat.com>

	* gdk/linux-fb/Makefile.am:
	Add gdkmouse-fb.c

	* gdk/linux-fb/gdkmouse-fb.c:
	New file. Abstracted the mouse drivers a bit.

	* gdk/linux-fb/gdkcursor-fb.c:
	The cursor hide/show functions was moved here from gdkinput-ps2.c.

	* gdk/linux-fb/gdkinput-ps2.c:
	Removed old mouse handling code. Moved cursor handling code
	to gdkcursor-fb.c, moved gdk_fb_window_send_crossing_events() to
	gdkwindow-fb.c. gdk_input_get_mouseinfo was renamed to
	gdk_mouse_get_info.

	* gdk/linux-fb/gdkmain-fb.c:
	Pass NULL pointers for x,y in gdk_mouse_get_info call.

	* gdk/linux-fb/gdkprivate-fb.h:
	Removed public gdk_fb_find_common_ancestor, added and renamed
	functions for the new mouse handling code.

	* gdk/linux-fb/gdkwindow-fb.c:
	Moved gdk_fb_window_send_crossing_events here. added global
	variable gdk_fb_window_containing_pointer. made
	gdk_fb_find_common_ancestor static. gdk_input_get_mouseinfo was
	renamed to gdk_mouse_get_info.
2000-12-06 17:27:52 +00:00
Alexander Larsson
1c805555ce Huge GtkFB patch with lots of small bugfixes and initial selections implementation.
2000-11-23  Alexander Larsson  <alexl@redhat.com>

	* gdk/linux-fb/gdkselection-fb.c:
	Initial selection implementation.

	* gtk/gtkselection.c:
	if GDK_WINDOWING_FB defined, include linux-fb/gdkfb.h and look up
	requestor in gtk_selection_request.

	* gdk/linux-fb/gdkfb.h, gdk/linux-fb/gdkglobals-fb.c:
	Added gdk_selection_property atom.

	* gdk/linux-fb/gdkprivate-fb.h:
	Export _gdk_selection_window_destroyed.
	Removed mask_off_x/y from GdkCursorPrivateFB.
	Removed hbearing, added top, left to PangoFBGlyphInfo.

	* gdk/linux-fb/gdkwindow-fb.c (_gdk_windowing_window_destroy):
	Call _gdk_selection_window_destroyed
	(_gdk_windowing_window_init): Don't call gdk_cursor_new() before
	the root window has been created.
	(static_dx_hack, static_dy_hack, compare_draw_rects,
	gdk_fb_window_move_resize): Remove unnecessary sort of rectangles
	in region. They are already sorted. Instead just traverse them in
	reverse if draw_direction < 0.

	* gdk/linux-fb/gdkinput-ps2.c (send_button_event):
	Double-clicks must be sent after the normal button_press.
	(gdk_fb_cursor_unhide): Remove usage of mask_off_x/y. Clean up.

	* gdk/linux-fb/gdkgeometry-fb.c (gdk_window_scroll):
	Pass _gdk_fb_screen_gc instead of NULL.

	* gdk/linux-fb/gdkmain-fb.c (_gdk_windowing_init_check):
	Initialize gdk_selection_property.
	(gdk_event_make): Remove unused code.

	* gdk/linux-fb/gdkcursor-fb.c:
	Make the pixmap for the cursor the same size as the mask. Also remove
	the mask_off_x/y fields in GdkCursorPrivateFB and combine
	_gdk_cursor_new_from_pixmap() and gdk_cursor_new_from_pixmap()
	Now the whole cursor is visible.

	* gdk/linux-fb/gdkdrawable-fb2.c (gdk_fb_draw_drawable_3):
	Fix bug where xdest+height instead of ydest+height was used
	to calculate if the source and dest overlapped. This fixes the
	redraw bug when the main window in testgtk was scrolled when
	partially covered by a tall window.
	Copy rectangles in region in order depending on draw_direction.
	Also moved the draw_direction flipping of start_y and end_y into
	the gc functions, as this might not be what all of them want.
	(gdk_fb_draw_lines): Support dashed lines.
	(gdk_fb_draw_glyphs): Clean up glyph placement. Also fix positioning
	so that the text is positioned correctly (was 1 pixel high).

	gdk/linux-fb/gdkgc-fb.c:
	Initialize cap_style to GTK_CAP_BUTT. This fixes a problem where
	all lines were drawn a pixel to short. Also checked the default of
	the rest of the values, and they're the same as X now.

	* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_glyph_info):
	Clean up pixel positioning of the glyphs. Just use bgy->top and
	bgy->left. Also used PANGO_PIXEL where appropriate and added 0.5
	to all divisions to get correct rounding behaviour.

	* gdk/linux-fb/gdkrender-fb.c (gdk_fb_draw_drawable_generic,
	gdk_fb_draw_drawable_memmove, gdk_fb_draw_drawable_aa_24):
	Moved start_y/end_y flip into draw_drawable implementations.
	Flip also x rendering when draw_direction < 0.
	Remove unneccesary multiply with draw_direction.
2000-11-25 15:44:35 +00:00
Alexander Larsson
be698675c7 Cleanup and reindent of GtkFB.
Added some serial mouse support.
Updates to latest Gtk+/pango
2000-11-13 17:40:23 +00:00
Elliot Lee
b427cec028 Set serif font to something sane.
Set serif font to something sane.

Add cursors so it will compile anywhere (hopefully).
2000-08-03 02:33:46 +00:00
Tim Janik
afee2c67c5 applied patch from Andreas Persenius <ndap@swipnet.se> that updates the
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.
2000-07-26 11:33:08 +00:00
Elliot Lee
6d7a643f7c (Part 2) Remove gdk_*_lookup() defines, since they are defined by the
(Part 2)
	* gdk/gdkprivate.h: Remove gdk_*_lookup() defines, since they are defined by the
	individual backends already.
	* gdk/gdkregion-generic.h, gdk/gdktypes.h: Put gdkregionbox & gdksegment back together
	again. Yes, there really is a good reason for this, if you are using the gdkregion
	internals, and if you're not, why do you care?
	* gdk/gdkwindow.c: Fix inverted condition
	* gdk/linux-fb: Compiles (for me - it will not work elsewhere most likely).
	* gtk/gtkcolorsel.c, gtk/gtkwindow.c: Add include for linux-fb
	* gtk/gtkrange.c: Redraw trough when moving.
	* gtk/gtktypeutils.c: Fix warning by adding const cast.
	* modules/linux-fb/basic.c: Fix unknown glyph retrieval.
2000-07-24 16:19:00 +00:00
Elliot Lee
dd7510dccb *** empty log message *** 2000-06-20 20:20:38 +00:00
Elliot Lee
c496211676 Put it into CVS.
Put it into CVS.
2000-05-31 21:50:38 +00:00