More binary-bundling removal
[pdfmod:pdfmod.git] / lib / poppler-sharp / poppler-sharp / generated / Rectangle.cs
1 // This file was generated by the Gtk# code generator.
2 // Any changes made will be lost if regenerated.
3
4 namespace Poppler {
5
6         using System;
7         using System.Collections;
8         using System.Runtime.InteropServices;
9
10 #region Autogenerated code
11         [StructLayout(LayoutKind.Sequential)]
12         public struct Rectangle {
13
14                 public double X1;
15                 public double Y1;
16                 public double X2;
17                 public double Y2;
18
19                 public static Poppler.Rectangle Zero = new Poppler.Rectangle ();
20
21                 public static Poppler.Rectangle New(IntPtr raw) {
22                         if (raw == IntPtr.Zero)
23                                 return Poppler.Rectangle.Zero;
24                         return (Poppler.Rectangle) Marshal.PtrToStructure (raw, typeof (Poppler.Rectangle));
25                 }
26
27                 [DllImport("poppler-glib")]
28                 static extern IntPtr poppler_rectangle_new();
29
30                 public static Rectangle New()
31                 {
32                         Rectangle result = Rectangle.New (poppler_rectangle_new());
33                         return result;
34                 }
35
36                 [DllImport("poppler-glib")]
37                 static extern IntPtr poppler_rectangle_copy(IntPtr raw);
38
39                 public Poppler.Rectangle Copy() {
40                         IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
41                         System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
42                         IntPtr raw_ret = poppler_rectangle_copy(this_as_native);
43                         Poppler.Rectangle ret = Poppler.Rectangle.New (raw_ret);
44                         ReadNative (this_as_native, ref this);
45                         System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
46                         return ret;
47                 }
48
49                 [DllImport("poppler-glib")]
50                 static extern void poppler_rectangle_free(IntPtr raw);
51
52                 public void Free() {
53                         IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
54                         System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
55                         poppler_rectangle_free(this_as_native);
56                         ReadNative (this_as_native, ref this);
57                         System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
58                 }
59
60                 [DllImport("poppler-glib")]
61                 static extern IntPtr poppler_rectangle_get_type();
62
63                 public static GLib.GType GType { 
64                         get {
65                                 IntPtr raw_ret = poppler_rectangle_get_type();
66                                 GLib.GType ret = new GLib.GType(raw_ret);
67                                 return ret;
68                         }
69                 }
70
71                 static void ReadNative (IntPtr native, ref Poppler.Rectangle target)
72                 {
73                         target = New (native);
74                 }
75
76 #endregion
77         }
78 }