File: appGuiGtkX.c

package info (click to toggle)
ted 2.11-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 11,064 kB
  • ctags: 13,935
  • sloc: ansic: 120,446; makefile: 7,469; sh: 253
file content (50 lines) | stat: -rw-r--r-- 1,063 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#   include	"appFrameConfig.h"

#   include	<stdlib.h>
#   include	<stdio.h>
#   include	<string.h>
#   include	<appDebugon.h>

#   ifdef USE_GTK

#   include	"appFrame.h"
#   include	<appGeoString.h>

#   include	<gdk/gdkx.h>

void appIconifyShellWidget(		APP_WIDGET		shell )
    {
    XIconifyWindow( GDK_DISPLAY(),
	GDK_WINDOW_XWINDOW( shell->window ), DefaultScreen( GDK_DISPLAY() ) );
    }

void appCopyPixmapValue(	APP_SELECTION_EVENT *	gsd,
				APP_BITMAP_IMAGE	pixmapCopied )
    {
    Pixmap	pixmap= GDK_WINDOW_XWINDOW( pixmapCopied );

    gtk_selection_data_set( gsd, gsd->target, 8* sizeof(Pixmap),
				(unsigned char *)&pixmap, sizeof(Pixmap) );

    return;
    }

void appDrawGtkSetXFillRule(	GdkGC *		gc,
				int		rule )
    {
    GdkGCPrivate *	private;

    private = (GdkGCPrivate*)gc;

    switch( rule )
	{
	case GDK_EVEN_ODD_RULE:	rule= EvenOddRule; break;
	case GDK_WINDING_RULE:	rule= WindingRule; break;
	default:
	    LDEB(rule); rule= EvenOddRule; break;
	}

    XSetFillRule( GDK_DISPLAY(), private->xgc, rule );
    }
				
#   endif