summaryrefslogtreecommitdiff
path: root/gtk/gtkprintcontext.c
diff options
context:
space:
mode:
Diffstat (limited to 'gtk/gtkprintcontext.c')
-rw-r--r--gtk/gtkprintcontext.c18
1 files changed, 7 insertions, 11 deletions
diff --git a/gtk/gtkprintcontext.c b/gtk/gtkprintcontext.c
index c512869467..26e5a56c70 100644
--- a/gtk/gtkprintcontext.c
+++ b/gtk/gtkprintcontext.c
@@ -213,21 +213,17 @@ _gtk_print_context_rotate_according_to_orientation (GtkPrintContext *context)
void
_gtk_print_context_translate_into_margin (GtkPrintContext *context)
{
- GtkPrintOperationPrivate *priv;
gdouble left, top;
g_return_if_fail (GTK_IS_PRINT_CONTEXT (context));
- priv = context->op->priv;
-
/* We do it this way to also handle GTK_UNIT_PIXELS */
-
left = gtk_page_setup_get_left_margin (context->page_setup, GTK_UNIT_INCH);
top = gtk_page_setup_get_top_margin (context->page_setup, GTK_UNIT_INCH);
cairo_translate (context->cr,
- left * context->surface_dpi_x / context->pixels_per_unit_x,
- top * context->surface_dpi_y / context->pixels_per_unit_y);
+ left * context->surface_dpi_x / context->pixels_per_unit_x,
+ top * context->surface_dpi_y / context->pixels_per_unit_y);
}
void
@@ -253,7 +249,7 @@ _gtk_print_context_set_page_setup (GtkPrintContext *context,
* Obtains the cairo context that is associated with the
* #GtkPrintContext.
*
- * Return value: the cairo context of @context
+ * Return value: (transfer none): the cairo context of @context
*
* Since: 2.10
*/
@@ -383,10 +379,10 @@ gtk_print_context_get_dpi_y (GtkPrintContext *context)
/**
* gtk_print_context_get_hard_margins:
* @context: a #GtkPrintContext
- * @top: top hardware printer margin
- * @bottom: bottom hardware printer margin
- * @left: left hardware printer margin
- * @right: right hardware printer margin
+ * @top: (out): top hardware printer margin
+ * @bottom: (out): bottom hardware printer margin
+ * @left: (out): left hardware printer margin
+ * @right: (out): right hardware printer margin
*
* Obtains the hardware printer margins of the #GtkPrintContext, in units.
*