Commit 4f5e5b48 authored by Christian Persch's avatar Christian Persch Committed by Christian Persch

Make gtk_printer_list_papers public. Bug #345587.

2006-12-24  Christian Persch  <chpe@cvs.gnome.org>

	* docs/reference/gtk/gtk-sections.txt:
	* gtk/gtk.symbols:
	* gtk/gtkpagesetupunixdialog.c: (fill_paper_sizes_from_printer):
	* gtk/gtkprinter-private.h:
	* gtk/gtkprinter.c: (gtk_printer_list_papers):
	* gtk/gtkprinter.h: Make gtk_printer_list_papers public. Bug #345587.
parent 842b3183
2006-12-24 Christian Persch <chpe@cvs.gnome.org>
* docs/reference/gtk/gtk-sections.txt:
* gtk/gtk.symbols:
* gtk/gtkpagesetupunixdialog.c: (fill_paper_sizes_from_printer):
* gtk/gtkprinter-private.h:
* gtk/gtkprinter.c: (gtk_printer_list_papers):
* gtk/gtkprinter.h: Make gtk_printer_list_papers public. Bug #345587.
2006-12-24 Carlos Garcia Campos <carlosgc@gnome.org>
* gtk/gtkpagesetupunixdialog.c: Don't ignore reverse portrait option
......
......@@ -6210,6 +6210,7 @@ gtk_printer_is_virtual
gtk_printer_is_default
gtk_printer_accepts_ps
gtk_printer_accepts_pdf
gtk_printer_list_papers
gtk_printer_compare
GtkPrinterFunc
gtk_enumerate_printers
......
......@@ -2610,6 +2610,7 @@ gtk_printer_get_location
gtk_printer_get_icon_name
gtk_printer_get_job_count
gtk_printer_is_virtual
gtk_printer_list_papers
gtk_printer_accepts_pdf
gtk_printer_accepts_ps
gtk_printer_compare
......
......@@ -723,7 +723,7 @@ fill_paper_sizes_from_printer (GtkPageSetupUnixDialog *dialog,
}
else
{
list = _gtk_printer_list_papers (printer);
list = gtk_printer_list_papers (printer);
/* TODO: We should really sort this list so interesting size
are at the top */
for (l = list; l != NULL; l = l->next)
......
......@@ -49,7 +49,6 @@ cairo_surface_t * _gtk_printer_create_cairo_surface (GtkPrinter
gdouble width,
gdouble height,
GIOChannel *cache_io);
GList * _gtk_printer_list_papers (GtkPrinter *printer);
void _gtk_printer_get_hard_margins (GtkPrinter *printer,
gdouble *top,
gdouble *bottom,
......
......@@ -784,11 +784,24 @@ _gtk_printer_create_cairo_surface (GtkPrinter *printer,
width, height, cache_io);
}
/**
* gtk_printer_list_papers:
* @printer:
*
* Lists all the page sizes @printer supports.
*
* Return value: a newly allocated list of newly allocated #GtkPageSetup:s.
*
* Since: 2.12
*/
GList *
_gtk_printer_list_papers (GtkPrinter *printer)
gtk_printer_list_papers (GtkPrinter *printer)
{
GtkPrintBackendClass *backend_class = GTK_PRINT_BACKEND_GET_CLASS (printer->priv->backend);
GtkPrintBackendClass *backend_class;
g_return_val_if_fail (GTK_IS_PRINTER (printer), NULL);
backend_class = GTK_PRINT_BACKEND_GET_CLASS (printer->priv->backend);
return backend_class->printer_list_papers (printer);
}
......
......@@ -79,6 +79,7 @@ gboolean gtk_printer_is_virtual (GtkPrinter *printer
gboolean gtk_printer_is_default (GtkPrinter *printer);
gboolean gtk_printer_accepts_pdf (GtkPrinter *printer);
gboolean gtk_printer_accepts_ps (GtkPrinter *printer);
GList *gtk_printer_list_papers (GtkPrinter *printer);
gint gtk_printer_compare (GtkPrinter *a,
GtkPrinter *b);
......@@ -90,7 +91,7 @@ void gtk_enumerate_printers (GtkPrinterFunc func,
gpointer data,
GDestroyNotify destroy,
gboolean wait);
G_END_DECLS
#endif /* __GTK_PRINTER_H__ */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment