2003-09-17 21:56:59 +00:00
<Type Name= "Print" FullName= "Gnome.Print" >
<TypeSignature Language= "C#" Value= "public class Print" Maintainer= "auto" />
<AssemblyInfo >
<AssemblyName > gnome-sharp</AssemblyName>
2003-11-23 00:56:01 +00:00
<AssemblyPublicKey >
</AssemblyPublicKey>
2003-09-17 21:56:59 +00:00
<AssemblyVersion > 0.0.0.0</AssemblyVersion>
<AssemblyCulture > neutral</AssemblyCulture>
<Attributes />
</AssemblyInfo>
<ThreadSafetyStatement > Gtk# is thread aware, but not thread safe; See the <link location= "node:gtk-sharp/programming/threads" > Gtk# Thread Programming</link> for details.</ThreadSafetyStatement>
<Docs >
<summary > To be added</summary>
<remarks > To be added</remarks>
2003-11-23 00:56:01 +00:00
<example >
<code language= "C#" >
using System;
using Gtk;
using GtkSharp;
using Gnome;
class PrintSample
{
TextView tv;
static void Main ()
{
new PrintSample ();
}
PrintSample ()
{
Application.Init ();
Gtk.Window win = new Gtk.Window ("Print sample");
win.SetDefaultSize (400, 300);
win.DeleteEvent += new DeleteEventHandler (OnWinDelete);
VBox vbox = new VBox (false, 0);
win.Add (vbox);
tv = new TextView ();
tv.Buffer.Text = "Hello World";
vbox.PackStart (tv, true, true, 0);
Button print = new Button (Gtk.Stock.Print);
print.Clicked += new EventHandler (OnPrintClicked);
vbox.PackStart (print, false, true, 0);
win.ShowAll ();
Application.Run ();
}
void MyPrint (PrintContext gpc)
{
Print.Beginpage (gpc, "demo");
Print.Moveto (gpc, 1, 700);
Print.Show (gpc, tv.Buffer.Text);
Print.Showpage (gpc);
}
void OnPrintClicked (object o, EventArgs args)
{
PrintJob pj = new PrintJob (PrintConfig.Default ());
PrintDialog dialog = new PrintDialog (pj, "Print Test", 0);
int response = dialog.Run ();
Console.WriteLine ("response: " + response);
if (response == (int) PrintButtons.Cancel) {
Console.WriteLine ("Canceled");
dialog.Hide ();
dialog.Dispose ();
return;
}
PrintContext ctx = pj.Context;
MyPrint (ctx);
pj.Close ();
switch (response) {
case (int) PrintButtons.Print:
pj.Print ();
break;
case (int) PrintButtons.Preview:
new PrintJobPreview (pj, "Print Test").Show ();
break;
}
dialog.Hide ();
dialog.Dispose ();
}
void OnWinDelete (object o, DeleteEventArgs args)
{
Application.Quit ();
}
}
</code>
</example>
2003-09-17 21:56:59 +00:00
</Docs>
<Base >
<BaseTypeName > System.Object</BaseTypeName>
</Base>
<Interfaces />
<Attributes />
<Members >
<Member MemberName= ".ctor" >
<MemberSignature Language= "C#" Value= "public Print ();" />
<MemberType > Constructor</MemberType>
<ReturnValue />
<Parameters />
<Docs >
<summary > To be added</summary>
<returns > a <see cref= "T:Gnome.Print" /> </returns>
<remarks > To be added</remarks>
</Docs>
</Member>
2004-11-05 21:37:41 +00:00
<Member MemberName= "Pixbuf" >
<MemberSignature Language= "C#" Value= "public static int Pixbuf (Gnome.PrintContext pc, Gdk.Pixbuf image);" />
2003-10-12 09:06:39 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
<ReturnType > System.Int32</ReturnType>
</ReturnValue>
<Parameters >
<Parameter Name= "pc" Type= "Gnome.PrintContext" />
2004-11-05 21:37:41 +00:00
<Parameter Name= "image" Type= "Gdk.Pixbuf" />
2003-10-12 09:06:39 +00:00
</Parameters>
<Docs >
<summary > To be added</summary>
<param name= "pc" > a <see cref= "T:Gnome.PrintContext" /> </param>
2004-11-05 21:37:41 +00:00
<param name= "image" > a <see cref= "T:Gdk.Pixbuf" /> </param>
2003-10-12 09:06:39 +00:00
<returns > a <see cref= "T:System.Int32" /> </returns>
<remarks > To be added</remarks>
</Docs>
</Member>
2004-11-05 21:37:41 +00:00
<Member MemberName= "CheckbuttonNew" >
<MemberSignature Language= "C#" Value= "public static Gtk.Widget CheckbuttonNew (Gnome.PrintConfig config, out byte path, out byte label);" />
2003-10-12 09:06:39 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2004-11-05 21:37:41 +00:00
<ReturnType > Gtk.Widget</ReturnType>
2003-10-12 09:06:39 +00:00
</ReturnValue>
<Parameters >
2004-11-05 21:37:41 +00:00
<Parameter Name= "config" Type= "Gnome.PrintConfig" />
<Parameter Name= "path" Type= "System.Byte&" RefType= "out" />
<Parameter Name= "label" Type= "System.Byte&" RefType= "out" />
2003-10-12 09:06:39 +00:00
</Parameters>
<Docs >
<summary > To be added</summary>
2004-11-05 21:37:41 +00:00
<param name= "config" > a <see cref= "T:Gnome.PrintConfig" /> </param>
<param name= "path" > a <see cref= "T:System.Byte" /> </param>
<param name= "label" > a <see cref= "T:System.Byte" /> </param>
<returns > a <see cref= "T:Gtk.Widget" /> </returns>
2003-10-12 09:06:39 +00:00
<remarks > To be added</remarks>
</Docs>
</Member>
2004-11-05 21:37:41 +00:00
<Member MemberName= "RadiobuttonNew" >
<MemberSignature Language= "C#" Value= "public static Gtk.Widget RadiobuttonNew (Gnome.PrintConfig config, out byte path, Gnome.PrintConfigOption options);" />
2003-10-12 09:06:39 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2004-11-05 21:37:41 +00:00
<ReturnType > Gtk.Widget</ReturnType>
2003-10-12 09:06:39 +00:00
</ReturnValue>
<Parameters >
2004-11-05 21:37:41 +00:00
<Parameter Name= "config" Type= "Gnome.PrintConfig" />
<Parameter Name= "path" Type= "System.Byte&" RefType= "out" />
<Parameter Name= "options" Type= "Gnome.PrintConfigOption" />
2003-10-12 09:06:39 +00:00
</Parameters>
<Docs >
<summary > To be added</summary>
2004-11-05 21:37:41 +00:00
<param name= "config" > a <see cref= "T:Gnome.PrintConfig" /> </param>
<param name= "path" > a <see cref= "T:System.Byte" /> </param>
<param name= "options" > a <see cref= "T:Gnome.PrintConfigOption" /> </param>
<returns > a <see cref= "T:Gtk.Widget" /> </returns>
2003-10-12 09:06:39 +00:00
<remarks > To be added</remarks>
</Docs>
</Member>
2004-11-05 21:37:41 +00:00
<Member MemberName= "WidgetNew" >
<MemberSignature Language= "C#" Value= "public static Gtk.Widget WidgetNew (Gnome.PrintConfig config, out byte path, Gnome.PrintWidgetType type);" />
2003-10-28 00:48:23 +00:00
<MemberType > Method</MemberType>
<ReturnValue >
2004-11-05 21:37:41 +00:00
<ReturnType > Gtk.Widget</ReturnType>
2003-10-28 00:48:23 +00:00
</ReturnValue>
<Parameters >
2004-11-05 21:37:41 +00:00
<Parameter Name= "config" Type= "Gnome.PrintConfig" />
<Parameter Name= "path" Type= "System.Byte&" RefType= "out" />
<Parameter Name= "type" Type= "Gnome.PrintWidgetType" />
2003-10-28 00:48:23 +00:00
</Parameters>
<Docs >
<summary > To be added</summary>
2004-11-05 21:37:41 +00:00
<param name= "config" > a <see cref= "T:Gnome.PrintConfig" /> </param>
<param name= "path" > a <see cref= "T:System.Byte" /> </param>
<param name= "type" > a <see cref= "T:System.Int32" /> </param>
<returns > a <see cref= "T:Gtk.Widget" /> </returns>
2003-10-28 00:48:23 +00:00
<remarks > To be added</remarks>
</Docs>
</Member>
2003-09-17 21:56:59 +00:00
</Members>
</Type>