2009-01-06 Gonzalo Paniagua Javier <gonzalo@novell.com>
[mono.git] / mcs / class / Mono.Cairo / Mono.Cairo / PSSurface.cs
index 450161a5d1f8ae18d2fdbb79fe771e609d338b99..1304be6230a295fa69dd921dc5edf431ba3d6767 100644 (file)
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if CAIRO_1_2
-
 using System;
 
 namespace Cairo {
 
        public class PSSurface : Surface
        {
+               internal PSSurface (IntPtr handle, bool owns) : base (handle, owns)
+               {
+               }
+
                public PSSurface (string filename, double width, double height)
                {
-                       surface = CairoAPI.cairo_ps_surface_create (filename, width, height);
+                       surface = NativeMethods.cairo_ps_surface_create (filename, width, height);
                        lock (surfaces.SyncRoot){
                                surfaces [surface] = this;
                        }
                }
 
+               public void BeginPageSetup ()
+               {
+                       NativeMethods.cairo_ps_surface_begin_page_setup (surface);
+               }
+
+               public void BeginSetup ()
+               {
+                       NativeMethods.cairo_ps_surface_begin_setup (surface);
+               }
+
+               public void DscComment (string comment)
+               {
+                       NativeMethods.cairo_ps_surface_dsc_comment (surface, comment);
+               }
+
                public void SetSize (double width, double height)
                {
-                       CairoAPI.cairo_ps_surface_set_size (surface, width, height);
+                       NativeMethods.cairo_ps_surface_set_size (surface, width, height);
                }
        }
 }
-
-#endif