mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-26 13:41:07 +00:00
Add a function to list the builtin paper sizes. (#382355, Christian
2007-04-29 Matthias Clasen <mclasen@redhat.com> * gtk/gtk.symbols: * gtk/gtkpapersize.[hc]: Add a function to list the builtin paper sizes. (#382355, Christian Persch) svn path=/trunk/; revision=17691
This commit is contained in:
parent
bcbbbe5101
commit
4e316dd99e
@ -1,3 +1,9 @@
|
||||
2007-04-29 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtk.symbols:
|
||||
* gtk/gtkpapersize.[hc]: Add a function to list the
|
||||
builtin paper sizes. (#382355, Christian Persch)
|
||||
|
||||
2007-04-29 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtk.symbols:
|
||||
|
@ -1,3 +1,7 @@
|
||||
2007-04-29 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtk-sections.txt: Add gtk_paper_size_get_builtins
|
||||
|
||||
2007-04-29 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtk-sections.txt: Add gtk_printer_{has,request}_details
|
||||
|
@ -6361,6 +6361,7 @@ gtk_paper_size_new_custom
|
||||
gtk_paper_size_copy
|
||||
gtk_paper_size_free
|
||||
gtk_paper_size_is_equal
|
||||
gtk_paper_size_get_builtins
|
||||
gtk_paper_size_get_name
|
||||
gtk_paper_size_get_display_name
|
||||
gtk_paper_size_get_ppd_name
|
||||
|
@ -2555,6 +2555,7 @@ gtk_paper_size_new_custom
|
||||
gtk_paper_size_copy
|
||||
gtk_paper_size_free
|
||||
gtk_paper_size_is_equal
|
||||
gtk_paper_size_get_builtins
|
||||
gtk_paper_size_get_name
|
||||
gtk_paper_size_get_display_name
|
||||
gtk_paper_size_get_ppd_name
|
||||
|
@ -430,6 +430,33 @@ gtk_paper_size_is_equal (GtkPaperSize *size1,
|
||||
gtk_paper_size_get_name (size2)) == 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_paper_size_get_builtins:
|
||||
*
|
||||
* Creates a list of builtin paper sizes.
|
||||
*
|
||||
* Return value: a newly allocated list of newly
|
||||
* allocated #GtkPaperSize objects
|
||||
*
|
||||
* Since: 2.12
|
||||
*/
|
||||
GList *
|
||||
gtk_paper_size_get_builtins (void)
|
||||
{
|
||||
GList *list = NULL;
|
||||
guint i;
|
||||
|
||||
for (i = 0; i < G_N_ELEMENTS (standard_names_offsets); ++i)
|
||||
{
|
||||
GtkPaperSize *size;
|
||||
|
||||
size = gtk_paper_size_new_from_info (&standard_names_offsets[i]);
|
||||
list = g_list_prepend (list, size);
|
||||
}
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_paper_size_get_name:
|
||||
* @size: a #GtkPaperSize object
|
||||
|
@ -56,6 +56,7 @@ void gtk_paper_size_free (GtkPaperSize *size);
|
||||
gboolean gtk_paper_size_is_equal (GtkPaperSize *size1,
|
||||
GtkPaperSize *size2);
|
||||
|
||||
GList *gtk_paper_size_get_builtins (void);
|
||||
|
||||
/* The width is always the shortest side, measure in mm */
|
||||
G_CONST_RETURN gchar *gtk_paper_size_get_name (GtkPaperSize *size);
|
||||
|
Loading…
Reference in New Issue
Block a user