File: Pixmap.xs

package info (click to toggle)
perl-tk 1%3A800.011-1
  • links: PTS
  • area: main
  • in suites: slink
  • size: 16,820 kB
  • ctags: 17,448
  • sloc: ansic: 189,575; perl: 31,426; makefile: 4,360; sh: 1,921; yacc: 762
file content (69 lines) | stat: -rw-r--r-- 1,397 bytes parent folder | download | duplicates (3)
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
/*
  Copyright (c) 1995-1997 Nick Ing-Simmons. All rights reserved.
  This program is free software; you can redistribute it and/or
  modify it under the same terms as Perl itself.
*/

#include <EXTERN.h>
#include <perl.h>
#include <XSUB.h>

#include "tkGlue.def"

#include "pTk/tkPort.h"
#include "pTk/tkInt.h"
#include "pTk/tixPort.h"
#include "pTk/tixInt.h"
#include "pTk/tixImgXpm.h"
#include "pTk/tkVMacro.h"
#include "tkGlue.h"
#include "tkGlue.m"

DECLARE_VTABLES;
TixVtab     *TixVptr     ; 
TixintVtab  *TixintVptr  ; 
TiximgxpmVtab  *TiximgxpmVptr  ; 

extern Tk_ImageType tixPixmapImageType;

static void  Install _((char *, TkWindow *win));

static void
Install(class,winPtr)
char *class;
TkWindow *winPtr;
{
 TkMainInfo *mainInfo = winPtr->mainPtr;
 if (mainInfo)
  {
   Tcl_Interp *Et_Interp = mainInfo->interp;
   if (Et_Interp)
    {
#ifdef WIN32
#pragma warning(disable: 4305)
#endif
#define UNSIGNED_CHAR unsigned char
#include "pTk/tixBitmaps.h"
    }
  }
}


MODULE = Tk::Pixmap	PACKAGE = Tk::Pixmap

PROTOTYPES: DISABLE

void
Install(class,win)
char *		class
TkWindow *	win

BOOT:
 {
  IMPORT_VTABLES;
  TixVptr     =     (TixVtab *) SvIV(perl_get_sv("Tk::TixVtab",5));    
  TixintVptr  =  (TixintVtab *) SvIV(perl_get_sv("Tk::TixintVtab",5));  
  TiximgxpmVptr  =  (TiximgxpmVtab *) SvIV(perl_get_sv("Tk::TiximgxpmVtab",5));  

  Tk_CreateImageType(&tixPixmapImageType);
 }